Skip to content

Instantly share code, notes, and snippets.

@travishorn
Last active June 2, 2023 13:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save travishorn/219c4b855af09812c9a269a1487f792f to your computer and use it in GitHub Desktop.
Save travishorn/219c4b855af09812c9a269a1487f792f to your computer and use it in GitHub Desktop.
The git pre-commit hook and the VS Code settings I use when developing Svelte apps.

The git pre-commit hook and the VS Code settings I use when developing Svelte apps.

#!/bin/sh
# Lint files before committing
npm run lint
# Exit with the appropriate exit code based on the lint script's result
if [[ $? -ne 0 ]]; then
exit 1
fi
{
"editor.insertSpaces": false,
"editor.rulers": [100],
"explorer.sortOrder": "filesFirst",
"workbench.editor.labelFormat": "short",
"workbench.tree.indent": 18
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment