update-flake-lock icon indicating copy to clipboard operation
update-flake-lock copied to clipboard

Feature request: updating multiple flakes in the same repo in the same PR

Open ipetkov opened this issue 2 years ago • 3 comments

Sometimes it is useful to create a secondary sub-flake which contains tests and their related dependencies so that they are not included in the top-level flake consumed downstream (i.e. to avoid polluting others' lock files with development dependencies).

It would be useful if the update-flake-lock action could update the root and sub flake in the same run/opened-PR and keep all inputs moving in lock step, rather than doing it across multiple runs

ipetkov avatar Aug 27 '23 17:08 ipetkov

Here's a real-world use case, if maintainers are looking for one. I have 4 example flakes in this repo, and would like to (after adding a flake.lock to each) a single Github Action workflow that will update all 4 of them at the same time.

If I'm to use DeterminateSystems/update-flake-lock in its current state, I'll have no choice but to create 4 different workflows which is just an overkill.

srid avatar Mar 18 '24 12:03 srid

Another example: services-flake which currently updates 4 lock files:

image

This ends up creating 4 PRs every week:

image

srid avatar May 26 '24 15:05 srid

Another example: services-flake which currently updates 4 lock files:

image This ends up creating 4 [PRs](https://github.com/juspay/services-flake/pulls?q=is%3Apr+%22Update+lock%22) every week: image

Multiple workflow files is now replaced with a single file using github actions’ matrix: https://github.com/juspay/services-flake/blob/43073cea552aacd62ceebd83e0e835cd17e48f34/.github/workflows/update-flake-lock.yaml

image

shivaraj-bh avatar Aug 05 '24 04:08 shivaraj-bh