Skip to content

Commit

Permalink
use reflink_copy and build musl binaries
Browse files Browse the repository at this point in the history
  • Loading branch information
skshetry committed Feb 19, 2024
1 parent 49928f6 commit bfb7e0b
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 10 deletions.
23 changes: 17 additions & 6 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "dvc-data"
version = "0.1.0"
version = "0.1.1"
edition = "2021"
authors = ["Saugat Pachhai"]
description = "Pure Rust implementation of DVC"
Expand All @@ -15,7 +15,7 @@ eula = false
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
reflink = "0.1.3"
reflink-copy = "0.1.14"
hex = "0.4.3"
console = "0.15.8"
num_cpus = "1.16.0"
Expand Down Expand Up @@ -67,7 +67,7 @@ cargo-dist-version = "0.10.0"
# The installers to generate for each app
installers = ["shell", "powershell", "msi"]
# Target platforms to build apps for (Rust target-triple syntax)
targets = ["aarch64-apple-darwin", "x86_64-apple-darwin", "x86_64-unknown-linux-gnu"]
targets = ["aarch64-apple-darwin", "x86_64-apple-darwin", "x86_64-unknown-linux-gnu", "x86_64-unknown-linux-musl"]
# CI backends to support
ci = ["github"]
# Publish jobs to run in CI
Expand Down
2 changes: 1 addition & 1 deletion src/fsutils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ pub fn size(path: PathBuf) -> u64 {

pub fn transfer_file(from: &PathBuf, to: &PathBuf) {
fs::create_dir_all(to.parent().unwrap()).unwrap();
reflink::reflink_or_copy(from, to)
reflink_copy::reflink_or_copy(from, to)
.unwrap_or_else(|_| panic!("transfer failed: {from:?} {to:?}"));
}

Expand Down

0 comments on commit bfb7e0b

Please sign in to comment.