context action now passes flags
This commit is contained in:
parent
441f1d3ef0
commit
44bad997cb
2 changed files with 11 additions and 0 deletions
|
@ -74,6 +74,7 @@ pub fn context_action(state: &State) {
|
||||||
let target = util::repo_fallback();
|
let target = util::repo_fallback();
|
||||||
let mut args = Arguments::from_vec( vec![(&target).into()] );
|
let mut args = Arguments::from_vec( vec![(&target).into()] );
|
||||||
let mut substate = State::new(&mut args);
|
let mut substate = State::new(&mut args);
|
||||||
|
substate.flags = state.flags.clone();
|
||||||
if util::session_exists(&target) {
|
if util::session_exists(&target) {
|
||||||
attach(&mut substate);
|
attach(&mut substate);
|
||||||
} else {
|
} else {
|
||||||
|
|
10
src/flag.rs
10
src/flag.rs
|
@ -37,5 +37,15 @@ impl Flags {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn clone(&self) -> Flags {
|
||||||
|
Flags {
|
||||||
|
detached: self.detached,
|
||||||
|
nested: self.nested,
|
||||||
|
quiet: self.quiet,
|
||||||
|
read_only: self.read_only,
|
||||||
|
target: None
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue