-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #120 from sakithb/rewrite
[WIP] Rewriting the internals of how the extension works
- Loading branch information
Showing
73 changed files
with
9,073 additions
and
5,010 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,13 @@ | ||
# EditorConfig is awesome: https://EditorConfig.org | ||
|
||
root = true | ||
|
||
[*] | ||
charset = utf-8 | ||
end_of_line = lf | ||
insert_final_newline = true | ||
indent_style = space | ||
indent_size = 2 | ||
|
||
[*.{js,ts,css}] | ||
indent_size = 4 |
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,117 @@ | ||
{ | ||
"root": true, | ||
"extends": ["eslint:recommended", "plugin:@typescript-eslint/recommended", "plugin:import/recommended", "plugin:import/typescript"], | ||
"plugins": ["@typescript-eslint"], | ||
"parser": "@typescript-eslint/parser", | ||
"env": { | ||
"es2021": true | ||
}, | ||
"parserOptions": { | ||
"ecmaVersion": 2022, | ||
"sourceType": "module" | ||
}, | ||
"globals": { | ||
"ARGV": "readonly", | ||
"Debugger": "readonly", | ||
"GIRepositoryGType": "readonly", | ||
"globalThis": "readonly", | ||
"imports": "readonly", | ||
"Intl": "readonly", | ||
"log": "readonly", | ||
"logError": "readonly", | ||
"pkg": "readonly", | ||
"print": "readonly", | ||
"printerr": "readonly", | ||
"window": "readonly", | ||
"TextEncoder": "readonly", | ||
"TextDecoder": "readonly", | ||
"console": "readonly", | ||
"setTimeout": "readonly", | ||
"setInterval": "readonly", | ||
"clearTimeout": "readonly", | ||
"clearInterval": "readonly" | ||
}, | ||
"rules": { | ||
"import/extensions": ["error", "ignorePackages"], | ||
"import/no-unresolved": "off", | ||
"max-len": [ | ||
"warn", | ||
{ | ||
"code": 140, | ||
"ignoreComments": true, | ||
"ignoreStrings": true, | ||
"ignoreTemplateLiterals": true, | ||
"ignoreRegExpLiterals": true | ||
} | ||
], | ||
"no-use-before-define": [ | ||
"error", | ||
{ | ||
"functions": false, | ||
"classes": true, | ||
"variables": true, | ||
"allowNamedExports": true | ||
} | ||
], | ||
"no-restricted-globals": [ | ||
"error", | ||
{ | ||
"name": "Debugger", | ||
"message": "Internal use only" | ||
}, | ||
{ | ||
"name": "GIRepositoryGType", | ||
"message": "Internal use only" | ||
}, | ||
{ | ||
"name": "log", | ||
"message": "Use debugLog()" | ||
}, | ||
{ | ||
"name": "logError", | ||
"message": "Use errorLog()" | ||
} | ||
], | ||
"no-restricted-properties": [ | ||
"error", | ||
{ | ||
"object": "imports", | ||
"property": "format", | ||
"message": "Use template strings" | ||
}, | ||
{ | ||
"object": "pkg", | ||
"property": "initFormat", | ||
"message": "Use template strings" | ||
}, | ||
{ | ||
"object": "Lang", | ||
"property": "copyProperties", | ||
"message": "Use Object.assign()" | ||
}, | ||
{ | ||
"object": "Lang", | ||
"property": "bind", | ||
"message": "Use arrow notation or Function.prototype.bind()" | ||
}, | ||
{ | ||
"object": "Lang", | ||
"property": "Class", | ||
"message": "Use ES6 classes" | ||
} | ||
], | ||
"no-restricted-syntax": [ | ||
"error", | ||
{ | ||
"selector": "MethodDefinition[key.name=\"_init\"] CallExpression[arguments.length<=1][callee.object.type=\"Super\"][callee.property.name=\"_init\"]", | ||
"message": "Use constructor() and super()" | ||
} | ||
], | ||
"no-constant-condition": [ | ||
"warn", | ||
{ | ||
"checkLoops": false | ||
} | ||
] | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
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 @@ | ||
name: Lint and format | ||
|
||
on: | ||
push: | ||
branches: [ "main" ] | ||
pull_request: | ||
branches: [ "main" ] | ||
|
||
jobs: | ||
lint: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
- name: Install packages | ||
uses: pnpm/action-setup@v2 | ||
with: | ||
version: 8 | ||
run_install: true | ||
|
||
- name: Lint | ||
run: ./mediacontrols.sh lint | ||
format: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
- name: Install packages | ||
uses: pnpm/action-setup@v2 | ||
with: | ||
version: 8 | ||
run_install: true | ||
|
||
- name: Format | ||
run: ./mediacontrols.sh format |
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -1,6 +1,3 @@ | ||
*.compiled | ||
*.zip | ||
.vscode | ||
builds | ||
dist | ||
node_modules | ||
dist | ||
.vscode |
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 |
---|---|---|
@@ -1,12 +1,6 @@ | ||
{ | ||
"trailingComma": "es5", | ||
"tabWidth": 4, | ||
"indent_size": 4, | ||
"semi": true, | ||
"singleQuote": false, | ||
"indent_style": "space", | ||
"useTabs": false, | ||
"printWidth": 120, | ||
"arrowParens": "always" | ||
"printWidth": 120, | ||
"bracketSameLine": true, | ||
"quoteProps": "consistent", | ||
"singleQuote": 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
Oops, something went wrong.