-
Notifications
You must be signed in to change notification settings - Fork 492
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix Windows builds #522
Fix Windows builds #522
Changes from 2 commits
be33971
ecaa7c6
da141ad
598bd89
29d3b93
78383d7
fa5ba42
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
use crate::clipboard; | ||
use crate::config::Action; | ||
|
||
use crate::fs; | ||
use crate::config::CONFIG; | ||
use crate::env_var; | ||
use crate::extractor; | ||
|
@@ -65,6 +65,8 @@ fn prompt_finder( | |
('\n'.to_string(), &None) | ||
}; | ||
|
||
eprintln!("{}", fs::exe_string()?); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Remove |
||
|
||
let overrides = { | ||
let mut o = CONFIG.fzf_overrides_var(); | ||
if let Some(io) = initial_opts { | ||
|
@@ -78,15 +80,9 @@ fn prompt_finder( | |
let mut opts = FinderOpts { | ||
overrides, | ||
preview: Some(format!( | ||
r#"navi preview-var "$(cat <<NAVIEOF | ||
{{+}} | ||
NAVIEOF | ||
)" "$(cat <<NAVIEOF | ||
{{q}} | ||
NAVIEOF | ||
)" "{name}"; {extra}"#, | ||
r#"(@echo.{{+}}NAVIEOF{{q}}NAVIEOF{name}) | {exe} preview-var-win"#, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If windows... else... |
||
exe = fs::exe_string()?, | ||
name = variable_name, | ||
extra = extra_preview.clone().unwrap_or_default() | ||
)), | ||
..initial_opts.clone().unwrap_or_default() | ||
}; | ||
|
@@ -100,7 +96,7 @@ NAVIEOF | |
|
||
if opts.preview_window.is_none() { | ||
opts.preview_window = Some(if extra_preview.is_none() { | ||
format!("up:{}", variable_count + 3) | ||
format!("up:{}", variable_count + 10) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 3 |
||
} else { | ||
"right:50%".to_string() | ||
}); | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -167,6 +167,9 @@ pub enum Command { | |
/// Typed text | ||
variable: String, | ||
}, | ||
/// Used for fzf's preview window when selecting variable suggestions | ||
#[clap(setting = AppSettings::Hidden)] | ||
PreviewVarWin, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. PreviewVarStdin |
||
/// Outputs shell widget source code | ||
Widget { | ||
#[clap(possible_values = WIDGET_POSSIBLE_VALUES, case_insensitive = true, default_value = "bash")] | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove