Skip to content

Commit

Permalink
fix ci's
Browse files Browse the repository at this point in the history
  • Loading branch information
molarmanful committed Jan 21, 2025
1 parent d279467 commit 56f2690
Show file tree
Hide file tree
Showing 4 changed files with 52 additions and 8 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
---
name: build
on:
push:
branches: [main]
paths:
- bited-build.toml
- src/**
- flake.nix
- flake.lock
- default.nix
- .github/workflows/build.yml
pull_request:
branches: [main]
paths:
- bited-build.toml
- src/**
- flake.nix
- flake.lock
- default.nix
- .github/workflows/build.yml
concurrency:
group: ${{ github.ref }}
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
with:
ref: main
persist-credentials: false
fetch-depth: 0
- uses: nixbuild/nix-quick-install-action@v29
- uses: DeterminateSystems/magic-nix-cache-action@main
- run: nix build .#kirsch
- name: artifacts
uses: actions/upload-artifact@v4
with:
name: kirsch
path: result/share/fonts
4 changes: 1 addition & 3 deletions .github/workflows/pub.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,6 @@ jobs:
- uses: actions/checkout@v4
with:
ref: master
persist-credentials: false
fetch-depth: 0
- run: echo -n ${{ github.ref_name }} > VERSION
- uses: pnpm/action-setup@v3
with:
version: '*'
Expand All @@ -29,6 +26,7 @@ jobs:
- run: pnpm i
- uses: nixbuild/nix-quick-install-action@v29
- uses: DeterminateSystems/magic-nix-cache-action@main
- run: echo -n ${{ github.ref_name }} > VERSION
- run: nix build .#kirsch-release
- name: release
uses: svenstaro/[email protected]
Expand Down
7 changes: 5 additions & 2 deletions default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

lib,
stdenvNoCC,
zip,
...
}:

Expand All @@ -19,15 +20,17 @@ stdenvNoCC.mkDerivation {
runHook preBuild
rm -rf out
${P.bited-build}/bin/bited-build ${cfg} \
${lib.optionalString nerd "--nerd"} \
${lib.optionalString release "--release"}
${lib.optionalString nerd "--nerd"}
runHook postBuild
'';

installPhase = ''
runHook preInstall
mkdir -p $out/share/fonts
cp -r out/. $out/share/fonts
${lib.optionalString release ''
${zip}/bin/zip -r $out/share/fonts/ANAKRON_${version}.zip $out/share/fonts
''}
runHook postInstall
'';
}
6 changes: 3 additions & 3 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 56f2690

Please sign in to comment.