mirror of
https://github.com/ipetkov/crane.git
synced 2024-11-22 23:17:15 +03:00
22f971a126
* Instead of injecting our own dummy `build.rs` file, we will patch the `Cargo.toml` files to specify a build script in the Nix store * This allow cargo to notice the difference (i.e. changed build script path) where it could not before (due to nix enforcing that all sources always have the same timestamp)
11 lines
198 B
Rust
11 lines
198 B
Rust
use std::{
|
|
fs,
|
|
io::{self, Write},
|
|
};
|
|
|
|
fn main() -> io::Result<()> {
|
|
fs::create_dir_all("./target")?;
|
|
fs::File::create("./target/mydata")?.write_all(b"hello world!\n")?;
|
|
Ok(())
|
|
}
|