summaryrefslogtreecommitdiff
path: root/src/main.rs
diff options
context:
space:
mode:
authorfxqnlr <[email protected]>2024-09-08 17:21:27 +0200
committerfxqnlr <[email protected]>2024-09-08 17:21:27 +0200
commita8d1be9536bce6d6be2cf1586c8bac049e820d31 (patch)
tree05c5c78c11f4506ba2eaa8a0751d3d896cfb81e9 /src/main.rs
parent695556c3441f5ffd40c35387a5b45e4459684c2c (diff)
downloadarbs-a8d1be9536bce6d6be2cf1586c8bac049e820d31.tar
arbs-a8d1be9536bce6d6be2cf1586c8bac049e820d31.tar.gz
arbs-a8d1be9536bce6d6be2cf1586c8bac049e820d31.zip
save files, real last modified check (doesn't work correctly)
Diffstat (limited to 'src/main.rs')
-rw-r--r--src/main.rs15
1 files changed, 10 insertions, 5 deletions
diff --git a/src/main.rs b/src/main.rs
index d5ccb75..acb728f 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -16,18 +16,23 @@ fn main() -> color_eyre::Result<()> {
16 cfg.directories.push("~/.config/nvim".to_string()); 16 cfg.directories.push("~/.config/nvim".to_string());
17 cfg.directories.push("~/.config/hypr".to_string()); 17 cfg.directories.push("~/.config/hypr".to_string());
18 cfg.root = "./backup".to_string(); 18 cfg.root = "./backup".to_string();
19 // cfg.root = "./backup-test".to_string();
20 // cfg.directories.push("u:/code/proj/fxbaup/backup-test-dir".to_string());
19 21
20 let pacman = Pacman; 22 let pacman = Pacman;
21 let pkgs = pacman.get_installed(); 23 let pkgs = pacman.get_installed()?;
22 24
23 let backup = Backup::create(&cfg, pkgs)?; 25 let backup = Backup::create(&cfg, pkgs)?;
24 println!("{backup:#?}"); 26 // println!("{backup:#?}");
25 27
26 // backup.save(&cfg)?; 28 backup.save(&cfg)?;
27 29
28 let index = Backup::get_index(&cfg, None)?; 30 // PathInfo::compare_to_last_modified(&cfg, &LocationRoot::User("fx".to_string()), "code/proj/fxbaub/backup-test-dir/size.txt")?;
31 // PathInfo::compare_to_last_modified(&cfg, &LocationRoot::User("fx".to_string()), "code/proj/fxbaub/backup-test-dir/content.txt")?;
29 32
30 println!("{index:#?}"); 33 // let index = Backup::get_index(&cfg, None)?;
34
35 // println!("{index:#?}");
31 36
32 // let fi = FileInfo::new("~/.config/nvim", &cfg)?; 37 // let fi = FileInfo::new("~/.config/nvim", &cfg)?;
33 // println!("{:?}", fi.get_absolute_path()); 38 // println!("{:?}", fi.get_absolute_path());