knl / niv-updater-action

A GitHub Action that creates meaningful pull requests with updates to your niv-managed dependencies, so you don't have to do menial chores.
BSD 3-Clause "New" or "Revised" License
29 stars 11 forks source link

Run arbitrary steps before creating PR #48

Open nomeata opened 3 years ago

nomeata commented 3 years ago

In one of my projects, whenever a certain dependency is bumped, I typically want to run a command like

nix-update --version=skip drun

to bump a cargoSha256 hash in one of the nix file.

It would be good if I could pass an arbitrary script to niv-updater-action to run after bumping the niv, but before creating the commit, to include other changes in the PR.

knl commented 3 years ago

Hi @nomeata, this sounds interesting, but I won't be able to work on it until end of September. In the meantime, could you maybe have your arbitrary script run after niv-updater-action and amend the previous commit?

nomeata commented 3 years ago

This is not urgent or anything. I am mostly noting down the idea here.

It seems that you are pushing the change via XPUT via the API, rather than using local git to create the commit, which may make things harder.