treeverse / lakeFS

lakeFS - Data version control for your data lake | Git for data
https://docs.lakefs.io
Apache License 2.0
4.46k stars 354 forks source link

Allow pushing data in the pre-commit hook #8360

Open HMJiangGatech opened 3 days ago

HMJiangGatech commented 3 days ago

In the pre-commit hook (e.g., lua hook), I'm looking for a way to write into the repo.

Example, I structure my repo as

data/ # multiple json
stats.txt

Then I want to have a pre-commit hook to always count how many files in data, and write that into the stats.txt, e.g.,

Number of files in data/ are 107 .

I know I can publish somewhere else, e.g., a s3 location. But I'm looking for a solution to directly write into the repo.

talSofer commented 2 days ago

Thanks for opening this request @HMJiangGatech!

To assist in finding the right solution for your use case, do you mind answering these questions:

I'm asking because the following solution may better fit your use case:

Do you think this would work for you?