-
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(core): change structure project (#56)
- Loading branch information
Showing
99 changed files
with
2,141 additions
and
978 deletions.
There are no files selected for viewing
File renamed without changes.
File renamed without changes.
File renamed without changes.
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,28 @@ | ||
module.exports = { | ||
parser: "@typescript-eslint/parser", | ||
env: { | ||
node: true, | ||
es2021: true | ||
}, | ||
parserOptions: { | ||
ecmaVersion: 6, | ||
sourceType: "module" // Allows for the use of imports | ||
}, | ||
extends: [ | ||
"plugin:prettier/recommended", | ||
"plugin:@typescript-eslint/recommended", // Uses the recommended rules from the @typescript-eslint/eslint-plugin | ||
"plugin:import/warnings" | ||
], | ||
plugins: ["@typescript-eslint"], | ||
rules: { | ||
"@typescript-eslint/semicolon": "off", | ||
"@typescript-eslint/member-delimiter-style": "off", | ||
"@typescript-eslint/naming-convention": "warn", | ||
"@typescript-eslint/semi": "off", | ||
"no-throw-literal": "warn", | ||
curly: "warn", | ||
eqeqeq: "warn", | ||
semi: "off" | ||
}, | ||
ignorePatterns: ["**/*.d.ts"] | ||
} |
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 |
---|---|---|
|
@@ -160,27 +160,10 @@ title = "gitleaks config" | |
description = "ignore value fake" | ||
regexes = [ | ||
'''host=HOST''', | ||
'''--private-key={{.PRIVATE_KEY_FILE}}''', | ||
'''PASSWORD=XXXXXX''', | ||
] | ||
|
||
[[rules]] | ||
description = "Email" | ||
regex = '''[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,4}''' | ||
tags = ["email"] | ||
[rules.allowlist] | ||
description = "ignore emails" | ||
regexes = [ | ||
'''[a-zA-Z0-9._%+-][email protected]''', | ||
'''[a-zA-Z0-9._%+-][email protected]''', | ||
'''[email protected]''', | ||
'''[email protected]''', | ||
'''[email protected]''', | ||
'''[email protected]''', | ||
'''[email protected]''', | ||
'''[email protected]''', | ||
'''[email protected]''', | ||
'''[email protected]''', | ||
'''[email protected]''', | ||
] | ||
|
||
[[rules]] | ||
description = "High Entropy" | ||
|
@@ -222,29 +205,57 @@ title = "gitleaks config" | |
description = "Files with keys and credentials" | ||
file = '''(?i)(id_rsa|passwd|id_rsa.pub|pgpass)$''' | ||
tags = ["key", "files"] | ||
[rules.allowlist] | ||
description = "ignore some" | ||
files = ['''(.*pub|env)$'''] | ||
|
||
[[rules]] | ||
description = "Extension Files with keys and credentials" | ||
file = '''(.*?)(pub|pem|ppk|key)$''' | ||
tags = ["key", "files"] | ||
[rules.allowlist] | ||
description = "ignore file test" | ||
files = [ | ||
'''.*-test.*$''', | ||
] | ||
|
||
# Global allowlist | ||
[allowlist] | ||
description = "Whitelisted files" | ||
files = [ | ||
'''(.*?)(jpg|gif|png|doc|pdf|bin|mp3|mp4|mov|ttf|woff|woff2|eot|lock)$''', | ||
'''^\.gitignore$''', | ||
'''^\.gitleaks.toml$''', | ||
'''^yarn.lock$''', | ||
'''^vendor/(.*?)$''', | ||
'''^node_modules/(.*?)$''', | ||
] | ||
paths = [ | ||
'''^vendor/''', | ||
'''^bower_components/''', | ||
'''^public/''', | ||
'''^node_modules/''', | ||
'''^theme/''', | ||
] | ||
files = [ | ||
'''(.*?)(jpg|gif|png|doc|pdf|bin|mp3|mp4|mov|ttf|woff|woff2|eot|lock)$''', | ||
'''^\.gitignore$''', | ||
'''^\.gitleaks.toml$''', | ||
'''^yarn.lock$''', | ||
'''^vendor/(.*?)$''', | ||
'''^sonar-project.properties$''', | ||
'''^node_modules/(.*?)$''', | ||
] | ||
commits = [] | ||
|
||
[whitelist] | ||
description = "image and html allowlists" | ||
files = [ | ||
paths = [ | ||
'''^vendor/''', | ||
'''^bower_components/''', | ||
'''^public/''', | ||
'''^node_modules/''', | ||
'''^theme/''', | ||
] | ||
files = [ | ||
'''(.*?)(jpg|gif|png|doc|pdf|bin|mp3|mp4|mov|ttf|woff|woff2|eot|lock)$''', | ||
'''^\.gitignore$''', | ||
'''^\.gitleaks.toml$''', | ||
'''^\.gitignore$''', | ||
'''^yarn.lock$''', | ||
'''^sonar-project.properties$''', | ||
] | ||
|
||
commits = [] |
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,73 @@ | ||
# This is an example goreleaser.yaml file with some sane defaults. | ||
# Make sure to check the documentation at http://goreleaser.com | ||
project_name: zsh-rvm | ||
env: | ||
- GO111MODULE=on | ||
- REPO=github.com/hadenlabs/zsh-rvm | ||
before: | ||
hooks: | ||
- go mod download | ||
- go mod tidy | ||
- go mod vendor | ||
- go generate ./... | ||
|
||
# https://goreleaser.com/build/ | ||
builds: | ||
# Defaults to the project name. | ||
- id: default | ||
# ID of the build. | ||
env: | ||
- CGO_ENABLED=0 | ||
ldflags: | ||
- -s -w | ||
- -X "{{.Env.REPO}}/cmd.Version={{.Version}}" | ||
- -X "{{.Env.REPO}}/cmd.Commit={{.FullCommit}}" | ||
- -X "{{.Env.REPO}}/cmd.RepoURL={{.GitURL}}" | ||
- -X "{{.Env.REPO}}/cmd.BuildDate={{.Date}}" | ||
- -X "{{.Env.REPO}}/cmd.BuiltWithGoVersion={{.Env.GO_VERSION}}" | ||
- -X "{{.Env.REPO}}/cmd.BuiltBy={{.Env.BUILT_BY}}" | ||
goos: | ||
- darwin | ||
- linux | ||
goarch: | ||
- amd64 | ||
archives: | ||
- replacements: | ||
darwin: Darwin | ||
linux: Linux | ||
amd64: x86_64 | ||
builds: | ||
- default | ||
wrap_in_directory: true | ||
name_template: "{{.ProjectName}}-{{.Os}}-{{.Arch}}" | ||
format: tar.gz | ||
format_overrides: | ||
- goos: windows | ||
format: zip | ||
files: | ||
- LICENSE | ||
- README.md | ||
- CHANGELOG.md | ||
- config/**/* | ||
- systemd/* | ||
# https://goreleaser.com/snapshots/ | ||
snapshot: | ||
name_template: "dev@{{.ShortCommit}}" | ||
|
||
# https://goreleaser.com/checksum/ | ||
checksum: | ||
name_template: "{{ .ProjectName }}_{{ .Version }}_checksums.txt" | ||
algorithm: sha256 | ||
changelog: | ||
sort: asc | ||
filters: | ||
exclude: | ||
- "^docs:" | ||
- "^test:" | ||
release: | ||
github: | ||
owner: hadenlabs | ||
name: zsh-rvm | ||
draft: true | ||
prerelease: auto | ||
name_template: "{{.ProjectName}}-v{{.Version}}-{{.ShortCommit}}-{{.Date}}" |
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,12 @@ | ||
ignored: | ||
- DL3008 # Pin versions in apt get install. Instead of `apt-get install <package>` use `apt-get install <package>=<version>` | ||
- DL3013 # Pin versions in pip. Instead of `pip install <package>` use `pip install <package>==<version>` | ||
- DL3016 # Pin versions in npm. Instead of `npm install <package>` use `npm install <package>@<version> | ||
- DL3018 # Pin versions in apk add. Instead of `apk add <package>` use `apk add <package>=<version> | ||
- DL3028 # Pin versions in gem install. Instead of `gem install <gem>` use `gem install <gem>:<version>` | ||
|
||
- SC2086 # info: Double quote to prevent globbing and word splitting. | ||
|
||
# temp | ||
|
||
- DL4006 # Set the SHELL option -o pipefail before RUN with a pipe in it |
8 changes: 4 additions & 4 deletions
8
.github/linters/.lintstagedrc.js → .ci/linters/.lintstagedrc.js
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,10 +1,10 @@ | ||
const escape = require('shell-quote').quote | ||
const escape = require("shell-quote").quote | ||
|
||
module.exports = { | ||
'*.{ts,tsx,js,json,css}': (filenames) => [ | ||
"*.{ts,tsx,js,json,css}": (filenames) => [ | ||
...filenames.map((filename) => `prettier --check "${escape([filename])}"`), | ||
...filenames.map((filename) => `git add "${filename}"`) | ||
], | ||
'*.{ts,tsx,js,jsx}': ['eslint'], | ||
'*.{ts,tsx,css}': ['stylelint'] | ||
"*.{ts,tsx,js,jsx}": ["eslint"], | ||
"*.{ts,tsx,css}": ["stylelint"] | ||
} |
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
File renamed without changes.
File renamed without changes.
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 @@ | ||
plugin "aws" { | ||
enabled = true | ||
version = "0.26.0" | ||
source = "github.com/terraform-linters/tflint-ruleset-aws" | ||
} | ||
rule "terraform_deprecated_index" { | ||
enabled = true | ||
} | ||
rule "terraform_unused_declarations" { | ||
enabled = true | ||
} | ||
rule "terraform_comment_syntax" { | ||
enabled = true | ||
} | ||
rule "terraform_documented_outputs" { | ||
enabled = true | ||
} | ||
rule "terraform_documented_variables" { | ||
enabled = true | ||
} | ||
rule "terraform_typed_variables" { | ||
enabled = true | ||
} | ||
rule "terraform_naming_convention" { | ||
enabled = true | ||
} | ||
rule "terraform_required_version" { | ||
enabled = true | ||
} | ||
rule "terraform_standard_module_structure" { | ||
enabled = true | ||
} | ||
rule "terraform_required_providers" { | ||
enabled = false | ||
} | ||
rule "terraform_module_pinned_source" { | ||
enabled = true | ||
style = "semver" | ||
} |
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: | ||
line-length: | ||
max: 200 | ||
level: warning |
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,11 @@ | ||
download-external-modules: true | ||
evaluate-variables: true | ||
external-modules-download-path: .external_modules | ||
framework: | ||
- all | ||
no-guide: true | ||
output: cli | ||
quiet: true | ||
skip-fixes: true | ||
skip-suppressions: true | ||
soft-fail: true |
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.