chore: remove dockfmt #37
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: Build Nix envs | |
| on: | |
| workflow_dispatch: | |
| pull_request: | |
| paths: | |
| - "**" | |
| - "!*.md" | |
| push: | |
| branches: | |
| - "master" | |
| paths: | |
| - "**" | |
| - "!*.md" | |
| env: | |
| CACHIX_USER: albttx | |
| UPDATE_BRANCH: flake-update | |
| jobs: | |
| build-macos-env: | |
| name: Build/cache macOS Nix env | |
| runs-on: macos-15 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v3 | |
| - name: Install Nix | |
| uses: cachix/install-nix-action@v30 | |
| with: | |
| extra_nix_config: | | |
| access-tokens = github.com=${{ secrets.GITHUB_TOKEN }} | |
| - name: Setup Cachix | |
| uses: cachix/cachix-action@v15 | |
| with: | |
| name: ${{ env.CACHIX_USER }} | |
| authToken: ${{ secrets.CACHIX_AUTH_TOKEN }} | |
| - name: Create /run directory | |
| run: | | |
| echo -e "run\tprivate/var/run" | sudo tee -a /etc/synthetic.conf >/dev/null | |
| /System/Library/Filesystems/apfs.fs/Contents/Resources/apfs.util -t &>/dev/null || true | |
| sudo mv /etc/nix/nix.conf /etc/nix/nix.conf.before-nix-darwin | |
| sudo mv /etc/shells /etc/shells.before-nix-darwin | |
| - name: Prevent conflict between Cachix installed by workflow and the one installed in the config | |
| run: | | |
| nix-env --set-flag priority 1 cachix | |
| - name: Build nix-darwin config | |
| run: | | |
| nix build .#darwinConfigurations.githubCI.system --extra-experimental-features nix-command --extra-experimental-features flakes | |
| - name: Switch to nix-darwin env | |
| run: | | |
| # Build and switch to full config | |
| ./result/sw/bin/darwin-rebuild switch --flake .#githubCI | |
| # build-linux-env: | |
| # name: Build/cache Linux Nix env | |
| # runs-on: ubuntu-latest | |
| # steps: | |
| # - name: Checkout repository | |
| # uses: actions/checkout@v3 | |
| # - name: Install Nix | |
| # uses: cachix/install-nix-action@v26 | |
| # with: | |
| # extra_nix_config: | | |
| # access-tokens = github.com=${{ secrets.GITHUB_TOKEN }} | |
| # - name: Setup Cachix | |
| # uses: cachix/cachix-action@v12 | |
| # with: | |
| # name: ${{ env.CACHIX_USER }} | |
| # authToken: ${{ secrets.CACHIX_AUTH_TOKEN }} | |
| # - name: Prevent conflict between Cachix installed by workflow and the one installed in the config | |
| # run: | | |
| # nix-env --set-flag priority 1 cachix | |
| # - name: Build and switch to home-manager env | |
| # run: | | |
| # nix build ".#homeConfigurations.github-ci.activationPackage"; ./result/activate |