Custom fonts and wallpapers built using nix. assets.lemueldls.dev/index.json
wallpapers
at main 80 lines 2.1 kB view raw
1name: Deploy 2 3on: 4 push: 5 branches: 6 - main 7 schedule: 8 - cron: "0 0 * * *" 9 workflow_dispatch: 10 11permissions: 12 contents: write 13 id-token: write 14 15concurrency: 16 group: assets 17 cancel-in-progress: false 18 19jobs: 20 deploy: 21 runs-on: ubuntu-latest 22 23 steps: 24 - name: Checkout repository 25 uses: actions/checkout@v6 26 with: 27 fetch-depth: 1 28 29 - name: Set up SSH signing key 30 run: | 31 mkdir -p ~/.ssh 32 echo "${{ secrets.SSH_SIGNING_KEY }}" > ~/.ssh/id_ed25519 33 chmod 600 ~/.ssh/id_ed25519 34 git config --global gpg.format ssh 35 git config --global user.signingKey ~/.ssh/id_ed25519 36 git config --global user.name "Lemuel DLS" 37 git config --global user.email "noreply@git.lemueldls.dev" 38 39 - uses: cachix/install-nix-action@v31 40 with: 41 github_access_token: ${{ secrets.GITHUB_TOKEN }} 42 43 - uses: cachix/cachix-action@v16 44 with: 45 name: lemueldls 46 authToken: ${{ secrets.CACHIX_AUTH_TOKEN }} 47 48 - name: Update flake 49 run: nix flake update 50 51 - name: Add and commit changes 52 run: | 53 git add -A 54 git commit -S -m "chore: update flake" || echo "No changes to commit" 55 git push 56 57 - name: Build flake 58 run: | 59 nix flake archive --json | jq -r '.path,(.inputs|to_entries[].value.path)' 60 nix build --print-out-paths 61 62 - name: Copy assets 63 run: | 64 mkdir -p public 65 cp -r result/share/fonts public 66 cp -r result/share/wallpapers/assets/contents/images public/wallpapers 67 68 - name: Generate index 69 run: | 70 cd public 71 find -L * -type f | jq -R . | jq -s . > index.json 72 73 - name: Upload to R2 74 uses: zhaijunxiao/r2-dir-sync@v1.0.1 75 with: 76 accountid: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} 77 accesskeyid: ${{ secrets.CLOUDFLARE_ACCESS_KEY }} 78 secretaccesskey: ${{ secrets.CLOUDFLARE_SECRET_KEY }} 79 bucket: assets 80 source: public