Skip to content

ci: fix nix crate vendoring #8912

ci: fix nix crate vendoring

ci: fix nix crate vendoring #8912

Workflow file for this run

name: Git is clean
on:
push:
branches:
- main
pull_request:
concurrency:
group: ${{ github.ref }}-git-clean
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
jobs:
git-clean:
permissions:
id-token: write
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
fetch-depth: 0
- name: Free disk space
uses: jlumbroso/free-disk-space@v1.3.1
- uses: nixbuild/nix-quick-install-action@v30
with:
nix_conf: |
keep-env-derivations = true
keep-outputs = true
- name: Restore and save Nix store
uses: nix-community/cache-nix-action@v6
with:
# restore and save a cache using this key
primary-key: nix-${{ runner.os }}-${{ hashFiles('**/*.nix', '**/flake.lock') }}
# if there's no cache hit, restore a cache by this prefix
restore-prefixes-first-match: nix-${{ runner.os }}-
# collect garbage until the Nix store size (in bytes) is at most this number
# before trying to save a new cache
# 1G = 1073741824
gc-max-store-size-linux: 1G
# Build metas etc. required to do a correct pointer build.
- run: ./pointers.sh
# Format the repo after generating pointers so that the pointer files are
# formatted too.
- run: nix develop -c forge fmt
# Check if the repo is clean after generating pointers and formatting.
- run: git diff --exit-code
# forwards status to telegram chat if this ci fails or gets canceled, only runs for default branch
- name: Forward CI Status
if: always() # This ensures it runs regardless of previous step outcomes
uses: rainlanguage/github-chore/.github/actions/telegram-status-report@main
with:
status: ${{ job.status }}
telegram-bot-token: ${{ secrets.TELEGRAM_BOT_TOKEN }}
telegram-chat-id: ${{ secrets.TELEGRAM_CHAT_ID }}