Initial Commit

This commit is contained in:
Chase 2023-01-10 17:39:36 -06:00
commit 51aa6e1c93
Signed by: chase
GPG Key ID: 9EC29E797878008C
30 changed files with 5278 additions and 0 deletions

16
.editorconfig Normal file
View File

@ -0,0 +1,16 @@
# editorconfig.org
root = true
[*]
indent_style = space
indent_size = 4
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
[*.{yml,yaml}]
indent_size = 2
[*.json]
insert_final_newline = unset

16
.eslintrc.json Normal file
View File

@ -0,0 +1,16 @@
{
"env": {
"es2021": true,
"node": true,
"browser": false
},
"extends": [
"chase"
],
"parserOptions": {
"ecmaVersion": "latest",
"sourceType": "module"
},
"rules": {},
"globals": {}
}

1
.gitattributes vendored Normal file
View File

@ -0,0 +1 @@
* text=auto eol=lf

28
.github/ISSUE_TEMPLATE/bug-report.md vendored Normal file
View File

@ -0,0 +1,28 @@
---
name: Bug Report
about: Report incorrect or unexpected behavior
title: ''
labels: bug
assignees: ''
---
**Describe the bug**
A clear and concise description of what the bug is.
<!--
Tip: You can attach images or log files by clicking this area to highlight it and then dragging files into it.
-->
**To Reproduce**
Steps to reproduce the behavior:
1. Do '...'
**Expected behavior**
A clear and concise description of what you expected to happen.
**Screenshots**
If applicable, add screenshots to help explain your problem.
**Additional context**
Add any other context about the problem here.

2
.github/ISSUE_TEMPLATE/config.yml vendored Normal file
View File

@ -0,0 +1,2 @@
---
blank_issues_enabled: true

View File

@ -0,0 +1,14 @@
---
name: Feature Request
about: Suggest an idea for the project
title: ''
labels: enhancement
assignees: ''
---
**Describe the feature request you'd like**
A clear and concise description of what you want to have added.
**Additional context**
Add any other context or screenshots about the feature request here.

9
.github/PULL_REQUEST_TEMPLATE.md vendored Normal file
View File

@ -0,0 +1,9 @@
**Please describe the changes this PR makes and why it should be merged:**
<!--
Please move lines that apply to you out of the comment:
- Code changes have been fully tested, or there are no code changes
- This PR includes breaking changes (methods removed or renamed, parameters moved or removed)
- This PR **only** includes non-code changes, like changes to documentation, README, etc.
- I have linted this PR and it passes all tests
-->

3
.github/SECRETS.md vendored Normal file
View File

@ -0,0 +1,3 @@
# Secrets
* `GH_PAT` - A GitHub [Personal Access Token](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token) with `repo` permissions.

15
.github/SECURITY.md vendored Normal file
View File

@ -0,0 +1,15 @@
# Security Policy
## Supported Versions
The only supported version of this project is the latest commit. Nothing else is supported by us.
## Testing
If you believe you have found a vulnerability, be sure you test it in the latest commit.
## Reporting a Vulnerability
If you believe you have discovered a vulnerability or exploit and ensured it happens on the latest commit, please reach out to the project owner's email.
**Do not make a GitHub Issue for a security vulnerability.**

12
.github/dependabot.yml vendored Normal file
View File

@ -0,0 +1,12 @@
---
version: 2
updates:
- package-ecosystem: npm
directory: /
schedule:
interval: daily
- package-ecosystem: github-actions
directory: /
schedule:
interval: daily
open-pull-requests-limit: 10

13
.github/labeler.yml vendored Normal file
View File

@ -0,0 +1,13 @@
---
dependencies:
- package.json
- package-lock.json
meta:
- README.md
- LICENSE.md
- .gitignore
- .gitattributes
- .eslintrc.json
- .github/**/*
- .vscode/**/*

34
.github/labels.yml vendored Normal file
View File

@ -0,0 +1,34 @@
---
- name: "bug"
color: "d73a4a"
description: "Something isn't working"
- name: "dependencies"
color: "0052cc"
description: "Pull requests that update a dependency file"
- name: "documentation"
color: "0075ca"
description: "Improvements or additions to documentation"
- name: "duplicate"
color: "cfd8d7"
description: "This issue or pull request already exists"
- name: "enhancement"
color: "a22eef"
description: "New feature or request"
- name: "good first issue"
color: "7057ff"
description: "Good for newcomers"
- name: "help wanted"
color: "008672"
description: "Extra attention is needed"
- name: "invalid"
color: "e6e6fa"
description: "This doesn't seem right"
- name: "meta"
color: "ffffff"
description: "Changes that aren't directly related to any source"
- name: "question"
color: "cc317c"
description: "Further information is needed"
- name: "wontfix"
color: "ffffff"
description: "This will not be worked on"

2
.github/linters/.hadolint.yaml vendored Normal file
View File

@ -0,0 +1,2 @@
---
ignored: [DL3018]

5
.github/linters/.htmlhintrc vendored Normal file
View File

@ -0,0 +1,5 @@
{
"title-require": false,
"id-class-value": false,
"head-script-disabled": false
}

6
.github/linters/.stylelintrc.json vendored Normal file
View File

@ -0,0 +1,6 @@
{
"rules": {
"selector-class-pattern": null,
"no-missing-end-of-source-newline": null
}
}

4
.github/linters/.yaml-lint.yml vendored Normal file
View File

@ -0,0 +1,4 @@
---
rules:
line-length:
max: 260

16
.github/workflows/auto-merge.yml vendored Normal file
View File

@ -0,0 +1,16 @@
---
name: "📦️ Auto Merge Dependency Updates"
on:
- pull_request_target
jobs:
run:
runs-on: ubuntu-latest
steps:
- uses: tjenkinson/gh-action-auto-merge-dependency-updates@v1
with:
allowed-actors: dependabot[bot]
allowed-update-types: devDependencies:minor, devDependencies:patch, devDependencies:major
merge-method: squash
repo-token: ${{ secrets.GITHUB_TOKEN }}

13
.github/workflows/labeler.yml vendored Normal file
View File

@ -0,0 +1,13 @@
---
name: "🏷️ Pull Request Labeler"
on:
- pull_request_target
jobs:
labeler:
runs-on: ubuntu-latest
steps:
- uses: actions/labeler@v4
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"
sync-labels: true

20
.github/workflows/labelsync.yml vendored Normal file
View File

@ -0,0 +1,20 @@
---
name: "🏷️ Label Sync"
on:
schedule:
- cron: "0 0 * * *"
workflow_dispatch:
push:
branches:
- main
paths:
- ".github/labels.yml"
jobs:
labelsync:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: "🏷️ Label Sync"
uses: crazy-max/ghaction-github-labeler@v4
with:
github-token: ${{ secrets.GH_PAT }}

39
.github/workflows/linter.yml vendored Normal file
View File

@ -0,0 +1,39 @@
---
name: "🎨 Lint"
on:
push:
branches: [master, main]
pull_request:
branches: [master, main]
jobs:
lint:
runs-on: ubuntu-latest
if: github.actor != 'dependabot[bot]' && !contains(github.event.head_commit.message, '[skip lint]')
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: "📦️ Install Dependencies"
run: |
npm install
- name: "🎨 ESLint"
run: npx eslint . --ext .js,.jsx,.ts,.tsx
- name: "🎨 Super-Linter"
uses: github/super-linter/slim@v4
env:
VALIDATE_ALL_CODEBASE: true
DEFAULT_BRANCH: main
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
VALIDATE_JAVASCRIPT_ES: false
VALIDATE_JAVASCRIPT_STANDARD: false
VALIDATE_TYPESCRIPT_ES: false
VALIDATE_TYPESCRIPT_STANDARD: false
VALIDATE_JSCPD: false
VALIDATE_MARKDOWN: false
VALIDATE_NATURAL_LANGUAGE: false

22
.github/workflows/lock.yml vendored Normal file
View File

@ -0,0 +1,22 @@
---
name: "🔒 Lock Resolved Issues/PRs"
on:
pull_request:
types:
- closed
issues:
types:
- closed
jobs:
lock:
runs-on: ubuntu-latest
steps:
- uses: chxseh/action-lock-unlock@v1.0.1
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
number: ${{ github.event.pull_request.number || github.event.issue.number }}
lock: true
lock-reason: resolved

21
.github/workflows/unlock.yml vendored Normal file
View File

@ -0,0 +1,21 @@
---
name: "🔓 Unlock Reopened Issues/PRs"
on:
pull_request:
types:
- reopened
issues:
types:
- reopened
jobs:
unlock:
runs-on: ubuntu-latest
steps:
- uses: chxseh/action-lock-unlock@v1.0.1
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
number: ${{ github.event.pull_request.number || github.event.issue.number }}
lock: false

10
.gitignore vendored Normal file
View File

@ -0,0 +1,10 @@
# Packages
node_modules/
# Private Data
config.json
.env
# Misc
*.bak
.DS_Store

9
.vscode/extensions.json vendored Normal file
View File

@ -0,0 +1,9 @@
{
"recommendations": [
"dbaeumer.vscode-eslint",
"github.vscode-pull-request-github",
"eamodio.gitlens",
"aaron-bond.better-comments",
"EditorConfig.EditorConfig"
]
}

14
.vscode/settings.json vendored Normal file
View File

@ -0,0 +1,14 @@
{
"javascript.format.insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces": true,
"javascript.format.placeOpenBraceOnNewLineForControlBlocks": true,
"javascript.format.placeOpenBraceOnNewLineForFunctions": true,
"editor.formatOnPaste": true,
"editor.formatOnSave": true,
"editor.formatOnType": true,
"editor.detectIndentation": false,
"editor.tabSize": 4,
"files.eol": "\n",
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
}
}

21
LICENSE.md Normal file
View File

@ -0,0 +1,21 @@
MIT License
Copyright (c) 2023 chxseh
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

12
README.md Normal file
View File

@ -0,0 +1,12 @@
<div align="center">
<h1>lidarr-true-singles<br>
<a href="https://chse.dev/donate"><img alt="Donate" src="https://badges.chse.dev:/badge/Donate_To_This_Project-brightgreen"></a>
<a href="https://github.com/chxseh/lidarr-true-singles/actions/workflows/linter.yml"><img alt="GitHub Actions Status" src="https://github.com/chxseh/lidarr-true-singles/actions/workflows/linter.yml/badge.svg"></a>
<a href="https://github.com/chxseh/lidarr-true-singles/stargazers"><img alt="Stars" src="https://badges.chse.dev:/github/stars/chxseh/lidarr-true-singles"></a>
<a href="https://github.com/chxseh/lidarr-true-singles/issues"><img alt="Issues" src="https://badges.chse.dev:/github/issues/chxseh/lidarr-true-singles"></a>
<a href="https://github.com/chxseh/lidarr-true-singles/pulls"><img alt="Pull Requests" src="https://badges.chse.dev:/github/issues-pr/chxseh/lidarr-true-singles"></a>
<a href="https://github.com/chxseh/lidarr-true-singles/network"><img alt="Forks" src="https://badges.chse.dev:/github/forks/chxseh/lidarr-true-singles"></a>
<a href="https://github.com/chxseh/lidarr-true-singles/blob/main/LICENSE.md"><img alt="License" src="https://badges.chse.dev:/github/license/chxseh/lidarr-true-singles"></a>
</h1></div>
Automatically unmonitor promotional singles from lidarr.

4863
package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

36
package.json Normal file
View File

@ -0,0 +1,36 @@
{
"name": "lidarr-true-singles",
"version": "1.0.0",
"description": "Automatically unmonitor promotional singles from lidarr.",
"main": "./src/app.js",
"engines": {
"node": ">=16.14.0"
},
"type": "module",
"scripts": {
"start": "node ./src/app.js",
"lint": "eslint --fix --ext .js,.jsx,.ts,.tsx ./src"
},
"repository": {
"type": "git",
"url": "git+https://github.com/chxseh/lidarr-true-singles.git"
},
"keywords": [],
"author": "Chase <c@chse.dev> (https://chse.dev)",
"contributors": [
""
],
"license": "MIT",
"bugs": {
"url": "https://github.com/chxseh/lidarr-true-singles/issues"
},
"homepage": "https://github.com/chxseh/lidarr-true-singles#readme",
"dependencies": {},
"devDependencies": {
"eslint": "8.31.0",
"eslint-config-chase": "1.0.5",
"eslint-plugin-import": "2.26.0",
"eslint-plugin-jsdoc": "39.6.4",
"eslint-plugin-unicorn": "45.0.2"
}
}

2
src/app.js Normal file
View File

@ -0,0 +1,2 @@
/* eslint-disable unicorn/no-empty-file */
// Todo.