Commit ad8fce4
authored
chore: migrate to Nix-based development and CI workflows [ENG-11657] (#43)
* chore(nix): add flake
* chore(ci): migrate to Nix-based CI workflows
Migrate all CI workflows to use Nix for consistent, reproducible builds
following the pattern from stackone-ai-node repository.
Changes:
- Add .github/actions/setup-nix for reusable Nix setup
- Create unified ci.yml workflow (replaces test.yml and lint.yml)
- Add nix-flake.yml for flake validation
- Update docs.yml and release.yml to use Nix
- Enhance flake.nix shellHook to auto-install dependencies
- Remove separate test.yml and lint.yml workflows
Benefits:
- Consistent environment between local dev and CI
- Faster builds with Cachix caching
- Single unified CI workflow
- Automatic dependency installation via shellHook
* chore(nix): migrate to git-hooks.nix and treefmt
Replace pre-commit with Nix-native git-hooks.nix and treefmt for better
integration with the Nix development environment.
Changes:
- Add git-hooks.nix and treefmt-nix flake inputs
- Configure treefmt with ruff (check + format) and nixfmt
- Set up git-hooks with treefmt and mypy pre-commit hooks
- Remove .pre-commit-config.yaml
- Remove pre-commit from dev dependencies
- Update Makefile to remove pre-commit install step
- Format code with treefmt (ruff)
Benefits:
- Consistent formatting via `nix fmt`
- Automatic git hook installation in nix develop
- No Python-based pre-commit dependency
- Faster hook execution
- Better Nix ecosystem integration
* docs: add Nix installation and development setup to README
Add Nix as the recommended development setup with instructions for
entering the dev environment, formatting, and running checks.
Benefits of using Nix:
- Automatic dependency installation
- Git hooks auto-configured
- Consistent environment across platforms
* chore: add .pre-commit-config.yaml to .gitignore
This file is auto-generated by git-hooks.nix and should not be tracked.
* fix(nix): disable pre-commit check in flake check, keep mypy hook
Configure git-hooks to skip the check during 'nix flake check' because
mypy requires the Python environment which isn't available in the Nix
sandbox.
The mypy hook still works locally in 'nix develop' where the Python
environment is available. Mypy is also run in CI via ci.yml.
Changes:
- Set pre-commit.check.enable = false to skip flake check
- Keep mypy hook enabled for local development
- Treefmt check still runs in flake check
* chore: migrate from Makefile to justfile
Replace Makefile with justfile for better command runner experience.
Add just to Nix devShell for development environment.
* chore: enable prettier for markdown/json
* chore: format with treefmt
Apply consistent formatting across the repository using nix fmt:
- YAML files: standardise string quoting to double quotes
- Markdown files: add blank lines before lists for proper rendering
- Remove trailing whitespace in CLAUDE.md1 parent d50d5fb commit ad8fce4
File tree
19 files changed
+447
-226
lines changed- .github
- actions/setup-nix
- workflows
- stackone_ai
- feedback
19 files changed
+447
-226
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
| 15 | + | |
| 16 | + | |
16 | 17 | | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
| 18 | + | |
| 19 | + | |
22 | 20 | | |
23 | 21 | | |
24 | | - | |
| 22 | + | |
25 | 23 | | |
26 | 24 | | |
27 | 25 | | |
28 | | - | |
29 | | - | |
| 26 | + | |
| 27 | + | |
30 | 28 | | |
31 | 29 | | |
32 | 30 | | |
| |||
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
23 | | - | |
| 23 | + | |
| 24 | + | |
24 | 25 | | |
25 | 26 | | |
26 | | - | |
| 27 | + | |
27 | 28 | | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
| 29 | + | |
32 | 30 | | |
33 | 31 | | |
34 | 32 | | |
35 | | - | |
36 | | - | |
| 33 | + | |
37 | 34 | | |
38 | 35 | | |
39 | 36 | | |
40 | 37 | | |
41 | 38 | | |
42 | 39 | | |
43 | | - | |
44 | | - | |
| 40 | + | |
| 41 | + | |
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
This file was deleted.
0 commit comments