Skip to content

Commit

Permalink
chore: remove leftover cmd opt
Browse files Browse the repository at this point in the history
  • Loading branch information
roosta committed Nov 11, 2023
1 parent 9cdff81 commit c48394b
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 24 deletions.
1 change: 0 additions & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ fn get_option(config: &Config, key: &str) -> bool {
};
}

/// Gets a window title, depends on wm_property config opt
fn get_title(
props: &HashMap<WindowProperty, String>,
config: &Config,
Expand Down
23 changes: 0 additions & 23 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,6 @@ enum Icons {
Awesome,
}

#[derive(Copy, Clone, PartialEq, Eq, PartialOrd, Ord, ValueEnum, Debug)]
enum Properties {
Class,
Instance,
Name,
}

/// i3wsr config
#[derive(Parser, Debug)]
#[command(author, version, about, long_about = None)]
Expand All @@ -41,10 +34,6 @@ struct Args {
#[arg(short, long)]
remove_duplicates: bool,

/// Which window property to use
#[arg(short = 'p', long)]
wm_property: Option<Properties>,

/// What character used to split the workspace title string
#[arg(short = 'a', long)]
split_at: Option<String>,
Expand Down Expand Up @@ -106,18 +95,6 @@ fn setup() -> Result<Config, Box<dyn Error>> {
config.general.insert("split_at".to_string(), split_char);
}

// wm property
let wm_property = match args.wm_property {
Some(prop) => match prop {
Properties::Class => String::from("class"),
Properties::Instance => String::from("instance"),
Properties::Name => String::from("name"),
},
None => String::from("class"),
};
config
.general
.insert("wm_property".to_string(), wm_property);
Ok(config)
}

Expand Down

0 comments on commit c48394b

Please sign in to comment.