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

feat(bash/blesh): use _ble_exec_time_ata for duration even in bash < 5 #1940

Merged
merged 1 commit into from
Apr 10, 2024

Conversation

akinomyoga
Copy link
Contributor

See the commit message for the description. This applies the change suggested by @gvlassis in #1484 (comment).

Checks

  • I am happy for maintainers to push small adjustments to this PR, to speed up the review cycle
  • I have checked that there are no existing pull requests for the same thing

Bash < 5.0 doesn't support the high-resolution clock EPOCHREALTIME, so
ble.sh uses the builtin command `time` to measure the execution times
in Bash < 5.0.  This has a lower resolution of milliseconds but still
more accurate than Atuin's measurent because Atuin's measurement
includes the spawn cost of Atuin, which is typically larger than a
millisecond.

Reported-by: Georgios Vlassis <https://github.com/gvlassis>
Reference: atuinsh#1484 (comment)
Copy link
Member

@ellie ellie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice! 👏

@ellie ellie merged commit 0da8d34 into atuinsh:main Apr 10, 2024
17 checks passed
@akinomyoga
Copy link
Contributor Author

Thanks!

@akinomyoga akinomyoga deleted the blesh-exec-time branch April 10, 2024 12:05
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.

2 participants