Skip to content

better error if command cannot be found #308

better error if command cannot be found

better error if command cannot be found #308

Workflow file for this run

name: Update gomod2nix.toml
on: pull_request
permissions:
contents: write
jobs:
renovatebot:
runs-on: ubuntu-latest
if: ${{ github.actor == 'renovate[bot]' }}
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
fetch-depth: 0
- name: Install Nix
uses: cachix/install-nix-action@v30
with:
github_access_token: ${{ secrets.GH_TOKEN_FOR_UPDATES }}
nix_path: nixpkgs=channel:nixos-unstable
- name: Update gomod2nix.toml
run: |
nix develop .#renovate --command bash -c "gomod2nix:update"
# git push if we have a diff
if [[ -n $(git diff) ]]; then
git add nix/packages/treefmt/gomod2nix.toml
git config --global user.email "<29139614+renovate[bot]@users.noreply.github.com>"
git config --global user.name "renovate[bot]"
git commit -m "chore: update gomod2nix.toml"
git push origin HEAD:${{ github.head_ref }}
fi