This repository has been archived by the owner on Oct 4, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 60
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit a5340fa
Showing
47 changed files
with
8,193 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,92 @@ | ||
{ | ||
"parser": "@typescript-eslint/parser", | ||
"extends": [ | ||
"eslint:recommended", | ||
"plugin:@typescript-eslint/eslint-recommended", | ||
"plugin:@typescript-eslint/recommended" | ||
], | ||
"parserOptions": { | ||
"ecmaVersion": 2018, | ||
"sourceType": "module" | ||
}, | ||
"ignorePatterns": [ | ||
"dist", | ||
"server", | ||
"portal", | ||
"local-execution" | ||
], | ||
"rules": { | ||
"quotes": [ | ||
"warn", | ||
"single" | ||
], | ||
"indent": [ | ||
"warn", | ||
2, | ||
{ | ||
"SwitchCase": 1 | ||
} | ||
], | ||
"semi": [ | ||
"off" | ||
], | ||
"comma-dangle": [ | ||
"warn", | ||
"always-multiline" | ||
], | ||
"dot-notation": "off", | ||
"eqeqeq": "warn", | ||
"curly": [ | ||
"warn", | ||
"all" | ||
], | ||
"brace-style": [ | ||
"warn" | ||
], | ||
"prefer-arrow-callback": [ | ||
"warn" | ||
], | ||
"max-len": [ | ||
"warn", | ||
160 | ||
], | ||
"no-console": [ | ||
"warn" | ||
], // use the provided Homebridge log method instead | ||
"no-non-null-assertion": [ | ||
"off" | ||
], | ||
"comma-spacing": [ | ||
"error" | ||
], | ||
"no-multi-spaces": [ | ||
"warn", | ||
{ | ||
"ignoreEOLComments": true | ||
} | ||
], | ||
"lines-between-class-members": [ | ||
"warn", | ||
"always", | ||
{ | ||
"exceptAfterSingleLine": true | ||
} | ||
], | ||
"@typescript-eslint/explicit-function-return-type": "off", | ||
"@typescript-eslint/no-non-null-assertion": "off", | ||
"@typescript-eslint/explicit-module-boundary-types": "off", | ||
"@typescript-eslint/no-explicit-any": "off", | ||
"@typescript-eslint/no-unused-vars": [ | ||
"off", | ||
{ | ||
"args": "none" | ||
} | ||
], | ||
"@typescript-eslint/semi": [ | ||
"warn" | ||
], | ||
"@typescript-eslint/member-delimiter-style": [ | ||
"warn" | ||
] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# These are supported funding model platforms | ||
|
||
custom: https://paypal.me/oznu |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
--- | ||
name: Bug Report | ||
about: Create a report to help us improve | ||
title: '' | ||
labels: bug | ||
assignees: '' | ||
|
||
--- | ||
|
||
<!-- You must use the issue template below when submitting a bug --> | ||
|
||
**Describe The Bug:** | ||
<!-- A clear and concise description of what the bug is. --> | ||
|
||
**To Reproduce:** | ||
<!-- Steps to reproduce the behavior. --> | ||
|
||
**Expected behavior:** | ||
<!-- A clear and concise description of what you expected to happen. --> | ||
|
||
**Logs:** | ||
<!-- Bug reports that do not contain logs may be closed without warning. --> | ||
|
||
``` | ||
Show the Homebridge logs here. | ||
Remove any sensitive information. | ||
``` | ||
|
||
**Homebridge Config:** | ||
|
||
```json | ||
Show your homebridge config.json here. | ||
Remove any sensitive information, such as your homebridge-gsh / google-smarthome token. | ||
``` | ||
|
||
**Screenshots:** | ||
<!-- If applicable, add screenshots to help explain your problem. --> | ||
|
||
**Environment:** | ||
|
||
* **Node.js Version**: <!-- node -v --> | ||
* **NPM Version**: <!-- npm -v --> | ||
* **Homebridge Version**: <!-- homebridge -V --> | ||
* **Homebridge GSH Plugin Version**: | ||
* **Homebridge Config UI X Plugin Version**: | ||
* **Operating System**: <!-- Raspbian / Ubuntu / Debian / Windows / macOS / Docker --> | ||
|
||
|
||
<!-- Click the "Preview" tab before you submit to ensure the formatting is correct. --> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
blank_issues_enabled: false | ||
contact_links: | ||
- name: Homebridge Discord Community | ||
url: https://discord.gg/cFFBuvp | ||
about: Ask your questions in the homebridge-gsh channel |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
--- | ||
name: Feature Request | ||
about: Suggest an idea for this project | ||
title: '' | ||
labels: enhancement | ||
assignees: '' | ||
|
||
--- | ||
|
||
**Is your feature request related to a problem? Please describe:** | ||
<!-- A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] --> | ||
|
||
**Describe the solution you'd like:** | ||
<!-- A clear and concise description of what you want to happen. --> | ||
|
||
**Describe alternatives you've considered:** | ||
<!-- A clear and concise description of any alternative solutions or features you've considered. --> | ||
|
||
**Additional context:** | ||
<!-- Add any other context or screenshots about the feature request here. --> | ||
|
||
|
||
<!-- Click the "Preview" tab before you submit to ensure the formatting is correct. --> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
--- | ||
name: Support Request | ||
about: Need help? | ||
title: '' | ||
labels: question | ||
assignees: '' | ||
|
||
--- | ||
|
||
<!-- You must use the issue template below when submitting a support request --> | ||
|
||
**Describe Your Problem:** | ||
<!-- A clear and concise description of what problem you are trying to solve. --> | ||
|
||
**Logs:** | ||
<!-- Support requests that do not contain logs may be closed without warning. --> | ||
|
||
``` | ||
Show the Homebridge logs here. | ||
Remove any sensative information. | ||
``` | ||
|
||
**Homebridge Config:** | ||
|
||
```json | ||
Show your homebridge config.json here. | ||
Remove any sensitive information, such as your homebridge-gsh / google-smarthome token. | ||
``` | ||
|
||
**Screenshots:** | ||
<!-- If applicable, add screenshots to help explain your problem. --> | ||
|
||
**Environment:** | ||
|
||
* **Node.js Version**: <!-- node -v --> | ||
* **NPM Version**: <!-- npm -v --> | ||
* **Homebridge Version**: <!-- homebridge -V --> | ||
* **Homebridge GSH Plugin Version**: | ||
* **Homebridge Config UI X Plugin Version**: | ||
* **Operating System**: <!-- Raspbian / Ubuntu / Debian / Windows / macOS / Docker --> | ||
|
||
|
||
<!-- Click the "Preview" tab before you submit to ensure the formatting is correct. --> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
# Security Policies and Procedures | ||
|
||
This document outlines security procedures and general policies for the `homebridge-gsh` project. | ||
|
||
* [Reporting a Bug](#reporting-a-bug) | ||
* [Disclosure Policy](#disclosure-policy) | ||
* [Comments on this Policy](#comments-on-this-policy) | ||
|
||
## Reporting a Bug | ||
|
||
The `homebridge-gsh` team and community take all security bugs in `homebridge-gsh` | ||
seriously. Thank you for improving the security of `homebridge-gsh`. We appreciate | ||
your efforts and responsible disclosure and will make every effort to acknowledge | ||
your contributions. | ||
|
||
Report security bugs by emailing the maintainer at [email protected] | ||
|
||
The maintainer will acknowledge your email within 48 hours, and will send a | ||
more detailed response within 48 hours indicating the next steps in handling | ||
your report. After the initial reply to your report, the security team will | ||
endeavor to keep you informed of the progress towards a fix and full | ||
announcement, and may ask for additional information or guidance. | ||
|
||
Report security bugs in third-party modules to the person or team maintaining | ||
the module. | ||
|
||
## Disclosure Policy | ||
|
||
When the security team receives a security bug report, they will assign it to a | ||
primary handler. This person will coordinate the fix and release process, | ||
involving the following steps: | ||
|
||
* Confirm the problem and determine the affected versions. | ||
* Audit code to find any potential similar problems. | ||
* Prepare fixes for all releases still under maintenance. These fixes will be | ||
released as fast as possible to npm. | ||
|
||
## Comments on this Policy | ||
|
||
If you have suggestions on how this process could be improved please submit a | ||
pull request. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# Number of days of inactivity before an issue becomes stale | ||
daysUntilStale: 30 | ||
# Number of days of inactivity before a stale issue is closed | ||
daysUntilClose: 5 | ||
# Issues with these labels will never be considered stale | ||
exemptLabels: | ||
- pinned | ||
- security | ||
# Label to use when marking an issue as stale | ||
staleLabel: stale | ||
# Comment to post when marking an issue as stale. Set to `false` to disable | ||
markComment: > | ||
This issue has been automatically marked as stale because it has not had | ||
recent activity. It will be closed if no further activity occurs. Thank you | ||
for your contributions. | ||
# Comment to post when closing a stale issue. Set to `false` to disable | ||
closeComment: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: Homebridge Build and Lint | ||
|
||
on: [push, pull_request] | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
matrix: | ||
# the Node.js versions to build on | ||
node-version: [10.x, 12.x, 13.x, 14.x] | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
|
||
- name: Install dependencies | ||
run: npm install | ||
|
||
- name: Lint the project | ||
run: npm run lint | ||
|
||
- name: Build the project | ||
run: npm run build | ||
env: | ||
CI: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
node_modules | ||
.env | ||
dist | ||
homebridge-gsh-**.tgz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
node_modules | ||
.vscode | ||
.github | ||
server | ||
portal | ||
src | ||
scripts | ||
local-execution | ||
tsconfig.build.json | ||
tsconfig.json | ||
tslint.json | ||
nodemon.json | ||
.env | ||
homebridge-gsh-**.tgz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"recommendations": [ | ||
"dbaeumer.vscode-eslint" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"editor.tabSize": 2, | ||
"editor.insertSpaces": true, | ||
"files.eol": "\n", | ||
"editor.codeActionsOnSave": { | ||
"source.fixAll.tslint": true, | ||
"source.fixAll.eslint": true | ||
}, | ||
"editor.formatOnSave": true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
# Contributing | ||
|
||
Pull requests are welcome from everyone. | ||
|
||
This project is written in [TypeScript](https://www.typescriptlang.org/) and [Angular](https://angular.io/) for the server portal UI. | ||
|
||
## Getting Setup | ||
|
||
First, remove any globally installed versions of `homebridge-gsh` you may have installed on your development machine: | ||
|
||
``` | ||
npm uninstall -g homebridge-gsh | ||
``` | ||
|
||
Fork, then clone the repo: | ||
|
||
``` | ||
git clone [email protected]:your-username/homebridge-gsh.git | ||
``` | ||
|
||
Install npm dependencies for the plugin: | ||
|
||
``` | ||
npm install | ||
``` | ||
|
||
Build the plugin: | ||
|
||
``` | ||
npm run build:plugin | ||
``` | ||
|
||
Symlink your development directory to global: | ||
|
||
``` | ||
npm link | ||
``` | ||
|
||
You can now run `homebridge` and it will use `homebridge-gsh` from your development directory. |
Oops, something went wrong.