mirror of
https://github.com/QWRK-ORG/qwrk-laconic-core.git
synced 2026-09-08 05:34:07 +00:00
chore: update pre-commit hooks to remove staged file references and clean up logger output
This commit is contained in:
+2
-2
@@ -3,11 +3,11 @@ pre-commit:
|
||||
commands:
|
||||
lint:
|
||||
glob: "*.{js,ts,jsx,tsx}"
|
||||
run: pnpm lint:fix {staged_files}
|
||||
run: pnpm lint:fix
|
||||
stage_fixed: true
|
||||
format:
|
||||
glob: "*.{js,ts,jsx,tsx}"
|
||||
run: pnpm format:fix {staged_files}
|
||||
run: pnpm format:fix
|
||||
stage_fixed: true
|
||||
typecheck:
|
||||
glob: "*.{ts,tsx}"
|
||||
|
||||
@@ -1,14 +0,0 @@
|
||||
pre-commit:
|
||||
commands:
|
||||
check:
|
||||
glob: "*.{js,ts,cjs,mjs,d.cts,d.mts,jsx,tsx,json,jsonc}"
|
||||
# run: npx @biomejs/biome check --write --no-errors-on-unmatched --files-ignore-unknown=true --colors=off {staged_files}
|
||||
run: pnpm biome format --write {staged_files}
|
||||
stage_fixed: true
|
||||
|
||||
pre-push:
|
||||
parallel: true
|
||||
commands:
|
||||
check:
|
||||
glob: "*.{js,ts,cjs,mjs,d.cts,d.mts,jsx,tsx,json,jsonc}"
|
||||
run: npx @biomejs/biome check --no-errors-on-unmatched --files-ignore-unknown=true --colors=off {push_files}
|
||||
+5
-16
@@ -23,20 +23,13 @@ const formatCommand = (cmd) => {
|
||||
|
||||
// Display a header for the command
|
||||
console.log(
|
||||
'\n' +
|
||||
chalk.gray(
|
||||
'╔═════════════════════════════════════════════════════════════════════════════╗'
|
||||
)
|
||||
`\n${chalk.gray('╔═════════════════════════════════════════════════════════════════════════════╗')}`
|
||||
)
|
||||
console.log(
|
||||
chalk.gray('║ ') +
|
||||
chalk.white.bold(`LEFTHOOK: ${formatCommand(command)}`) +
|
||||
chalk.gray(' ║')
|
||||
`${chalk.gray('║ ')}${chalk.white.bold(`LEFTHOOK: ${formatCommand(command)}`)}${chalk.gray(' ║')}`
|
||||
)
|
||||
console.log(
|
||||
chalk.gray(
|
||||
'╚═════════════════════════════════════════════════════════════════════════════╝\n'
|
||||
)
|
||||
`${chalk.gray('╚═════════════════════════════════════════════════════════════════════════════╝\n')}`
|
||||
)
|
||||
|
||||
// If we have files, display them
|
||||
@@ -66,16 +59,12 @@ try {
|
||||
|
||||
// Show success message
|
||||
console.log(
|
||||
'\n' +
|
||||
chalk.green.bold('✓ SUCCESS') +
|
||||
chalk.green(` ${formatCommand(command)} completed successfully`)
|
||||
`\n${chalk.green.bold('✓ SUCCESS')}${chalk.green(` ${formatCommand(command)} completed successfully`)}`
|
||||
)
|
||||
} catch (error) {
|
||||
// Show error message
|
||||
console.log(
|
||||
'\n' +
|
||||
chalk.red.bold('✗ ERROR') +
|
||||
chalk.red(` ${formatCommand(command)} failed`)
|
||||
`\n${chalk.red.bold('✗ ERROR')}${chalk.red(` ${formatCommand(command)} failed`)}`
|
||||
)
|
||||
process.exit(1)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user