Skip to content

Commit

Permalink
chore(linting): fix linting problems with JSCPD
Browse files Browse the repository at this point in the history
  • Loading branch information
Falcion committed Dec 24, 2024
1 parent fff8723 commit 8a37c3d
Show file tree
Hide file tree
Showing 13 changed files with 76 additions and 75 deletions.
22 changes: 0 additions & 22 deletions .github/DISCUSSION_TEMPLATE/01_general.yml

This file was deleted.

37 changes: 37 additions & 0 deletions .github/DISCUSSION_TEMPLATE/02_accessibility.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
title: '[ACCESS]: '
labels: ['discussion', 'discussions/accessibility']
body:
- type: dropdown
attributes:
label: Select accessibility topic
description: Please specify the area of accessibility you want to discuss.
options:
- 'UI/UX Accessibility'
- 'Web Content Accessibility Guidelines (WCAG)'
- 'Screen Reader Support'
- 'Keyboard Navigation'
- 'Color Contrast Issues'
- 'Other Accessibility Concerns'
validations:
required: true
- type: textarea
attributes:
label: Description
description: Provide a detailed explanation of the accessibility topic or issue.
validations:
required: true
- type: checkboxes
attributes:
label: Affected platforms
description: Select the platforms where this accessibility issue is observed.
options:
- 'Web Application'
- 'Desktop Application'
- 'Mobile Application'
- 'Other'
validations:
required: true
- type: input
attributes:
label: Suggested Solutions (Optional)
description: If you have any suggestions for addressing the issue, provide them here.
22 changes: 0 additions & 22 deletions .github/DISCUSSION_TEMPLATE/03_accessibility.yml

This file was deleted.

8 changes: 4 additions & 4 deletions .github/ISSUE_TEMPLATE/01_bug_report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ body:
id: contact
attributes:
label: Contact details
description: If possible, write down the contact information if you need additional communication, if you want contact via “github”, leave this field blank.
description: If possible, write down the contact information for this bug report. If you need additional communication, if you want contact via “github”, leave this field blank.
placeholder: example@domain.com
validations:
required: false
Expand Down Expand Up @@ -54,23 +54,23 @@ body:
id: terms
attributes:
label: Code of conduct
description: By submitting this issue, you agree to follow our code of conduct.
description: By submitting this bug report, you agree to follow our code of conduct.
options:
- label: I agree to follow this project's code of conduct
required: true
- type: checkboxes
id: issue-policy
attributes:
label: Issue policy
description: By submitting this issue, you agree to follow our issue policy.
description: By submitting this bug report, you agree to follow our issue policy.
options:
- label: I agree to follow this project's issue policy
required: true
- type: checkboxes
id: security-policy
attributes:
label: Security policy
description: By submitting this issue, you agree to follow our security policy.
description: By submitting this bug report, you agree to follow our security policy.
options:
- label: I agree to follow this project's security policy.
required: true
10 changes: 4 additions & 6 deletions .github/ISSUE_TEMPLATE/02_feature_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,8 @@ body:
id: contact
attributes:
label: Contact details
description: If possible, write down the contact information if you need additional communication, if you want contact via “github”, leave this field blank.
description: If possible, write down the contact information for this feature request. If you need additional communication, if you want contact via “github”, leave this field blank.
placeholder: example@domain.com
validations:
required: false
- type: textarea
id: what-wanted
attributes:
Expand All @@ -43,23 +41,23 @@ body:
id: terms
attributes:
label: Code of conduct
description: By submitting this issue, you agree to follow our code of conduct.
description: By submitting this feature request, you agree to follow our code of conduct.
options:
- label: I agree to follow this project's code of conduct
required: true
- type: checkboxes
id: issue-policy
attributes:
label: Issue policy
description: By submitting this issue, you agree to follow our issue policy.
description: By submitting this feature request, you agree to follow our issue policy.
options:
- label: I agree to follow this project's issue policy
required: true
- type: checkboxes
id: security-policy
attributes:
label: Security policy
description: By submitting this issue, you agree to follow our security policy.
description: By submitting this feature request, you agree to follow our security policy.
options:
- label: I agree to follow this project's security policy.
required: true
14 changes: 11 additions & 3 deletions .github/ISSUE_TEMPLATE/03_question.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ body:
id: contact
attributes:
label: Contact details
description: If possible, write down the contact information if you need additional communication, if you want contact via “github”, leave this field blank.
description: If possible, write down the contact information for this question. If you need additional communication, if you want contact via “github”, leave this field blank.
placeholder: example@domain.com
validations:
required: false
Expand All @@ -28,19 +28,27 @@ body:
value: ...
validations:
required: true
- type: checkboxes
id: terms
attributes:
label: Code of conduct
description: By submitting this question, you agree to follow our code of conduct.
options:
- label: I agree to follow this project's code of conduct
required: true
- type: checkboxes
id: issue-policy
attributes:
label: Issue policy
description: By submitting this issue, you agree to follow our issue policy.
description: By submitting this question, you agree to follow our issue policy.
options:
- label: I agree to follow this project's issue policy
required: true
- type: checkboxes
id: security-policy
attributes:
label: Security policy
description: By submitting this issue, you agree to follow our security policy.
description: By submitting this question, you agree to follow our security policy.
options:
- label: I agree to follow this project's security policy.
required: true
8 changes: 3 additions & 5 deletions .github/ISSUE_TEMPLATE/04_documentation_issue.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,8 @@ body:
id: contact
attributes:
label: Contact details
description: If possible, write down the contact information if you need additional communication, if you want contact via “github”, leave this field blank.
description: If possible, write down the contact information for this documentation issue. If you need additional communication, if you want contact via “github”, leave this field blank.
placeholder: example@domain.com
validations:
required: false
- type: input
id: where-issue
attributes:
Expand All @@ -40,15 +38,15 @@ body:
id: terms
attributes:
label: Code of conduct
description: By submitting this issue, you agree to follow our code of conduct.
description: By submitting this documentation issue, you agree to follow our code of conduct.
options:
- label: I agree to follow this project's code of conduct
required: true
- type: checkboxes
id: issue-policy
attributes:
label: Issue policy
description: By submitting this issue, you agree to follow our issue policy.
description: By submitting this documentation issue, you agree to follow our issue policy.
options:
- label: I agree to follow this project's issue policy
required: true
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -126,3 +126,6 @@ ts*.buildinfo*

# Python VENV
**/venv/

# JSCPD reports
report/
14 changes: 2 additions & 12 deletions .husky/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,18 +37,8 @@ Next one are popular errors and fails thrown by hooks:

### Error-code "001"

Code of this exception can be fixed by setting up and installing WSL or set up
instructions of renaming executables:

- Rename "npm" into "npm.cmd" within your setups;
- Rename "npx" into "npx.cmd" within your setups;

Source:\
<https://github.com/desktop/desktop/issues/12562#issuecomment-1007154382>

> [!Note]
> If this not helping, go through entire algorithm of fixing hooks from HUSKY and
> setting up virtual machine for UNIX-subsystem.
Read more about this here:\
[Error "001"](./docs/h001.md)

### Error-code "127"

Expand Down
6 changes: 6 additions & 0 deletions .jscpd.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"threshold": 0,
"reporters": ["html", "console", "badge"],
"ignore": ["**/__snapshots__/**", "**/venv/**", "**/node_modules/**", "./report/**"],
"absolute": true
}
5 changes: 4 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,10 @@
},
"yaml.schemas": {
"yamllint": ["https://json.schemastore.org/yamllint.json"],
"https://json.schemastore.org/yamllint.json": "/.github/ISSUE_TEMPLATE/config.yml"
"https://json.schemastore.org/yamllint.json": [
"/.github/ISSUE_TEMPLATE/config.yml",
"/.github/ISSUE_TEMPLATE/shared_sections.yml"
]
},
"files.autoSave": "onFocusChange",
"editor.formatOnSave": true,
Expand Down
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,7 @@
"@electron/lint-roller": "^3.0.0",
"@eslint/eslintrc": "^3.2.0",
"@eslint/js": "^9.15.0",
"@jscpd/badge-reporter": "^4.0.1",
"@npmcli/package-json": "^6.0.1",
"@types/fs-extra": "^11.0.4",
"@types/minimist": "^1.2.5",
Expand Down Expand Up @@ -215,6 +216,7 @@
"github-wiki-sidebar": "^1.1.1",
"globals": "^15.12.0",
"husky": "^9.1.7",
"jscpd": "^4.0.5",
"lint": "^1.1.2",
"lint-staged": "^15.2.10",
"markdownlint": "^0.37.0",
Expand Down

0 comments on commit 8a37c3d

Please sign in to comment.