Skip to content

Commit

Permalink
Fix: spaces being trimmed when copying files/paths (#82)
Browse files Browse the repository at this point in the history
  • Loading branch information
krivahtoo authored Jul 11, 2021
1 parent f21c15b commit f9cfcab
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/commands/file_ops.rs
Original file line number Diff line number Diff line change
Expand Up @@ -96,16 +96,16 @@ fn copy_string_to_buffer(string: String) -> JoshutoResult<()> {
let clipboards = [
(
"wl-copy",
format!("printf '%s' {} | {} 2> /dev/null", string, "wl-copy"),
format!("printf '%s' '{}' | {} 2> /dev/null", string, "wl-copy"),
),
(
"xsel",
format!("printf '%s' {} | {} -ib 2> /dev/null", string, "xsel"),
format!("printf '%s' '{}' | {} -ib 2> /dev/null", string, "xsel"),
),
(
"xclip",
format!(
"printf '%s' {} | {} -selection clipboard 2> /dev/null",
"printf '%s' '{}' | {} -selection clipboard 2> /dev/null",
string, "xclip"
),
),
Expand Down

0 comments on commit f9cfcab

Please sign in to comment.