Skip to content
Open
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
2 changes: 0 additions & 2 deletions .envrc
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
#!/bin/bash

use flake
55 changes: 55 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
# Reusable CI of nullkomma projects, called by their push.yml.
name: nullkomma CI
on:
workflow_call:
inputs:
visibility:
description: FlakeHub visibility (public, unlisted or private); empty skips publishing.
type: string
default: ""
deploy:
description: Run `nix run .#deploy` on pushes to the default branch.
type: boolean
default: false
secrets:
CLOUDFLARE_ACCOUNT_ID:
required: false
CLOUDFLARE_API_TOKEN:
required: false
jobs:
DeterminateCI:
uses: DeterminateSystems/ci/.github/workflows/workflow.yml@main
permissions:
contents: read
id-token: write
with:
visibility: ${{ inputs.visibility }}
fail-fast: false
runner-map: |
{
"aarch64-darwin": "macos-latest",
"aarch64-linux": "ubuntu-24.04-arm",
"x86_64-linux": "ubuntu-latest"
}
flake-checker:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: DeterminateSystems/flake-checker-action@v14
with:
fail-mode: true
deploy:
if: inputs.deploy && github.event_name == 'push' && github.ref_name == github.event.repository.default_branch
needs: DeterminateCI
runs-on: ubuntu-latest
permissions:
contents: read
id-token: write
steps:
- uses: actions/checkout@v7
- uses: DeterminateSystems/determinate-nix-action@v3
- uses: DeterminateSystems/flakehub-cache-action@v3
- run: nix run .#deploy
env:
CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }}
23 changes: 6 additions & 17 deletions .github/workflows/cron.yml
Original file line number Diff line number Diff line change
@@ -1,24 +1,13 @@
name: Maintenance
on:
workflow_dispatch:
schedule:
- cron: "0 0 * * 0" # runs weekly on Sunday at 01:00
- cron: "0 0 * * 0" # weekly, Sunday 00:00 UTC
workflow_dispatch:
jobs:
nix-maintenance:
name: Nix Maintenance
runs-on: ubuntu-latest
nullkomma:
uses: ./.github/workflows/maintenance.yml
permissions:
id-token: "write"
contents: "write"
contents: write
id-token: write
issues: write
pull-requests: write
steps:
- uses: actions/checkout@v6
- uses: DeterminateSystems/determinate-nix-action@main
- uses: DeterminateSystems/flake-checker-action@main
- uses: DeterminateSystems/update-flake-lock@main
with:
pr-title: "Update flake.lock"
pr-labels: |
dependencies
automated
24 changes: 24 additions & 0 deletions .github/workflows/maintenance.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Maintenance workflow called by nullkomma's own cron.yml.
name: nullkomma maintenance
on:
workflow_call:
jobs:
update-flake-lock:
runs-on: ubuntu-latest
permissions:
contents: write
id-token: write
issues: write
pull-requests: write
steps:
- uses: actions/checkout@v7
- uses: DeterminateSystems/determinate-nix-action@v3
- uses: DeterminateSystems/flake-checker-action@v14
- name: Append available R snapshots
run: python3 tools/update-r-snapshots.py
- uses: DeterminateSystems/update-flake-lock@v29
with:
pr-title: Update flake.lock
pr-labels: |
dependencies
automated
27 changes: 6 additions & 21 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
@@ -1,31 +1,16 @@
name: CI
on:
pull_request:
workflow_dispatch:
push:
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
DeterminateCI:
uses: DeterminateSystems/ci/.github/workflows/workflow.yml@main
nullkomma:
uses: ./.github/workflows/ci.yml
permissions:
id-token: "write"
contents: "read"
contents: read
id-token: write
with:
visibility: public
fail-fast: false
runner-map: |
{
"aarch64-darwin": "macos-latest",
"aarch64-linux": "ubuntu-24.04-arm",
"x86_64-linux": "ubuntu-latest"
}
flake-checker:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Check Nix flake Nixpkgs inputs
uses: DeterminateSystems/flake-checker-action@v12
with:
fail-mode: true
visibility: "public"
14 changes: 11 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
**/*.quarto_ipynb
/.quarto/
/_book/
/_site/
.direnv/
result
/.quarto/
**/*.quarto_ipynb
_site/
result-*
.claude/
# Initialized files
!/.envrc
!/.github/workflows/push.yml
!/.gitignore
!/.vscode/extensions.json
!/.vscode/settings.json
7 changes: 6 additions & 1 deletion .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
{
"recommendations": ["arrterian.nix-env-selector", "jnoortheen.nix-ide"]
"recommendations": [
"arrterian.nix-env-selector",
"ibecker.treefmt-vscode",
"jnoortheen.nix-ide",
"quarto.quarto"
]
}
30 changes: 19 additions & 11 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,22 +1,30 @@
{
"nixEnvSelector.nixFile": "${workspaceFolder}/flake.nix",
"nixEnvSelector.useFlakes": true,
"nixEnvSelector.suggestion": false,
"editor.defaultFormatter": "ibecker.treefmt-vscode",
"nix.enableLanguageServer": true,
"nix.formatterPath": [
"treefmt",
"--stdin",
"{file}"
],
"nix.hiddenLanguageServerErrors": [
"textDocument/definition",
"textDocument/completion",
"textDocument/documentHighlight"
],
"nix.serverPath": "nixd",
"nix.serverSettings": {
"nixd": {
"formatting": {
"command": ["treefmt", "--stdin", "{file}"]
"command": [
"treefmt",
"--stdin",
"{file}"
]
}
}
},
"nix.formatterPath": ["treefmt", "--stdin", "{file}"],
"nix.hiddenLanguageServerErrors": [
"textDocument/definition",
"textDocument/completion",
"textDocument/documentHighlight"
],
"editor.defaultFormatter": "ibecker.treefmt-vscode",
"nixEnvSelector.nixFile": "${workspaceFolder}/flake.nix",
"nixEnvSelector.suggestion": false,
"nixEnvSelector.useFlakes": true,
"notebook.defaultFormatter": "ibecker.treefmt-vscode"
}
1 change: 0 additions & 1 deletion Makefile

This file was deleted.

Loading
Loading