Crates.io | lfs-dal |
lib.rs | lfs-dal |
version | 0.1.3 |
source | src |
created_at | 2024-01-06 09:12:37.598953 |
updated_at | 2024-09-16 10:48:43.006469 |
description | A custom transfer agent for Git LFS powered by OpenDAL. |
homepage | |
repository | https://github.com/regen100/lfs-dal |
max_upload_size | |
id | 1090812 |
size | 88,688 |
A custom transfer agent for Git LFS powered by OpenDAL.
Download the released binary or build from source.
# build from source
$ cargo install lfs-dal
Or install from homebrew.
$ brew tap regen100/lfs-dal
$ brew install lfs-dal
git-lfs
configurationConfigure git-lfs
to use lfs-dal
as a custom transfer agent.
$ git lfs install --local
$ git config lfs.standalonetransferagent lfs-dal
$ git config lfs.customtransfer.lfs-dal.path /PATH/TO/LFS-DAL
$ git config -f .lfsconfig lfs.url lfs-dal # avoid to push to the default server accidentally
lfs-dal
configurationConfigure OpenDAL service settings in lfs-dal
section at .lfsdalconfig
or .git/config
.
lfs-dal --list
shows available schemes.
For service-specific options, refer to the OpenDAL documentation.
[!NOTE] gitconfig does not allow
_
in keys. Use-
instead.
[!NOTE] lfs-dal looks for
.lfsdalconfig
and.git/config
..git/config
is not committed to the repository.
[!CAUTION] Do not commit your credentials to the repository. Some OpenDAL services support importing credentials via environment variables.
$ git config -f .lfsdalconfig lfs-dal.scheme s3
$ git config -f .lfsdalconfig lfs-dal.bucket test
$ git config -f .lfsdalconfig lfs-dal.region us-east-1
$ git config lfs-dal.access-key-id 123456
$ git config lfs-dal.secret-access-key 123456
Use aws2-wrap.
$ aws2-wrap git lfs pull
For testing OpenDAL settings, run lfs-dal --exit
. It exits immediately after initializing OpenDAL.
For more detailed log, configure lfs-dal
to output log to a file.
$ git config lfs.customtransfer.lfs-dal.args "--log-output=log-lfs-dal.txt --log-level=debug"
$ git config lfs.customtransfer.lfs-dal.concurrent false # avoid log interleaving