diff options
author | Daniel Schadt <kingdread@gmx.de> | 2021-11-09 01:12:02 +0100 |
---|---|---|
committer | Daniel Schadt <kingdread@gmx.de> | 2021-11-09 01:12:02 +0100 |
commit | 117f760d7cb389ef9bed5a206cf6a510a1225a1b (patch) | |
tree | c3045ffa79b8c6e3214933bf7b14501f45248774 /src | |
parent | 0805aacc891505c4dfe5f7a64184d131decaeb49 (diff) | |
download | modderbaas-117f760d7cb389ef9bed5a206cf6a510a1225a1b.tar.gz modderbaas-117f760d7cb389ef9bed5a206cf6a510a1225a1b.tar.bz2 modderbaas-117f760d7cb389ef9bed5a206cf6a510a1225a1b.zip |
Rename --fix-permissions to --chown
On second thought, we're just calling chown, so let's call it that.
Diffstat (limited to 'src')
-rw-r--r-- | src/main.rs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/main.rs b/src/main.rs index 91d1c9c..87f8847 100644 --- a/src/main.rs +++ b/src/main.rs @@ -28,7 +28,7 @@ fn main() -> Result<()> { .arg( Arg::with_name("world") .long("world") - .short("c") + .short("w") .required(false) .help("Select the world that we should operate on") .takes_value(true), @@ -67,9 +67,9 @@ fn main() -> Result<()> { .required(false), ) .arg( - Arg::with_name("fix-permissions") - .short("p") - .long("fix-permissions") + Arg::with_name("chown") + .short("o") + .long("chown") .help("Change the owner of the installed mod to match target-dir's") .required(false), ), @@ -214,7 +214,7 @@ fn install_mods( ) -> Result<()> { let target_dir = Path::new(matches.value_of("target").unwrap()); let dry_run = matches.is_present("dry-run"); - let fix_permissions = matches.is_present("fix-permissions"); + let chown_after = matches.is_present("chown"); let content_db = ContentDb::new(); let downloader = Downloader::new()?; @@ -329,7 +329,7 @@ fn install_mods( sys::stat, unistd::{Gid, Uid}, }; - if fix_permissions { + if chown_after { let perms = stat::stat(target_dir)?; let (uid, gid) = (Uid::from_raw(perms.st_uid), Gid::from_raw(perms.st_gid)); util::chown_recursive(installed.path(), Some(uid), Some(gid))?; |