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

Implement more of compgen #8

Merged
merged 1 commit into from
May 13, 2024
Merged

Implement more of compgen #8

merged 1 commit into from
May 13, 2024

Conversation

reubeno
Copy link
Owner

@reubeno reubeno commented May 13, 2024

Adds naive implementation for file, alias, builtin, and function. Future work should figure out how to reduce allocations in this code path, particularly for candidates that don't match filters.

@reubeno reubeno enabled auto-merge (squash) May 13, 2024 16:33
@reubeno reubeno merged commit 62f9451 into main May 13, 2024
4 checks passed
Copy link

Test Results

344 tests   329 ✅  2m 19s ⏱️
 56 suites   15 💤
  8 files      0 ❌

Results for commit 757c21f.

Copy link

Performance Benchmark Report

Benchmark name Baseline (ns) Test/PR (ns) Delta (ns) Delta %
expand_one_string 3318 ns 3317 ns -1 ns 🟢 -0.03%
instantiate_shell 53074 ns 53084 ns +10 ns 🟠 +0.02%
instantiate_shell_with_init_scripts 26636306 ns 47027422 ns +20391116 ns 🟠 +76.55%
parse_bash_completion 6644209 ns 6662033 ns +17824 ns 🟠 +0.27%
parse_sample_script 11072 ns 11047 ns -25 ns 🟢 -0.23%
run_echo_builtin_command 92046 ns 92726 ns +680 ns 🟠 +0.74%
run_one_builtin_command 108151 ns 110861 ns +2710 ns 🟠 +2.51%
run_one_external_command 1759258 ns 1787044 ns +27786 ns 🟠 +1.58%
run_one_external_command_directly 1022626 ns 1022512 ns -114 ns 🟢 -0.01%

Code Coverage Report

Package Base Coverage New Coverage Difference
cli.src 🟢 78.82% 🟠 73.95% 🔴 -4.87%
interactive-shell.src 🟢 75.88% 🟢 75.88% ⚪ 0%
parser.src 🟢 85.84% 🟢 85.86% 🟢 0.02%
shell.src 🟢 80.06% 🟢 79.93% 🔴 -0.13%
shell.src.builtins 🟠 63.98% 🟠 64.03% 🟢 0.05%
Overall Coverage 🟢 78.09% 🟢 77.99% 🔴 -0.1%

Minimum allowed coverage is 0%, this run produced 77.99%

@reubeno reubeno deleted the more-completion branch May 13, 2024 19:35
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