Skip to content

Commit

Permalink
repo maintenance
Browse files Browse the repository at this point in the history
  • Loading branch information
bwp91 committed Oct 12, 2024
1 parent 3933316 commit 87e0e7b
Show file tree
Hide file tree
Showing 15 changed files with 361 additions and 278 deletions.
5 changes: 3 additions & 2 deletions .github/ISSUE_TEMPLATE/1_verification-request.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
name: Plugin Verification Request
description: Request verification for your plugin
description: Request verification for your plugin.
title: 'Verification Request: homebridge-'
labels:
- request-verification
- pending
body:
- type: markdown
Expand All @@ -11,7 +12,7 @@ body:
attributes:
value: >
Please double check the [requirements
list](https://github.com/homebridge/verified#requirements) before
list](https://github.com/homebridge/plugins#requirements) before
submitting a request.
- type: input
id: plugin-name
Expand Down
5 changes: 3 additions & 2 deletions .github/ISSUE_TEMPLATE/2_icon-request.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
name: Plugin Icon Request
description: Request an icon for your verified plugin
description: Request an icon for your verified plugin.
title: 'Plugin Icon Request: homebridge-'
labels:
- request-icon
body:
- type: markdown
attributes:
Expand All @@ -10,7 +12,6 @@ body:
value: |
- A plugin must be **verified** before requesting an icon.
- Icons can only be request by the developer of a plugin.
- Verification checks will be performed on plugins requesting an icon.
- type: input
id: plugin-name
attributes:
Expand Down
21 changes: 21 additions & 0 deletions .github/ISSUE_TEMPLATE/3_maintain-request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: Plugin Maintain Request
description: Request to maintain an abandoned plugin.
title: 'Plugin Maintain Request: homebridge-'
labels:
- request-maintain
body:
- type: markdown
attributes:
value: '## Basic Details'
- type: input
id: plugin-name
attributes:
label: Plugin Name
description: The name of the plugin you would like to maintain.
placeholder: homebridge-xyz
validations:
required: true
- type: textarea
attributes:
label: References
description: References to other plugins you have developed or have helped maintain.
37 changes: 37 additions & 0 deletions .github/ISSUE_TEMPLATE/4_abandon-request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Plugin Abandon Request
description: Request to transfer your plugin into Homebridge ownership.
title: 'Abandon Request: homebridge-'
labels:
- request-abandon
body:
- type: markdown
attributes:
value: '## Basic Details'
- type: markdown
attributes:
value: |
- You must be the developer of the plugin to request abandonment.
- You must be willing to transfer the GitHub repository to the Homebridge organization.
- You must be willing to transfer the NPM package to the Homebridge organization.
- Another developer may request to maintain the plugin after it has been abandoned.
- type: input
id: plugin-name
attributes:
label: Plugin Name
description: The name of your plugin as it appears on NPM. For example `homebridge-xyz` or `@scope/homebridge-xyz`.
placeholder: homebridge-xyz
validations:
required: true
- type: input
attributes:
label: Link To GitHub Repo
placeholder: https://github.com/homebridge/homebridge-xyz
validations:
required: true
- type: markdown
attributes:
value: '## More Information'
- type: textarea
attributes:
label: More Information
description: Please provide any additional information that you want to include.
4 changes: 2 additions & 2 deletions .github/workflows/issue-labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,15 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: actions-ecosystem/action-add-labels@v1
if: ${{ startsWith(github.event.comment.body, '/check') }}
if: ${{ startsWith(github.event.comment.body, '/check') && contains(github.event.issue.labels.*.name, 'request-verification') }}
with:
labels: pending
review_remove_labels:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions-ecosystem/action-remove-labels@v1
if: ${{ startsWith(github.event.comment.body, '/check') }}
if: ${{ startsWith(github.event.comment.body, '/check') && contains(github.event.issue.labels.*.name, 'request-verification') }}
with:
github_token: ${{ secrets.github_token }}
labels: |
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/label-commenter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: Label Commenter
if: ${{ contains(github.event.issue.labels.*.name, 'request-verification') }}
uses: peaceiris/actions-label-commenter@v1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/plugin-checks-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ on:
jobs:
check-plugin:
runs-on: ubuntu-latest
if: github.event_name == 'issues' || (github.event_name == 'issue_comment' &&
github.event.comment.body == '/check') || (github.event_name == 'workflow_dispatch' &&
inputs.plugin)
if: (github.event_name == 'issues' && contains(github.event.issue.labels.*.name, 'request-verification')) ||
(github.event_name == 'issue_comment' && github.event.comment.body == '/check' && contains(github.event.issue.labels.*.name, 'request-verification')) ||
(github.event_name == 'workflow_dispatch' && inputs.plugin)
steps:
- uses: actions/checkout@v4
- name: Install Dependencies & Build
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/plugin-checks-schedule.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Plugin Checks (Schedule)
on:
workflow_dispatch:
schedule:
- cron: '0 0,6,12,18 * * *'
- cron: '0 0,12 * * *'

jobs:
check-plugin:
Expand Down
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ These verification requirements were last updated on 2023-12-08. Existing verifi

## How To Request Verification

If you would like your plugin verified, please open an [issue](https://github.com/homebridge/verified/issues/new/choose) on this repository and fill in the template. The Homebridge project team will then review your plugin and provide constructive feedback if required.
If you would like your plugin verified, please open an [issue](https://github.com/homebridge/plugins/issues/new/choose) on this repository and fill in the template. The Homebridge project team will then review your plugin and provide constructive feedback if required.

If you feel that your plugin should replace the verification status of an existing plugin, let us know and this will be dealt with on an individual basis.

Expand Down Expand Up @@ -101,16 +101,16 @@ A plugin installed via a bundle from this repo can be downloaded and installed i

### How The Bundle Generation Process Works

Every 30 minutes, a job is executed using GitHub Actions to check for updates made to any [verified Homebridge plugins](https://homebridge.io/w/Verified-Plugins).
Every 24 hours, a job is executed using GitHub Actions to check for updates made to any [verified Homebridge plugins](https://homebridge.io/w/Verified-Plugins).

Plugins that require updates are then:

1. Installed using `npm` in a clean work directory, post install scripts are disabled;
2. then a `.tar.gz` bundle is created for the plugin, including all it's dependencies;
3. then a `.sha256` checksum file is generated for the bundle;
4. finally the resulting tarball and checksum file are uploaded to the [Homebridge Plugin Repo](https://github.com/homebridge/plugin-repo/releases/tag/v1).
4. finally the resulting tarball and checksum file are uploaded to [this repo](https://github.com/homebridge/plugins/releases/tag/v1.0.0).

The two most recent versions of a plugin are retained in the [Homebridge Plugin Repo](https://github.com/homebridge/plugin-repo/releases/tag/v1), older versions are purged automatically.
The two most recent versions of a plugin are retained in [this repo](https://github.com/homebridge/plugins/releases/tag/v1.0.0), older versions are purged automatically.

### How Plugins Are Installed Via Bundles

Expand Down Expand Up @@ -141,9 +141,9 @@ If at any step, the process fails, the Homebridge UI will fall back to using `np

This project may impact the download stats for plugins provided by the NPM registry.

As such download stats are available via the [download-statistics.json](https://github.com/homebridge/plugin-repo/releases/download/v1/download-statistics.json) file. This file contains the total downloads from this repo for each verified plugin, as well as the download count for each version (including old versions that have been purged).
As such download stats are available via the [download-statistics.json](https://github.com/homebridge/plugins/releases/download/v1.0.0/download-statistics.json) file. This file contains the total downloads from this repo for each verified plugin, as well as the download count for each version (including old versions that have been purged).

The `download-statistics.json` file is updated every 30 minutes.
The `download-statistics.json` file is updated every 24 hours.

If you are accessing the file programmatically, you will need add a `nonce` query string to the URL to prevent it being redirected to an older (deleted) version of the file. E.g. `/download-statistics.json?nonce=1657193776`.

Expand Down
1 change: 1 addition & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ export default antfu({
'unused-imports/no-unused-vars': ['error', { caughtErrors: 'none' }],
},
typescript: true,
yaml: true,
formatters: {
markdown: true,
},
Expand Down
Loading

0 comments on commit 87e0e7b

Please sign in to comment.