Closure Size Report #320
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Closure Size Report | |
| on: | |
| workflow_dispatch: | |
| workflow_run: | |
| workflows: ["Build and Cache Nix Flake"] | |
| types: | |
| - completed | |
| branches: | |
| - main | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| report: | |
| runs-on: ubuntu-latest | |
| if: ${{ github.event_name != 'workflow_run' || github.event.workflow_run.conclusion == 'success' }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| host: | |
| - ali-desktop | |
| - ali-framework-laptop | |
| - ali-work-laptop | |
| permissions: | |
| contents: read | |
| id-token: write | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: wimpysworld/nothing-but-nix@main | |
| with: | |
| hatchet-protocol: 'rampage' | |
| - uses: cachix/install-nix-action@v31 | |
| with: | |
| nix_path: nixpkgs=channel:nixos-unstable | |
| github_access_token: ${{ secrets.GITHUB_TOKEN }} | |
| extra_nix_config: | | |
| max-jobs = auto | |
| cores = 0 | |
| eval-cache = true | |
| extra-substituters = https://cache.nixcache.org https://nix-community.cachix.org https://nix-gaming.cachix.org https://rust-overlay.cachix.org https://attic.xuyh0120.win/lantian https://cache.garnix.io | |
| extra-trusted-public-keys = nixcache.org-1:fd7sIL2BDxZa68s/IqZ8kvDsxsjt3SV4mQKdROuPoak= nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs= nix-gaming.cachix.org-1:nbjlureqMbRAxR1gJ/f3hxemL9svXaZF/Ees8vCUUs4= rust-overlay.cachix.org-1:l2scEhXR2wTljEGAr/OGGykVBVbvHI/phxoBUwxaXkk= lantian:EeAUQ+W+6r7EtwnmYjeVwx5kOGEBpjlBfPlzGlTNvHc= cache.garnix.io:CTFPyKSLcx5RMJKfLo5EEPUObbA78b0YQ2DTCJXqr9g= | |
| - name: Cache Nix evaluation | |
| uses: actions/cache@v5 | |
| with: | |
| path: ~/.cache/nix | |
| key: nix-eval-${{ hashFiles('flake.lock') }}-${{ matrix.host }} | |
| restore-keys: | | |
| nix-eval-${{ hashFiles('flake.lock') }}- | |
| - name: Generate closure report | |
| run: | | |
| ./scripts/closure-report.sh \ | |
| ".#nixosConfigurations.${{ matrix.host }}" \ | |
| "${{ matrix.host }}-closure-report.md" | |
| - name: Upload report | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: closure-report-${{ matrix.host }} | |
| path: ${{ matrix.host }}-closure-report.md | |
| - name: Print top 30 | |
| run: head -36 "${{ matrix.host }}-closure-report.md" |