Skip to content
snowkit

kits / developer-config

v1.0.0

Developer Config

Copy-in config for Node.js, TypeScript and Python repos: formatting, linting, git hooks, GitHub Actions CI, Dependabot and a dev container.

developer-configREADME.md

Markdown · 3.7 KB

Developer Config

Version 1.0.0

A set of current, sensible config files you can copy into a Node.js, TypeScript or Python repository: editor settings, formatting, linting, git rules, two git hooks, GitHub Actions workflows, Dependabot and a dev container. The files contain no comments, so they stay clean in your project. Every choice is explained in setup-guide.md.

Who it's for

  • Developers starting a new repository who want a solid baseline in minutes
  • Teams tidying up an older repository one step at a time
  • Maintainers who want CI with least-privilege permissions and dependency checks from day one

How to use it in 5 minutes

  1. Copy .editorconfig, .gitignore and .gitattributes into the root of your repository.
  2. Copy the formatter and linter files for your language: .prettierrc.json, .prettierignore and eslint.config.mjs for Node.js and TypeScript, ruff.toml for Python. Install the packages listed in setup-guide.md.
  3. Copy the hooks folder and run git config core.hooksPath hooks.
  4. Copy the .github folder and delete the workflows and Dependabot blocks for languages you do not use.
  5. Commit on a branch, open a pull request and watch the workflows run.

Read the "Single-language projects" and "Adopting gradually" sections of setup-guide.md before you apply this to an existing codebase.

File map

FileWhat it is
README.mdThis guide
LICENSE.txtMIT licence
CHANGELOG.mdVersion history
setup-guide.mdWhat every file does, what to change, what to delete for one language and how to adopt it step by step
.editorconfigShared editor settings: UTF-8, LF, indentation, final newline
.prettierrc.jsonPrettier formatting settings
.prettierignoreFiles and folders Prettier skips
eslint.config.mjsESLint flat config for TypeScript and JavaScript with type-aware rules
ruff.tomlRuff lint and format settings for Python
pyproject-snippet.mdThe same Python settings for pyproject.toml, plus a dev dependency group and pytest settings
.gitignoreIgnore rules for Node.js and Python projects, with secrets first
.gitattributesLine ending normalisation, binary files and lock file diffs
hooks/pre-commitBlocks secret-looking files and private keys, runs format and lint checks on staged files
hooks/commit-msgChecks the commit message against Conventional Commits
.github/workflows/node-ci.ymlNode.js CI: install, format check, lint, type check, test and build on current LTS versions
.github/workflows/python-ci.ymlPython CI: Ruff format and lint, pytest on supported Python versions
.github/workflows/dependency-review.ymlFails pull requests that add dependencies with known high-severity vulnerabilities
.github/workflows/codeql.ymlCodeQL code scanning for JavaScript, TypeScript, Python and workflow files
.github/dependabot.ymlWeekly grouped dependency updates for npm, pip and GitHub Actions
.devcontainer/devcontainer.jsonA dev container with Node.js and Python that installs dependencies and enables the hooks

A note on limits

These files are a starting point, not a standard every project must follow. Tool versions move: check the release notes of ESLint, typescript-eslint, Ruff and the GitHub Actions used here when you adopt the kit, and let Dependabot keep the action versions current. Hooks run on each developer's machine and can be skipped, and the secret checks only catch common file names and key formats, so keep CI, branch protection and a secret scanner in place as well. Dependency review and CodeQL on private repositories depend on your GitHub plan.

Licence

MIT License. See LICENSE.txt.