Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RFC: Exclude .lake directory from backups with CACHEDIR.TAG #4998

Open
henkkuli opened this issue Aug 12, 2024 · 0 comments · May be fixed by #5059
Open

RFC: Exclude .lake directory from backups with CACHEDIR.TAG #4998

henkkuli opened this issue Aug 12, 2024 · 0 comments · May be fixed by #5059
Labels
Lake Lake related issue P-medium We may work on this issue if we find the time RFC Request for comments

Comments

@henkkuli
Copy link

Proposal

The .lake/ directory contains remote sources and build artifacts for a project. Hence its contents can be automatically recreated from the rest of the project source. Such directories should be marked with a CACHEDIR.TAG file. This allows automatic backup tools (e.g. Restic, Borg and GNU tar) to ignore the contents of the directory when instructed (e.g. --exclude-caches flag on tar).

The only effect on users should be that their automatic backups may get smaller as the contents of .lake/ directory get excluded. In the rare case that files should be recovered from backups, the user needs to recompile their Lean projects. I would argue that this is a relatively minor inconvenience, and if this is a problem, the user should not have excluded caches from backups in the first place.

Other programming languages are already doing this. For example, Rust is excluding both target/ and ~/.cargo/{git,registry}/ directories.

Community Feedback

The feature was first proposed in the Lean Zulip. It got green light from @semorrison and @tydeu.

Impact

Add 👍 to issues you consider important. If others benefit from the changes in this proposal being added, please ask them to add 👍 to it.

@henkkuli henkkuli added the RFC Request for comments label Aug 12, 2024
@henkkuli henkkuli linked a pull request Aug 15, 2024 that will close this issue
@leanprover-bot leanprover-bot added the P-medium We may work on this issue if we find the time label Aug 16, 2024
@kim-em kim-em added the Lake Lake related issue label Oct 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Lake Lake related issue P-medium We may work on this issue if we find the time RFC Request for comments
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants