Skip to content

Commit 4c82232

Browse files
committed
Initial commit
0 parents  commit 4c82232

21 files changed

+7504
-0
lines changed

.eslintrc

+38
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
{
2+
"parser": "@typescript-eslint/parser",
3+
"extends": [
4+
"eslint:recommended",
5+
"plugin:@typescript-eslint/eslint-recommended",
6+
"plugin:@typescript-eslint/recommended" // uses the recommended rules from the @typescript-eslint/eslint-plugin
7+
],
8+
"parserOptions": {
9+
"ecmaVersion": 2018,
10+
"sourceType": "module"
11+
},
12+
"ignorePatterns": [
13+
"dist"
14+
],
15+
"rules": {
16+
"quotes": ["warn", "single"],
17+
"indent": ["warn", 2, { "SwitchCase": 1 }],
18+
"semi": ["off"],
19+
"comma-dangle": ["warn", "always-multiline"],
20+
"dot-notation": "off",
21+
"eqeqeq": "warn",
22+
"curly": ["warn", "all"],
23+
"brace-style": ["warn"],
24+
"prefer-arrow-callback": ["warn"],
25+
"max-len": ["warn", 140],
26+
"no-console": ["warn"], // use the provided Homebridge log method instead
27+
"no-non-null-assertion": ["off"],
28+
"comma-spacing": ["error"],
29+
"no-multi-spaces": ["warn", { "ignoreEOLComments": true }],
30+
"no-trailing-spaces": ["warn"],
31+
"lines-between-class-members": ["warn", "always", {"exceptAfterSingleLine": true}],
32+
"@typescript-eslint/explicit-function-return-type": "off",
33+
"@typescript-eslint/no-non-null-assertion": "off",
34+
"@typescript-eslint/explicit-module-boundary-types": "off",
35+
"@typescript-eslint/semi": ["warn"],
36+
"@typescript-eslint/member-delimiter-style": ["warn"]
37+
}
38+
}

.github/ISSUE_TEMPLATE/bug-report.md

+44
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
---
2+
name: Bug Report
3+
about: Create a report to help us improve
4+
title: ''
5+
labels: bug
6+
assignees: ''
7+
8+
---
9+
10+
<!-- You must use the issue template below when submitting a bug -->
11+
12+
**Describe The Bug:**
13+
<!-- A clear and concise description of what the bug is. -->
14+
15+
**To Reproduce:**
16+
<!-- Steps to reproduce the behavior. -->
17+
18+
**Expected behavior:**
19+
<!-- A clear and concise description of what you expected to happen. -->
20+
21+
**Logs:**
22+
23+
```
24+
Show the Homebridge logs here, remove any sensitive information.
25+
```
26+
27+
**Plugin Config:**
28+
29+
```json
30+
Show your Homebridge config.json here, remove any sensitive information.
31+
```
32+
33+
**Screenshots:**
34+
<!-- If applicable, add screenshots to help explain your problem. -->
35+
36+
**Environment:**
37+
38+
* **Plugin Version**:
39+
* **Homebridge Version**: <!-- homebridge -V -->
40+
* **Node.js Version**: <!-- node -v -->
41+
* **NPM Version**: <!-- npm -v -->
42+
* **Operating System**: <!-- Raspbian / Ubuntu / Debian / Windows / macOS / Docker / hb-service -->
43+
44+
<!-- Click the "Preview" tab before you submit to ensure the formatting is correct. -->

.github/ISSUE_TEMPLATE/config.yml

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# blank_issues_enabled: false
2+
# contact_links:
3+
# - name: Homebridge Discord Community
4+
# url: https://discord.gg/kqNCe2D
5+
# about: Ask your questions in the #YOUR_CHANNEL_HERE channel
+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
---
2+
name: Feature Request
3+
about: Suggest an idea for this project
4+
title: ''
5+
labels: enhancement
6+
assignees: ''
7+
8+
---
9+
10+
**Is your feature request related to a problem? Please describe:**
11+
<!-- A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] -->
12+
13+
**Describe the solution you'd like:**
14+
<!-- A clear and concise description of what you want to happen. -->
15+
16+
**Describe alternatives you've considered:**
17+
<!-- A clear and concise description of any alternative solutions or features you've considered. -->
18+
19+
**Additional context:**
20+
<!-- Add any other context or screenshots about the feature request here. -->
21+
22+
23+
<!-- Click the "Preview" tab before you submit to ensure the formatting is correct. -->
+38
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
---
2+
name: Support Request
3+
about: Need help?
4+
title: ''
5+
labels: question
6+
assignees: ''
7+
8+
---
9+
10+
<!-- You must use the issue template below when submitting a support request -->
11+
12+
**Describe Your Problem:**
13+
<!-- A clear and concise description of what problem you are trying to solve. -->
14+
15+
**Logs:**
16+
17+
```
18+
Show the Homebridge logs here, remove any sensitive information.
19+
```
20+
21+
**Plugin Config:**
22+
23+
```json
24+
Show your Homebridge config.json here, remove any sensitive information.
25+
```
26+
27+
**Screenshots:**
28+
<!-- If applicable, add screenshots to help explain your problem. -->
29+
30+
**Environment:**
31+
32+
* **Plugin Version**:
33+
* **Homebridge Version**: <!-- homebridge -V -->
34+
* **Node.js Version**: <!-- node -v -->
35+
* **NPM Version**: <!-- npm -v -->
36+
* **Operating System**: <!-- Raspbian / Ubuntu / Debian / Windows / macOS / Docker / hb-service -->
37+
38+
<!-- Click the "Preview" tab before you submit to ensure the formatting is correct. -->

.github/workflows/build.yml

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Build and Lint
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
build:
7+
runs-on: ubuntu-latest
8+
9+
strategy:
10+
matrix:
11+
# the Node.js versions to build on
12+
node-version: [12.x, 13.x, 14.x, 15.x, 16.x]
13+
14+
steps:
15+
- uses: actions/checkout@v2
16+
17+
- name: Use Node.js ${{ matrix.node-version }}
18+
uses: actions/setup-node@v2
19+
with:
20+
node-version: ${{ matrix.node-version }}
21+
22+
- name: Install dependencies
23+
run: npm install
24+
25+
- name: Lint the project
26+
run: npm run lint
27+
28+
- name: Build the project
29+
run: npm run build
30+
env:
31+
CI: true

.gitignore

+120
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,120 @@
1+
# Ignore compiled code
2+
dist
3+
4+
# ------------- Defaults ------------- #
5+
6+
# Logs
7+
logs
8+
*.log
9+
npm-debug.log*
10+
yarn-debug.log*
11+
yarn-error.log*
12+
lerna-debug.log*
13+
14+
# Diagnostic reports (https://nodejs.org/api/report.html)
15+
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
16+
17+
# Runtime data
18+
pids
19+
*.pid
20+
*.seed
21+
*.pid.lock
22+
23+
# Directory for instrumented libs generated by jscoverage/JSCover
24+
lib-cov
25+
26+
# Coverage directory used by tools like istanbul
27+
coverage
28+
*.lcov
29+
30+
# nyc test coverage
31+
.nyc_output
32+
33+
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
34+
.grunt
35+
36+
# Bower dependency directory (https://bower.io/)
37+
bower_components
38+
39+
# node-waf configuration
40+
.lock-wscript
41+
42+
# Compiled binary addons (https://nodejs.org/api/addons.html)
43+
build/Release
44+
45+
# Dependency directories
46+
node_modules/
47+
jspm_packages/
48+
49+
# Snowpack dependency directory (https://snowpack.dev/)
50+
web_modules/
51+
52+
# TypeScript cache
53+
*.tsbuildinfo
54+
55+
# Optional npm cache directory
56+
.npm
57+
58+
# Optional eslint cache
59+
.eslintcache
60+
61+
# Microbundle cache
62+
.rpt2_cache/
63+
.rts2_cache_cjs/
64+
.rts2_cache_es/
65+
.rts2_cache_umd/
66+
67+
# Optional REPL history
68+
.node_repl_history
69+
70+
# Output of 'npm pack'
71+
*.tgz
72+
73+
# Yarn Integrity file
74+
.yarn-integrity
75+
76+
# dotenv environment variables file
77+
.env
78+
.env.test
79+
80+
# parcel-bundler cache (https://parceljs.org/)
81+
.cache
82+
.parcel-cache
83+
84+
# Next.js build output
85+
.next
86+
87+
# Nuxt.js build / generate output
88+
.nuxt
89+
dist
90+
91+
# Gatsby files
92+
.cache/
93+
# Comment in the public line in if your project uses Gatsby and not Next.js
94+
# https://nextjs.org/blog/next-9-1#public-directory-support
95+
# public
96+
97+
# vuepress build output
98+
.vuepress/dist
99+
100+
# Serverless directories
101+
.serverless/
102+
103+
# FuseBox cache
104+
.fusebox/
105+
106+
# DynamoDB Local files
107+
.dynamodb/
108+
109+
# TernJS port file
110+
.tern-port
111+
112+
# Stores VSCode versions used for testing VSCode extensions
113+
.vscode-test
114+
115+
# yarn v2
116+
117+
.yarn/cache
118+
.yarn/unplugged
119+
.yarn/build-state.yml
120+
.pnp.*

0 commit comments

Comments
 (0)