Skip to content
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: handle PS2 prompts that require prompt-expansion #239

Merged
merged 1 commit into from
Oct 25, 2024

Conversation

reubeno
Copy link
Owner

@reubeno reubeno commented Oct 25, 2024

Tools like starship customize PS2 in addition to PS1; the same logic used to expand and evaluate PS1 should apply to PS2 as well.

Copy link

Test Results

  2 files    9 suites   1m 9s ⏱️
499 tests 499 ✅ 0 💤 0 ❌
986 runs  986 ✅ 0 💤 0 ❌

Results for commit fe408e0.

Copy link

Performance Benchmark Report

Benchmark name Baseline (μs) Test/PR (μs) Delta (μs) Delta %
expand_one_string 3.39 μs 3.42 μs 0.03 μs ⚪ Unchanged
instantiate_shell 59.85 μs 67.26 μs 7.40 μs 🟠 +12.37%
instantiate_shell_with_init_scripts 30751.87 μs 30956.51 μs 204.64 μs ⚪ Unchanged
parse_bash_completion 2797.06 μs 2802.28 μs 5.22 μs ⚪ Unchanged
parse_sample_script 4.20 μs 4.19 μs -0.00 μs ⚪ Unchanged
run_echo_builtin_command 91.81 μs 92.20 μs 0.39 μs ⚪ Unchanged
run_one_builtin_command 111.39 μs 109.53 μs -1.87 μs ⚪ Unchanged
run_one_external_command 1963.56 μs 1979.21 μs 15.65 μs ⚪ Unchanged
run_one_external_command_directly 1001.66 μs 1010.53 μs 8.87 μs ⚪ Unchanged

Code Coverage Report: Only Changed Files listed

Package Base Coverage New Coverage Difference
brush-core/src/shell.rs 🟢 78.66% 🟢 78.59% 🔴 -0.07%
Overall Coverage 🟢 73.56% 🟢 73.56% ⚪ 0%

Minimum allowed coverage is 70%, this run produced 73.56% |

Minimum allowed coverage is 70%, this run produced 77.1%

@reubeno reubeno merged commit f976e0c into main Oct 25, 2024
11 checks passed
@reubeno reubeno deleted the handle-interesting-PS2-prompts branch October 25, 2024 15:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant