Skip to content

Allow lockfile path to be configured - #461

Open
bishtawi wants to merge 1 commit into
cupcakearmy:masterfrom
bishtawi:bishtawi/lockfile-path-config
Open

Allow lockfile path to be configured#461
bishtawi wants to merge 1 commit into
cupcakearmy:masterfrom
bishtawi:bishtawi/lockfile-path-config

Conversation

@bishtawi

@bishtawi bishtawi commented Nov 25, 2025

Copy link
Copy Markdown

Bringing back #384 as it is something I (and I am sure others) would find useful.

I just cherry picked the exact commits from that PR so the code changes are exactly the same, just squashed and rebased.

Description from the previous PR:

The goal of this feature is to allow users to control the path of the lockfile. This is useful in situations where you don't want the lockfile to default next to the config file.

For my use case, I want to generate the config file with Nix which will store it in a read-only path. In such a situation autorestic won't be able to create the lockfile.

This PR adds a few ways to let users control their lockfile path:

  • Using the new --lockfile flag
  • Using the new lockfile: ... config option

Note that this PR includes a refactor that merges the lock package back into the internal package. This is done to avoid a circular dependency where the lock package needs to read the config from the internal package but the internal package also needs to use the lock package.

@vercel

vercel Bot commented Nov 25, 2025

Copy link
Copy Markdown

@dotboris is attempting to deploy a commit to the Nicco's projects Team on Vercel.

A member of the Team first needs to authorize it.

@bishtawi
bishtawi force-pushed the bishtawi/lockfile-path-config branch from b0285ed to 1d06cd4 Compare November 25, 2025 04:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants