Comments (6)
As a followup, it might be beneficial to have an option that disables all TUI features (e.g, overwriting lines) to make this easier to deploy in an automated setting like CI
from hyperfine.
@sharkdp I'm interested in taking this on. I'm just going through the codebase now for how everything is processed. What are your thoughts on the input by @doomrobo? If it is desired, would it be better as a separate issue for tracking purposes?
from hyperfine.
As a followup, it might be beneficial to have an option that disables all TUI features (e.g, overwriting lines) to make this easier to deploy in an automated setting like CI
What are your thoughts on the input by @doomrobo?
I tend to think that --color=never
(or the absence of a TTY) should also disable all TUI features, yes. I'd be okay with only two modes:
- All TUI features enabled, including color (if
--color=always
or if--color=auto
and we detect a TTY) - All TUI features disabled, no colors (if
--color=never
or if--color=auto
in the absence of a TTY)
We could also think about renaming --color
to something different.
I'm interested in taking this on
Sounds great!
We have implemented the same thing in fd
, if you want to take a look: https://github.com/sharkdp/fd/blob/1045930dd9a1dcb6058cbf902041d5c2bb31a48f/src/main.rs#L88-L92
from hyperfine.
@sharkdp As a preliminary step I've changed option 'color' to 'style' and changed the possible input values to be 'auto', 'basic', and 'full'. With basic corresponding to either never or auto+no tty, and full corresponding to always or auto+tty.
I've just been tracing through where the different areas that perform output are and have a question. When we're in basic mode, then what should be done with the progress bar? Should it just be removed totally or replaced with something else that makes more sense when output over consecutive lines.
Also, I'd like to refactor where the processing of the matches for args are done out of main to another function, as it may be prudent to put it under test to ensure that future changes don't cause unintended errors.
from hyperfine.
@sharkdp As a preliminary step I've changed option 'color' to 'style' and changed the possible input values to be 'auto', 'basic', and 'full'. With basic corresponding to either never or auto+no tty, and full corresponding to always or auto+tty.
If you like, you could open a PR already. This way, it's easier to discuss the actual implementation.
what should be done with the progress bar?
I'd be okay with removing it completely.
Also, I'd like to refactor where the processing of the matches for args are done out of main to another function, as it may be prudent to put it under test to ensure that future changes don't cause unintended errors.
Sounds great. Maybe this should be a separate PR, though.
from hyperfine.
Closed via #24
from hyperfine.
Related Issues (20)
- Add quieter markdown `stdout` export HOT 2
- Add short flag counterparts
- Add short flags for `--export` HOT 2
- hyperfine 1.18.0 not published at crates.io HOT 1
- Usage of `hyperfine` to benchmark code HOT 1
- ETA not clearly visible on terminals with a block cursor HOT 1
- run commands only once per set of parameters they use
- Always in this "Initial time measurement" state HOT 6
- Include parameters in output HOT 2
- T
- `-N` makes me can't pass options for command which'll be benchmarked. HOT 1
- Output cpu, disc and memory information HOT 3
- hypperfine without --show-output hard to read on windows7 cmd console HOT 1
- Using --prepare increases benchmark results HOT 2
- Allow custom time measurements HOT 1
- Feature request: Remote commands HOT 1
- Provide Statically Compiled Binaries for (aarch64|arm64) Linux
- Incorrect result for fastfetch HOT 2
- RFE: advanced metrics beyond wall time (CPU time, instruction count, ...)
- Distribution via NPM HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from hyperfine.