mirror of
https://github.com/RGBCube/nu_scripts
synced 2025-07-30 13:47:46 +00:00
fix some quoting bugs that the lsp found (#441)
This commit is contained in:
parent
d78ee5eaa7
commit
ebdab3dea3
2 changed files with 44 additions and 44 deletions
|
@ -3,8 +3,8 @@ def turtle [column: string] {
|
|||
wrap $column | table
|
||||
}
|
||||
|
||||
print $"Turtle 1 = ('turtle' | turtle 1 | str length)"
|
||||
print $"Turtle 2 = ('turtle' | turtle 1 | turtle 2 | str length)"
|
||||
print $"Turtle 3 = ('turtle' | turtle 1 | turtle 2 | turtle 3 | str length)"
|
||||
print $"Turtle 4 = ('turtle' | turtle 1 | turtle 2 | turtle 3 | turtle 4 | str length)"
|
||||
print $"Turtle 5 = ('turtle' | turtle 1 | turtle 2 | turtle 3 | turtle 4 | turtle 5 | str length)"
|
||||
print $"Turtle 1 = ('turtle' | turtle '1' | str length)"
|
||||
print $"Turtle 2 = ('turtle' | turtle '1' | turtle '2' | str length)"
|
||||
print $"Turtle 3 = ('turtle' | turtle '1' | turtle '2' | turtle '3' | str length)"
|
||||
print $"Turtle 4 = ('turtle' | turtle '1' | turtle '2' | turtle '3' | turtle '4' | str length)"
|
||||
print $"Turtle 5 = ('turtle' | turtle '1' | turtle '2' | turtle '3' | turtle '4' | turtle '5' | str length)"
|
|
@ -164,68 +164,68 @@ let cmd_duration_ms_bg_color_24 = (ansi -e { fg: "#000000" })
|
|||
let cmd_duration_ms_bg_color_8 = (ansi black)
|
||||
|
||||
let runtime_colors = [
|
||||
{ name: prompt_color_frame_and_connection, 8bit: $prompt_color_frame_and_connection_8, 24bit: $prompt_color_frame_and_connection_24 },
|
||||
{ name: prompt_color_separator_same_color, 8bit: $prompt_color_separator_same_color_8, 24bit: $prompt_color_separator_same_color_24 },
|
||||
{ name: left_separator_diff_color, 8bit: $left_prompt_separator_diff_color, 24bit: $left_prompt_separator_diff_color },
|
||||
{ name: left_separator_same_color, 8bit: $left_prompt_separator_same_color, 24bit: $left_prompt_separator_same_color },
|
||||
{ name: prompt_color_frame_and_connection, '8bit': $prompt_color_frame_and_connection_8, '24bit': $prompt_color_frame_and_connection_24 },
|
||||
{ name: prompt_color_separator_same_color, '8bit': $prompt_color_separator_same_color_8, '24bit': $prompt_color_separator_same_color_24 },
|
||||
{ name: left_separator_diff_color, '8bit': $left_prompt_separator_diff_color, '24bit': $left_prompt_separator_diff_color },
|
||||
{ name: left_separator_same_color, '8bit': $left_prompt_separator_same_color, '24bit': $left_prompt_separator_same_color },
|
||||
{ name: left_prefix, value: $nothing },
|
||||
{ name: left_suffix, value: $nothing },
|
||||
{ name: right_separator_diff_color, 8bit: $right_prompt_separator_diff_color, 24bit: $right_prompt_separator_diff_color },
|
||||
{ name: right_separator_same_color, 8bit: $right_prompt_separator_same_color, 24bit: $right_prompt_separator_same_color },
|
||||
{ name: right_separator_diff_color, '8bit': $right_prompt_separator_diff_color, '24bit': $right_prompt_separator_diff_color },
|
||||
{ name: right_separator_same_color, '8bit': $right_prompt_separator_same_color, '24bit': $right_prompt_separator_same_color },
|
||||
{ name: right_prefix, value: $nothing },
|
||||
{ name: right_suffix, value: $nothing },
|
||||
|
||||
{ name: cmd_bg_color, 8bit: $cmd_duration_bg_color_8, 24bit: $cmd_duration_bg_color_24 },
|
||||
{ name: cmd_color, 8bit: $cmd_duration_color_8, 24bit: $cmd_duration_color_24 },
|
||||
{ name: cmd_bg_color, '8bit': $cmd_duration_bg_color_8, '24bit': $cmd_duration_bg_color_24 },
|
||||
{ name: cmd_color, '8bit': $cmd_duration_color_8, '24bit': $cmd_duration_color_24 },
|
||||
{ name: cmd_decimals, value: 2 },
|
||||
{ name: cmd_icon, value: },
|
||||
|
||||
{ name: git_bg_color, 8bit: $git_bg_color_8, 24bit: $git_bg_color_24 },
|
||||
{ name: git_bg_color_unstable, 8bit: $git_bg_color_unstable_8, 24bit: $git_bg_color_unstable_24 },
|
||||
{ name: git_bg_color_urgent, 8bit: $git_bg_color_urgent_8 , 24bit: $git_bg_color_urgent_24 },
|
||||
{ name: git_color_branch, 8bit: $git_color_branch_8, 24bit: $git_color_branch_24 },
|
||||
{ name: git_color_conflicted, 8bit: $git_color_conflicted_8, 24bit: $git_color_conflicted_24 },
|
||||
{ name: git_color_dirty, 8bit: $git_color_dirty_8, 24bit: $git_color_dirty_24 },
|
||||
{ name: git_color_operation, 8bit: $git_color_operation_8, 24bit: $git_color_operation_24 },
|
||||
{ name: git_color_staged, 8bit: $git_color_staged_8, 24bit: $git_color_staged_24 },
|
||||
{ name: git_color_stash, 8bit: $git_color_stash_8, 24bit: $git_color_stash_24 },
|
||||
{ name: git_color_untracked, 8bit: $git_color_untracked_8, 24bit: $git_color_untracked_24 },
|
||||
{ name: git_color_upstream, 8bit: $git_color_upstream_8, 24bit: $git_color_upstream_24 },
|
||||
{ name: git_bg_color, '8bit': $git_bg_color_8, '24bit': $git_bg_color_24 },
|
||||
{ name: git_bg_color_unstable, '8bit': $git_bg_color_unstable_8, '24bit': $git_bg_color_unstable_24 },
|
||||
{ name: git_bg_color_urgent, '8bit': $git_bg_color_urgent_8 , '24bit': $git_bg_color_urgent_24 },
|
||||
{ name: git_color_branch, '8bit': $git_color_branch_8, '24bit': $git_color_branch_24 },
|
||||
{ name: git_color_conflicted, '8bit': $git_color_conflicted_8, '24bit': $git_color_conflicted_24 },
|
||||
{ name: git_color_dirty, '8bit': $git_color_dirty_8, '24bit': $git_color_dirty_24 },
|
||||
{ name: git_color_operation, '8bit': $git_color_operation_8, '24bit': $git_color_operation_24 },
|
||||
{ name: git_color_staged, '8bit': $git_color_staged_8, '24bit': $git_color_staged_24 },
|
||||
{ name: git_color_stash, '8bit': $git_color_stash_8, '24bit': $git_color_stash_24 },
|
||||
{ name: git_color_untracked, '8bit': $git_color_untracked_8, '24bit': $git_color_untracked_24 },
|
||||
{ name: git_color_upstream, '8bit': $git_color_upstream_8, '24bit': $git_color_upstream_24 },
|
||||
|
||||
{ name: os_bg_color, 8bit: $os_bg_color_8, 24bit: $os_bg_color_24 },
|
||||
{ name: os_color, 8bit: $os_color_8, 24bit: $os_color_24 },
|
||||
{ name: os_bg_color, '8bit': $os_bg_color_8, '24bit': $os_bg_color_24 },
|
||||
{ name: os_color, '8bit': $os_color_8, '24bit': $os_color_24 },
|
||||
|
||||
{ name: pwd_bg_color, 8bit: $pwd_bg_color_8, 24bit: $pwd_bg_color_24 },
|
||||
{ name: pwd_color_anchors, 8bit: $pwd_color_anchors_8, 24bit: $pwd_color_anchors_24 },
|
||||
{ name: pwd_color_dirs, 8bit: $pwd_color_dirs_8, 24bit: $pwd_color_dirs_24 },
|
||||
{ name: pwd_color_truncated_dirs, 8bit: $pwd_color_truncated_dirs_8, 24bit: $pwd_color_truncated_dirs_24 },
|
||||
{ name: pwd_bg_color, '8bit': $pwd_bg_color_8, '24bit': $pwd_bg_color_24 },
|
||||
{ name: pwd_color_anchors, '8bit': $pwd_color_anchors_8, '24bit': $pwd_color_anchors_24 },
|
||||
{ name: pwd_color_dirs, '8bit': $pwd_color_dirs_8, '24bit': $pwd_color_dirs_24 },
|
||||
{ name: pwd_color_truncated_dirs, '8bit': $pwd_color_truncated_dirs_8, '24bit': $pwd_color_truncated_dirs_24 },
|
||||
{ name: pwd_icon, value: $nothing },
|
||||
{ name: pwd_icon_home, value: $nothing },
|
||||
{ name: pwd_icon_unwritable, value: $nothing },
|
||||
|
||||
{ name: rustc_bg_color, 8bit: $rustc_bg_color_8, 24bit: $rustc_bg_color_24 },
|
||||
{ name: rustc_color, 8bit: $rustc_color_8, 24bit: $rustc_color_24 },
|
||||
{ name: rustc_bg_color, '8bit': $rustc_bg_color_8, '24bit': $rustc_bg_color_24 },
|
||||
{ name: rustc_color, '8bit': $rustc_color_8, '24bit': $rustc_color_24 },
|
||||
{ name: rustc_icon, value: },
|
||||
|
||||
{ name: status_bg_color, 8bit: $status_bg_color_8, 24bit: $status_bg_color_24 },
|
||||
{ name: status_bg_color_failure, 8bit: $status_bg_color_failure_8, 24bit: $status_bg_color_failure_24 },
|
||||
{ name: status_color, 8bit: $status_color_8, 24bit: $status_color_24 },
|
||||
{ name: status_color_failure, 8bit: $status_color_failure_8 , 24bit: $status_color_failure_24 },
|
||||
{ name: status_bg_color, '8bit': $status_bg_color_8, '24bit': $status_bg_color_24 },
|
||||
{ name: status_bg_color_failure, '8bit': $status_bg_color_failure_8, '24bit': $status_bg_color_failure_24 },
|
||||
{ name: status_color, '8bit': $status_color_8, '24bit': $status_color_24 },
|
||||
{ name: status_color_failure, '8bit': $status_color_failure_8 , '24bit': $status_color_failure_24 },
|
||||
{ name: status_icon, value: $nothing },
|
||||
{ name: status_icon_failure, value: $nothing },
|
||||
|
||||
{ name: time_bg_color, 8bit: $time_bg_color_8, 24bit: $time_bg_color_24 },
|
||||
{ name: time_color, 8bit: $time_color_8, 24bit: $time_color_24 },
|
||||
{ name: time_bg_color, '8bit': $time_bg_color_8, '24bit': $time_bg_color_24 },
|
||||
{ name: time_color, '8bit': $time_color_8, '24bit': $time_color_24 },
|
||||
{ name: time_format, value: $nothing },
|
||||
|
||||
{ name: indicator_bg_color, 8bit: $indicator_bg_color_8, 24bit: $indicator_bg_color_24 },
|
||||
{ name: indicator_color, 8bit: $indicator_color_8, 24bit: $indicator_color_24 },
|
||||
{ name: indicator_bg_color, '8bit': $indicator_bg_color_8, '24bit': $indicator_bg_color_24 },
|
||||
{ name: indicator_color, '8bit': $indicator_color_8, '24bit': $indicator_color_24 },
|
||||
|
||||
{ name: terminal_color, 8bit: $terminal_color_8, 24bit: $terminal_color_24 },
|
||||
{ name: terminal_bg_color, 8bit: $terminal_bg_color_8, 24bit: $terminal_bg_color_24 },
|
||||
{ name: terminal_color, '8bit': $terminal_color_8, '24bit': $terminal_color_24 },
|
||||
{ name: terminal_bg_color, '8bit': $terminal_bg_color_8, '24bit': $terminal_bg_color_24 },
|
||||
|
||||
{name: cmd_duration_ms_color, 8bit: $cmd_duration_ms_color_8, 24bit: $cmd_duration_ms_color_24 },
|
||||
{name: cmd_duration_ms_bg_color, 8bit: $cmd_duration_ms_bg_color_8, 24bit: $cmd_duration_ms_bg_color_24 },
|
||||
{name: cmd_duration_ms_color, '8bit': $cmd_duration_ms_color_8, '24bit': $cmd_duration_ms_color_24 },
|
||||
{name: cmd_duration_ms_bg_color, '8bit': $cmd_duration_ms_bg_color_8, '24bit': $cmd_duration_ms_bg_color_24 },
|
||||
]
|
||||
|
||||
# get the color from the $runtime_colors array
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue