Skip to content

Commit

Permalink
demo in main
Browse files Browse the repository at this point in the history
  • Loading branch information
jenna-a2ai committed Mar 28, 2024
1 parent 6f89732 commit ff04f8c
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 3 deletions.
5 changes: 5 additions & 0 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ fn main() -> io::Result<()> {
let message = String::from("assembled data");
add_cmd::run_add_cmd(&files, &message)?;

// todo: check permissions

// remove one of the files
fs::remove_file(&test1_path)?;
// change one of the files
Expand Down Expand Up @@ -69,5 +71,8 @@ fn main() -> io::Result<()> {
let status_string = serde_json::to_string_pretty(&status).unwrap();
println!("new status:\n{status_string}");

fs::remove_file(&test1_path)?;
fs::remove_file(&test2_path)?;
fs::remove_file(&test3_path)?;
Ok(())
}
2 changes: 1 addition & 1 deletion src/test_directory/test1.txt.dvsmeta
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"file_hash": "7f08b8682ee8258389605201d65ed6a9104eed809c000d7975186bc4cd8a3efe",
"file_size": 13,
"time_stamp": "2024-03-28 16:45:54.416308859 -04:00",
"time_stamp": "2024-03-28 16:50:07.067605119 -04:00",
"message": "assembled data",
"saved_by": "jenna"
}
2 changes: 1 addition & 1 deletion src/test_directory/test2.txt.dvsmeta
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"file_hash": "74eadcf4c325be88cfc13870000e31a237228b3932c590f9d73c63bbfe8438c9",
"file_size": 25,
"time_stamp": "2024-03-28 16:45:54.422660180 -04:00",
"time_stamp": "2024-03-28 16:50:07.073982922 -04:00",
"message": "assembled data again",
"saved_by": "jenna"
}
2 changes: 1 addition & 1 deletion src/test_directory/test3.txt.dvsmeta
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"file_hash": "8e287466df9f3e8b1a2bd177ba15efe111aae572ea8859bb24557cfb4418a5b4",
"file_size": 13,
"time_stamp": "2024-03-28 16:45:54.416808704 -04:00",
"time_stamp": "2024-03-28 16:50:07.068136128 -04:00",
"message": "assembled data",
"saved_by": "jenna"
}

0 comments on commit ff04f8c

Please sign in to comment.