Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: Add Are The Types Wrong, Improve Turbo Caching for Fake Root #5

Merged
merged 1 commit into from
Apr 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,8 @@
"jsonc",
"typescript",
"typescriptreact"
]
],
"files.associations": {
"turbo.json": "jsonc"
}
}
Binary file modified bun.lockb
Binary file not shown.
5 changes: 3 additions & 2 deletions internals/eslint-config/source/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ export default {
reportUnusedDisableDirectives: 'error',
},
rules: {
'@typescript-eslint/consistent-type-definitions': ['warn', 'type'],
'@typescript-eslint/no-unused-vars': [
'warn',
{
Expand All @@ -37,7 +38,7 @@ export default {
json: tseslint.config(
{
files: ['**/*.json'],
ignores: ['**/tsconfig*.json'],
ignores: ['**/tsconfig*.json', '**/turbo.json'],
languageOptions: {
parser: jsoncEslintParser,
},
Expand All @@ -61,7 +62,7 @@ export default {
},
},
{
files: ['**/tsconfig*.json'],
files: ['**/tsconfig*.json', '**/turbo.json'],
languageOptions: {
parser: jsoncEslintParser,
},
Expand Down
1 change: 0 additions & 1 deletion internals/eslint-config/turbo.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
"pipeline": {
"build": {
"inputs": ["./scripts/**", "./source/**", "tsconfig.*"],
"outputMode": "new-only",
"outputs": ["./dist/**"]
}
}
Expand Down
49 changes: 15 additions & 34 deletions internals/fake-root/turbo.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,47 +4,28 @@
"pipeline": {
"check:eslint": {
"inputs": [
"../../**/*.{cjs,js,mjs,json,mjs,mts,ts}",
"!../../internals/**/*",
"!../../packages/**/*",
"../../*.{cjs,js,mjs,json,mjs,mts,ts}",
"../../.vscode/**/*",
"../../eslint.config.mjs"
],
"outputMode": "new-only",
"outputs": ["./dist/**"]
]
},
"check:prettier": {
"check:knip": {
"inputs": [
"../../**/*.{cjs,js,mjs,json,mjs,mts,ts}",
"!../../packages/**/*",
"../../eslint.config.mjs"
],
"outputMode": "new-only",
"outputs": ["./dist/**"]
"../../internals/*/scripts/**/*",
"../../internals/*/source/**/*",
"../../knip.json",
"../../packages/*/scripts/**/*",
"../../packages/*/source/**/*"
]
},
"check:prettier": {
"inputs": ["../../*.{cjs,js,mjs,json,mjs,mts,ts}", "../../.vscode/**/*"]
},
"download": {},
"fix:eslint": {
"inputs": [
"../../**/*.{cjs,js,mjs,json,mjs,mts,ts}",
"!../../internals/**/*",
"!../../packages/**/*",
"../../eslint.config.mjs"
],
"outputMode": "new-only",
"outputs": ["./dist/**"]
"inputs": ["../../*.{cjs,js,mjs,json,mjs,mts,ts}", "../../.vscode/**/*"]
},
"fix:prettier": {
"inputs": [
"../../**/*.{cjs,js,mjs,json,mjs,mts,ts}",
"!../../packages/**/*",
"../../eslint.config.mjs"
],
"outputMode": "new-only",
"outputs": ["./dist/**"]
},
"watch": {
"cache": false,
"dependsOn": ["^build", "download"],
"persistent": true
"inputs": ["../../*.{cjs,js,mjs,json,mjs,mts,ts}", "../../.vscode/**/*"]
}
}
}
1 change: 1 addition & 0 deletions knip.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"$schema": "https://unpkg.com/knip@5/schema.json",
"ignore": ["dist/**"],
"ignoreBinaries": ["prettier", "publint"],
"ignoreDependencies": ["@arethetypeswrong/cli"],
"workspaces": {
"internals/*": {
"entry": ["scripts/*.ts", "source/index.ts"],
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"devDependencies": {
"@arethetypeswrong/cli": "^0.15.3",
"@skyblock-finance/eslint-config": "*",
"@types/bun": "latest",
"eslint": "^9.0.0",
"knip": "^5.9.4",
"nodemon": "^3.1.0",
Expand All @@ -20,6 +20,7 @@
"scripts": {
"build": "turbo run build",
"check": "turbo run check",
"check:arethetypeswrong": "turbo run check:arethetypeswrong",
"check:eslint": "turbo run check:eslint",
"check:knip": "turbo run check:knip",
"check:prettier": "turbo run check:prettier",
Expand Down
3 changes: 2 additions & 1 deletion packages/schemas/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
"zod": "^3.22.4"
},
"devDependencies": {
"@types/bun": "latest",
"@types/json-stable-stringify": "^1.0.36",
"@types/lodash": "^4.14.188",
"@types/node": "^18.11.9",
"json-stable-stringify": "^1.1.1",
"lodash": "^4.17.21",
"tslog": "^4.9.2"
Expand All @@ -34,6 +34,7 @@
},
"scripts": {
"build": "rm -rf dist && tsc --build",
"check:arethetypeswrong": "bun --bun run attw --pack .",
"check:eslint": "bun run eslint --max-warnings=0 .",
"check:prettier": "bun --bun run --cwd ../.. prettier --check packages/schemas",
"check:publint": "bun --bun run publint",
Expand Down
2 changes: 1 addition & 1 deletion packages/schemas/scripts/download-data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { Logger } from 'tslog'

export const log = new Logger()

interface Common {
type Common = {
name: string
}

Expand Down
1 change: 0 additions & 1 deletion packages/schemas/turbo.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
"pipeline": {
"build": {
"inputs": ["./source/**", "tsconfig.json"],
"outputMode": "new-only",
"outputs": ["./dist/**"]
},
"download": {
Expand Down
9 changes: 8 additions & 1 deletion turbo.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,23 @@
"globalDependencies": ["bun.lockb"],
"pipeline": {
"build": {
"dependsOn": ["^build"]
"dependsOn": ["^build"],
"outputMode": "new-only"
},
"check": {
"dependsOn": [
"check:arethetypeswrong",
"check:eslint",
"check:knip",
"check:prettier",
"check:publint"
]
},
"check:arethetypeswrong": {
"dependsOn": ["build"],
"inputs": ["dist/**", "package.json"],
"outputMode": "new-only"
},
"check:eslint": {
"dependsOn": ["@skyblock-finance/eslint-config#build"],
"inputs": [
Expand Down
Loading