This repository has been archived by the owner on Aug 1, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
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 #2 from swrlab/dev/prettier-0-2-0
fix: update prettier config
- Loading branch information
Showing
16 changed files
with
1,943 additions
and
88 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
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,8 @@ | ||
{ | ||
"parserOptions": { | ||
"ecmaVersion": 2020 | ||
}, | ||
"root": true, | ||
"plugins": ["@swrlab/eslint-plugin-swr"], | ||
"extends": ["plugin:@swrlab/eslint-plugin-swr/recommended"] | ||
} |
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 @@ | ||
version: 2 | ||
updates: | ||
- package-ecosystem: 'npm' | ||
directory: '/' | ||
open-pull-requests-limit: 10 | ||
schedule: | ||
interval: 'weekly' | ||
day: 'sunday' | ||
- package-ecosystem: 'github-actions' | ||
directory: '/' | ||
open-pull-requests-limit: 10 | ||
schedule: | ||
interval: 'weekly' | ||
day: 'sunday' |
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,7 @@ | ||
--- | ||
extends: default | ||
|
||
rules: | ||
document-start: disable | ||
line-length: | ||
max: 120 |
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,19 +1,46 @@ | ||
--- | ||
name: Lint code | ||
name: Linter | ||
|
||
on: [push] | ||
on: | ||
pull_request: | ||
|
||
env: | ||
DEFAULT_BRANCH: main | ||
EDITORCONFIG_FILE_NAME: /.editorconfig | ||
IGNORE_GITIGNORED_FILES: true | ||
JAVASCRIPT_DEFAULT_STYLE: prettier | ||
JAVASCRIPT_ES_CONFIG_FILE: /.eslintrc.json | ||
LINTER_RULES_PATH: / | ||
LOG_LEVEL: VERBOSE | ||
MARKDOWN_CONFIG_FILE: /.markdownlint.yaml | ||
NODE_VERSION: 18 | ||
VALIDATE_ALL_CODEBASE: true | ||
YAML_CONFIG_FILE: /.github/linters/.yamllint.yaml | ||
|
||
jobs: | ||
build: | ||
name: Lint Code Base | ||
runs-on: ubuntu-latest | ||
|
||
timeout-minutes: 70 | ||
steps: | ||
- name: Checkout Code | ||
uses: actions/checkout@v2 | ||
- name: 👀 Checkout repo | ||
uses: actions/checkout@v3 | ||
|
||
- name: ⛺️ Install Node.js | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: ${{ env.NODE_VERSION }} | ||
cache: 'yarn' | ||
cache-dependency-path: '**/yarn.lock' | ||
|
||
- name: 📦 Install Dependencies | ||
run: yarn | ||
|
||
- name: Lint Code Base | ||
uses: docker://github/super-linter:v2.2.0 | ||
- name: 📚 Lint Code Base | ||
uses: docker://github/super-linter:v4 | ||
with: | ||
context: . | ||
cache-from: type=gha | ||
cache-to: type=gha,mode=max | ||
env: | ||
VALIDATE_ALL_CODEBASE: true | ||
VALIDATE_ANSIBLE: false | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
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 +1,2 @@ | ||
node_modules/ | ||
node_modules/ | ||
.DS_Store |
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,34 @@ | ||
# see config https://github.com/DavidAnson/markdownlint#optionsconfig | ||
# see example file https://github.com/DavidAnson/markdownlint/blob/main/schema/.markdownlint.yaml | ||
# see rules https://github.com/markdownlint/markdownlint/blob/master/docs/RULES.md | ||
|
||
# Default state for all rules | ||
default: true | ||
|
||
# Unordered list style | ||
MD004: true | ||
|
||
MD007: | ||
# Unordered list indentation | ||
indent: 2 | ||
|
||
# MD013/line-length - Line length | ||
MD013: | ||
# Number of characters | ||
line_length: 808 | ||
|
||
MD026: | ||
# List of not allowed | ||
punctuation: '.,;:!。,;:' | ||
|
||
# Ordered list item prefix | ||
MD029: false | ||
|
||
# Allow inline HTML | ||
MD033: false | ||
|
||
# Emphasis used instead of a heading | ||
MD036: false | ||
|
||
# Error on blank lines | ||
blank_lines: 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 |
---|---|---|
@@ -1,3 +1,3 @@ | ||
module.exports = { | ||
...require("./index"), | ||
}; | ||
...require('./index'), | ||
} |
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,7 @@ | ||
Copyright 2020 SWR Audio Lab | ||
|
||
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. |
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,37 @@ | ||
# SWR Prettier config | ||
|
||
- [SWR Prettier config](#swr-prettier-config) | ||
- [Installation](#installation) | ||
- [Editor Config](#editor-config) | ||
|
||
## Installation | ||
|
||
Step 1: Install [npm package](https://www.npmjs.com/package/@swrlab/swr-prettier-config) | ||
|
||
```shell | ||
npm install @swrlab/swr-prettier-config --save-dev | ||
``` | ||
|
||
or | ||
|
||
```shell | ||
yarn add @swrlab/swr-prettier-config -D | ||
``` | ||
|
||
Step 2: Include in `package.json`: | ||
|
||
```json | ||
{ | ||
"prettier": "@swrlab/swr-prettier-config" | ||
} | ||
``` | ||
|
||
Or create a `.prettierrc.json` file with a link: | ||
|
||
```json | ||
"@swrlab/swr-prettier-config" | ||
``` | ||
|
||
## Editor Config | ||
|
||
This repository also contains a [`.editorconfig`](./.editorconfig) file. Consider this version as the main and copy it to other repositories where needed. This should ensure that the same copy is used everywhere. |
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
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,22 +1,26 @@ | ||
{ | ||
"name": "@swrlab/swr-prettier-config", | ||
"version": "0.1.2", | ||
"description": "SWR Prettier config.", | ||
"version": "0.2.0", | ||
"description": "SWR Audio Lab Prettier config", | ||
"license": "MIT", | ||
"main": "index.js", | ||
"keywords": [ | ||
"prettier", | ||
"swrlab" | ||
], | ||
"files": [ | ||
"index.js" | ||
], | ||
"license": "ISC", | ||
"author": "SWR Audio Lab <[email protected]>", | ||
"main": "index.js", | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/swrlab/swr-prettier-config" | ||
}, | ||
"bugs": "https://github.com/swrlab/swr-prettier-config/issues", | ||
"homepage": "https://github.com/swrlab/swr-prettier-config#readme", | ||
"devDependencies": { | ||
"@swrlab/eslint-plugin-swr": "0.2.0", | ||
"eslint": "^8.21.0" | ||
}, | ||
"scripts": {} | ||
} | ||
} |
Oops, something went wrong.