Skip to content

Commit

Permalink
upgrade build tooling (#22)
Browse files Browse the repository at this point in the history
  • Loading branch information
quisido authored Jul 18, 2022
1 parent dabea2f commit e3e92f3
Show file tree
Hide file tree
Showing 25 changed files with 9,121 additions and 1,133 deletions.
9 changes: 9 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
root = true

[*]
charset = utf-8
end_of_line = lf
indent_size = 2
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true
22 changes: 22 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
/**/*.gz
/.git/
/.idea/
/.yarn/cache/
/.yarn/sdks/
/.yarn/unplugged/
/.yarn/build-state.yml
/.yarn/install-state.gz
/dist/
/jest/
/node_modules/
/*.iml
/*.md
/.eslintcache
/.pnp.cjs
/.pnp.data.json
/.pnp.js
/.pnp.loader.mjs
/.tsbuildinfo
/LICENSE
/yarn.lock
.DS_Store
87 changes: 87 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
{
"parser": "@typescript-eslint/parser",
"root": true,

"env": {
"jest": true,
"node": true
},

"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended",
"plugin:@typescript-eslint/recommended-requiring-type-checking",
"plugin:jsx-a11y/strict",
"plugin:prettier/recommended",
"plugin:react/jsx-runtime",
"plugin:react/recommended",
"plugin:react-hooks/recommended",
"@monorepo-template/react-fixable",
"@monorepo-template/react-strict",
"@monorepo-template/react-typescript",
"@monorepo-template/typescript",
"@monorepo-template/typescript-fixable",
"@monorepo-template/typescript-strict",
"prettier"
],

"overrides": [
{
"files": ["*.cjs", "*.js", "*.jsx"],
"extends": "@monorepo-template/typescript/cjs"
},

{
"files": ["*.cjs", "*.js", "*.jsx", "*.mjs"],
"extends": [
"@monorepo-template/typescript/js",
"@monorepo-template/typescript-fixable/js"
]
},

{
"files": ["*.eslintrc.cjs"],
"extends": "@monorepo-template/typescript/eslint"
},

{
"files": ["*.json"],
"extends": [
"@monorepo-template/react-typescript/json",
"@monorepo-template/typescript/json",
"@monorepo-template/typescript-fixable/json"
]
},

{
"files": ["*.ts", "*.tsx"],
"extends": ["@monorepo-template/typescript/ts"]
}
],

"parserOptions": {
"extraFileExtensions": [".json"],
"project": "./tsconfig.eslint.json",
"useJSXTextNode": true,
"warnOnUnsupportedTypeScriptVersion": false,
"ecmaFeatures": {
"experimentalObjectRestSpread": true,
"jsx": false
}
},

"plugins": [
"@typescript-eslint",
"jsx-a11y",
"prettier",
"react",
"react-hooks"
],

"settings": {
"react": {
"version": "detect"
}
}
}
85 changes: 85 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
/.yarn/releases/* binary
* text eol=lf
*.3gpp binary
*.3gp binary
*.7z binary
*.ai binary
*.as binary
*.asf binary
*.asx binary
*.avi binary
*.bat text eol=crlf
*.bmp binary
*.cmd text eol=crlf
*.css text diff=css
*.eot binary
*.eps binary
*.exe binary
*.fla binary
*.flv binary
*.gif binary
*.gifv binary
*.gz binary
*.htm text diff=html
*.html text diff=html
*.ico binary
*.jar binary
*.jng binary
*.jp2 binary
*.jpg binary
*.jpeg binary
*.jpx binary
*.jxr binary
*.kar binary
*.lock text -diff
*.m4a binary
*.m4v binary
*.map text -diff
*.markdown text diff=markdown
*.md text diff=markdown
*.mdown text diff=markdown
*.mdwn text diff=markdown
*.mid binary
*.midi binary
*.mkd text diff=markdown
*.mkdn text diff=markdown
*.mng binary
*.mov binary
*.mp3 binary
*.mp4 binary
*.mpeg binary
*.mpg binary
*.ogg binary
*.ogv binary
*.otf binary
*.pdf binary
*.php text diff=php
*.png binary
*.ps1 text eol=crlf
*.psb binary
*.psd binary
*.py text diff=python
*.pyc binary
*.ra binary
*.rar binary
*.rb text diff=ruby
*.scss text diff=css
*.svgz binary
*.swc binary
*.swf binary
*.tar binary
*.tif binary
*.tiff binary
*.ttf binary
*.xhtml text diff=html
*.wbmp binary
*.webp binary
*.webm binary
*.woff binary
*.woff2 binary
*.zip binary
.pnp.cjs text -diff
.pnp.js text -diff
.pnp.loader.mjs text -diff
package-lock.json text -diff
pnpm-lock.yaml text eol=lf -diff
30 changes: 30 additions & 0 deletions .github/workflows/analyze.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Analyze

jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
languages: ${{ matrix.language }}
- name: Autobuild
uses: github/codeql-action/autobuild@v1
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
strategy:
fail-fast: false
matrix:
language: ['javascript']

on:
pull_request:
push:
branches: [main]
29 changes: 29 additions & 0 deletions .github/workflows/cron--weekly.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Cron (weekly)

jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
languages: ${{ matrix.language }}
- name: Autobuild
uses: github/codeql-action/autobuild@v1
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
strategy:
fail-fast: false
matrix:
language: ['javascript']

on:
schedule:
- cron: '15 20 * * 1'
Loading

0 comments on commit e3e92f3

Please sign in to comment.