Skip to content

Commit

Permalink
refactor!: project rewrite p1
Browse files Browse the repository at this point in the history
- rewrite programmatic api

Signed-off-by: Lexus Drumgold <[email protected]>
  • Loading branch information
unicornware committed Jan 22, 2025
1 parent 87130e1 commit 87bc625
Show file tree
Hide file tree
Showing 444 changed files with 20,845 additions and 22,707 deletions.
2 changes: 1 addition & 1 deletion .attw.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
"color": true,
"emoji": true,
"format": "ascii",
"ignoreRules": ["cjs-resolves-to-esm"],
"ignoreRules": ["cjs-resolves-to-esm", "internal-resolution-error"],
"summary": true
}
49 changes: 18 additions & 31 deletions .codecov.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@
---
codecov:
notify:
after_n_builds: 4
after_n_builds: 1
wait_for_ci: true
require_ci_to_pass: true

comment:
after_n_builds: 4
after_n_builds: 1
behavior: default
layout: header,diff,flags,components,tree,footer
require_base: false
Expand All @@ -27,23 +27,19 @@ component_management:
- component_id: cli
name: cli
paths:
- src/cli/**/*.ts
- component_id: config
name: config
paths:
- src/config/*.ts
- src/cli/**/*.mts
- component_id: internal
name: internal
paths:
- src/internal/*.ts
- src/internal/*.mts
- component_id: plugins
name: plugins
paths:
- src/plugins/**/*.ts
- src/plugins/*.mts
- component_id: utils
name: utils
paths:
- src/utils/*.ts
- src/utils/*.mts

coverage:
precision: 2
Expand Down Expand Up @@ -92,19 +88,7 @@ coverage:
threshold: 0%

flags:
node20:
carryforward: false
paths:
- src/
node19:
carryforward: false
paths:
- src/
node18:
carryforward: false
paths:
- src/
node16:
node23:
carryforward: false
paths:
- src/
Expand All @@ -113,16 +97,19 @@ github_checks:
annotations: true

ignore:
- '**/__mocks__/**'
- '**/__tests__/**'
- '**/index.ts'
- '**/*.d.mts'
- '**/__mocks__/'
- '**/__tests__/'
- '**/index.mts'
- '**/interfaces/'
- '**/types/'
- src/plugins/**/options.ts
- '!src/index.mts'
- src/internal/*.browser.mts

profiling:
critical_files_paths:
- src/cli/**/*.ts
- src/config/*.ts
- src/internal/create-context.ts
- src/make.ts
- src/cli/**/*.mts
- src/make.mts
- src/plugins/*.mts
- src/utils/load-build-config.mts
- src/utils/runnable-task.mts
11 changes: 6 additions & 5 deletions .commitlintrc.cts → .commitlintrc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,12 @@ import { scopes } from '@flex-development/commitlint-config'
const config: UserConfig = {
extends: ['@flex-development'],
rules: {
'scope-enum': [
Severity.Error,
'always',
scopes(['bundle', 'options', 'transpile'])
]
'scope-enum': [Severity.Error, 'always', scopes([
'bundle',
'chore',
'options',
'transpile'
])]
}
}

Expand Down
10 changes: 3 additions & 7 deletions .cspell.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@
"failFast": false,
"flagWords": [],
"ignorePaths": [
"**/*.log",
"**/*.patch",
"**/*.snap",
"**/*.wasm",
"**/.*ignore",
"**/.gitconfig",
"**/CHANGELOG.md",
Expand All @@ -26,15 +27,10 @@
".husky/_/",
".vscode/settings.json",
".yarn/",
"dist/",
"patches/",
"yarn.lock"
],
"ignoreRegExpList": [
"/@flex-development\\/.*/",
"/from\\s+(['\"]).*\\1/",
"import\\(.*\\)"
],
"ignoreRegExpList": [],
"ignoreWords": [],
"language": "en-US",
"patterns": [],
Expand Down
35 changes: 10 additions & 25 deletions .dictionary.txt
Original file line number Diff line number Diff line change
@@ -1,48 +1,33 @@
ardatan
atoi
attw
bdougie
booleanish
cefc
codecov
commitish
commitlintrc
dedupe
defu
dequal
dessant
devlop
dists
docast
dohm
dprint
emojify
esbuild
evanw
fbca
finalised
ggshield
gpgsign
groupby
hmarr
iife
infile
iterare
keyid
jchen
kaisugi
ksort
larsgw
lcov
lintstagedrc
memfs
mkbuild
mlly
nestjs
nocheck
npmrc
nvmrc
onrequest
pathe
pkgs
preid
reexporter
remarkrc
rollup
sarif
shfmt
swcrc
smob
toodles
tribonacci
tscu
Expand Down
68 changes: 26 additions & 42 deletions .dprint.jsonc
Original file line number Diff line number Diff line change
@@ -1,37 +1,33 @@
{
"$schema": "https://dprint.dev/schemas/v0.json",
"excludes": [
"!**/__fixtures__/**/dist/",
"!**/__fixtures__/**/node_modules/",
"!**/typings/**/dist/",
"!*.scratch.*",
"!scratch.*",
"**/*.patch",
"**/*.snap",
"**/*config.*.timestamp*",
"**/.temp/",
"**/.vercel/",
"**/__tests__/report.json",
"**/coverage/",
"**/dist/",
"**/node_modules",
"**/tsconfig*temp.json",
"**/CHANGELOG.md",
"**/LICENSE.md",
"**/RELEASE_NOTES.md",
".git/",
".husky/_/",
".yarn/",
"CHANGELOG.md",
"LICENSE.md",
"RELEASE_NOTES.md",
"yarn.lock"
],
"exec": {
"commands": [
{
"command": "node ./dprint/prettier.mjs {{file_path}}",
"exts": ["json5", "yaml", "yml"],
"command": "node --experimental-strip-types --experimental-transform-types ./dprint/prettier.mts {{file_path}}",
"exts": ["css", "html", "json5", "scss", "yaml", "yml"],
"stdin": true
},
{
"command": "node ./dprint/shfmt.mjs {{file_path}}",
"exts": ["sh", "txt", "zsh"],
"command": "node --experimental-strip-types --experimental-transform-types ./dprint/remark.mts {{file_path}}",
"exts": ["md", "mdx"],
"stdin": true
},
{
"command": "node --experimental-strip-types --experimental-transform-types ./dprint/shfmt.mts {{file_path}}",
"exts": ["sh", "zsh"],
"fileNames": [
".editorconfig",
".env",
Expand All @@ -42,7 +38,6 @@
".gitattributes",
".gitconfig",
".gitignore",
".markdownlintignore",
".npmrc",
".nvmrc",
"Brewfile",
Expand All @@ -52,49 +47,38 @@
],
"stdin": true
}
]
],
"cwd": "${configDir}"
},
"incremental": true,
"indentWidth": 2,
"json": {
"associations": ["**/*.{jsonc,json}"],
"array.preferSingleLine": false,
"commentLine.forceSpaceAfterSlashes": true,
"ignoreNodeCommentText": "dprint-ignore",
"object.preferSingleLine": false
"object.preferSingleLine": false,
"trailingCommas": "never"
},
"lineWidth": 80,
"markdown": {
"associations": ["**/*.{md,mdx}"],
"emphasisKind": "asterisks",
"ignoreDirective": "dprint-ignore",
"ignoreEndDirective": "dprint-ignore-end",
"ignoreFileDirective": "dprint-ignore-file",
"ignoreStartDirective": "dprint-ignore-start",
"lineWidth": 120,
"strongKind": "asterisks",
"textWrap": "maintain"
},
"newLineKind": "lf",
"plugins": [
"https://plugins.dprint.dev/typescript-0.87.1.wasm",
"https://plugins.dprint.dev/json-0.17.4.wasm",
"https://plugins.dprint.dev/markdown-0.16.0.wasm",
"https://plugins.dprint.dev/exec-0.4.3.json@42343548b8022c99b1d750be6b894fe6b6c7ee25f72ae9f9082226dd2e515072"
"https://plugins.dprint.dev/typescript-0.91.6.wasm",
"https://plugins.dprint.dev/json-0.19.3.wasm",
"https://plugins.dprint.dev/exec-0.5.0.json@8d9972eee71fa1590e04873540421f3eda7674d0f1aae3d7c788615e7b7413d0"
],
"typescript": {
"arrowFunction.useParentheses": "preferNone",
"binaryExpression.linePerExpression": false,
"binaryExpression.operatorPosition": "sameLine",
"binaryExpression.spaceSurroundingBitwiseAndArithmeticOperator": true,
"bracePosition": "sameLine",
"commentLine.forceSpaceAfterSlashes": true,
"commentLine.forceSpaceAfterSlashes": false,
"constructSignature.spaceAfterNewKeyword": true,
"constructor.spaceBeforeParentheses": false,
"constructorType.spaceAfterNewKeyword": true,
"doWhileStatement.spaceAfterWhileKeyword": true,
"enumDeclaration.memberSpacing": "maintain",
"exportDeclaration.forceMultiLine": false,
"exportDeclaration.forceMultiLine": "never",
"exportDeclaration.forceSingleLine": false,
"exportDeclaration.sortNamedExports": "maintain",
"exportDeclaration.spaceSurroundingNamedExports": true,
Expand All @@ -109,15 +93,15 @@
"ifStatement.spaceAfterIfKeyword": true,
"ignoreFileCommentText": "dprint-ignore-file",
"ignoreNodeCommentText": "dprint-ignore",
"importDeclaration.forceMultiLine": false,
"importDeclaration.forceMultiLine": "never",
"importDeclaration.forceSingleLine": false,
"importDeclaration.sortNamedImports": "maintain",
"importDeclaration.spaceSurroundingNamedImports": true,
"jsx.bracketPosition": "nextLine",
"jsx.forceNewLinesSurroundingContent": false,
"jsx.multiLineParens": "always",
"jsx.multiLineParens": "prefer",
"jsx.quoteStyle": "preferSingle",
"jsxExpressionContainer.spaceSurroundingExpression": true,
"jsxExpressionContainer.spaceSurroundingExpression": false,
"jsxSelfClosingElement.spaceBeforeSlash": true,
"memberExpression.linePerExpression": false,
"method.spaceBeforeParentheses": false,
Expand Down
10 changes: 1 addition & 9 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,8 @@ spaces_around_operators = true
tab_width = 2
trim_trailing_whitespace = true

# handlebars
[*.hbs]
max_line_length = 100

# markdown
[*.md]
[{*.md,*.mdx}]
max_line_length = 120

# shellscript
Expand All @@ -45,10 +41,6 @@ switch_case_indent = true
[*.snap]
max_line_length = 130

# xml
[*.xml]
max_line_length = 100

# yaml
[{*.yaml,*.yml}]
max_line_length = 100
3 changes: 3 additions & 0 deletions .env.vars
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# repository variables

GH_PROJECT_NUMBER=12
1 change: 1 addition & 0 deletions .env.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,4 @@
[ -f $PWD/.env.repo ] && source $PWD/.env.repo
HOMEBREW_BREWFILE=./Brewfile
NODE_NO_WARNINGS=1
NODE_OPTIONS='--experimental-strip-types --experimental-transform-types'
Loading

0 comments on commit 87bc625

Please sign in to comment.