What do we want to display? #330
Replies: 37 comments
-
I personally would like to start by adding the local IP address, as its the easiest of the bunch. |
Beta Was this translation helpful? Give feedback.
-
I have a computer with 2 GPUs. |
Beta Was this translation helpful? Give feedback.
-
An important thing to consider is systems with 2 or more, I think limiting the GPU output to 2 is better than having say four lines of:
|
Beta Was this translation helpful? Give feedback.
-
By default, it could be limited, with an option to show all GPUs. |
Beta Was this translation helpful? Give feedback.
-
That's a good idea 💡 |
Beta Was this translation helpful? Give feedback.
-
#53 You can now view your local IP address 🚀 |
Beta Was this translation helpful? Give feedback.
-
@123marvin123 We should fetch GPUs next! We might also want to move this issue to libmacchina as it makes more sense for the issue to be there now that they are separate repositories. |
Beta Was this translation helpful? Give feedback.
-
How about an option for smaller ascii art as seen in I'd also love to see even more bar options:
I suppose you could also use bars for things like cpu/gpu temps? Lastly, an option to choose circles or squares in the bar, and an option to have shortened (3 letter) names in the left column. With these options themes would be more customizable. Cheers, |
Beta Was this translation helpful? Give feedback.
-
Small ASCII would not look to appealing, it only looks nice on fetchers that fetch a maximum of 5 lines, but it is possible to detect the number of readouts and display a smaller ASCII image if only several readouts are visible. The other suggestions already do exist, our second theme, "Helium" has three letter keys, and square bars. Moving bars is not feasible as the point of Macchina is to be a static program that you call, and it writes your information to the terminal as fast as it can, so no while loops. Storage, backlight and volume information might come in the future, and since they are not yet implemented, each of them needs to be added as a fetchable readout by libmacchina, so Macchina can display it. |
Beta Was this translation helpful? Give feedback.
-
That would be excellent, as I (and I'm sure others) often only want about 5 lines or output. Again, it would just be nice to have that option.
Yes, but there is currently no possible way to achieve three letter keys with round bars. Therefore, either adding an option to specify the length of the keys OR an option to specify the shape of the bars would be handy. But ultimately, options for both would negate the need for theme's altogether as you would then be able to completely customise Macchina's output style.
I wasn't suggesting moving bars necessarily. Similar to the CPU Usage bar, it just prints out the current state. Same could be done for Swap usage, and cpu/gpu temps.
Sounds good. I look forward to hopefully seeing these new features in future releases! 👍 |
Beta Was this translation helpful? Give feedback.
-
Hey @Ramiferous!
Yeah there was a typo in your message that I should've understood as "more" instead of "move", my apologies.
Ask and you shall get, here's a sneak peek :^) Smaller ASCII art is activated when the amount of readouts is less or equal to 6 I made a small NetBSD logo, what do you think?
|
Beta Was this translation helpful? Give feedback.
-
UPDATEI'm working on extending the capabilities of CPU Usage, for now this is exclusive to Linux and NetBSD thanks to the This is a Rust-only approach, it is completely safe and no commands are called. I'm not planning to make a readout for processes, and I'm thinking of appending them to the CPU% (Load), and they are only visible when bars are disabled. The amount of threads is also exposed by sysinfo but this is Linux only and will land in the future. |
Beta Was this translation helpful? Give feedback.
-
Excellent! I still think a flag as an option to chose small ascii might be nice.
That cool, I like it! Can the flag be orange/red and the flagpole be grey/black (depending on your theme) Also, Any thoughts on the cpu/gpu & temp bars? |
Beta Was this translation helpful? Give feedback.
-
That's a good idea, will do :)
I'll try and tweak the colors, as the current choice of color doesn't reflect that of the actual logo.
They'll definitely come in the future :) |
Beta Was this translation helpful? Give feedback.
-
Anything new about gpu hardware support? |
Beta Was this translation helpful? Give feedback.
-
Thank you for response. I did not know that Rust have such problems with environment variables. |
Beta Was this translation helpful? Give feedback.
-
can we display the current shell instead of the default shell? or add a new variable called |
Beta Was this translation helpful? Give feedback.
-
@thorion3006 Noted :) |
Beta Was this translation helpful? Give feedback.
-
@thorion3006 see this commit, it's planned to land as a configuration option (and command line flag too). |
Beta Was this translation helpful? Give feedback.
-
thanks :-) |
Beta Was this translation helpful? Give feedback.
-
You could take it for a spin if you'd like :) |
Beta Was this translation helpful? Give feedback.
-
@grtcdr, the fact that Rust cannot access shell's version from std::env is not a problem, you can just run a command like fn get_shell_version(shell: &str) -> Option<String> {
let output = std::process::Command::new(shell)
.arg("-c")
.arg(format!("echo -n ${}_VERSION", shell.to_uppercase()))
.output();
match output {
Ok(output) => {
let stdout = String::from_utf8_lossy(&output.stdout).to_string();
if stdout.is_empty() {
None
} else {
Some(stdout)
}
}
Err(_) => None
}
} I tested it with bash, fish and zsh, it works as expected, returning data in format like this:
for these shells, respectively |
Beta Was this translation helpful? Give feedback.
-
Can you provide a benchmark? I'd love to know how well this runs, as we might ship this feature in the future. |
Beta Was this translation helpful? Give feedback.
-
@grtcdr, sure. This is what i used to test those 3 shells fn main() {
println!("{}", get_shell_version("bash").unwrap());
println!("{}", get_shell_version("fish").unwrap());
println!("{}", get_shell_version("zsh").unwrap());
}
fn get_shell_version(shell: &str) -> Option<String> {
let output = std::process::Command::new(shell)
.arg("-c")
.arg(format!("echo -n ${}_VERSION", shell.to_uppercase()))
.output();
match output {
Ok(output) => {
let stdout = String::from_utf8_lossy(&output.stdout).to_string();
if stdout.is_empty() {
None
} else {
Some(stdout)
}
}
Err(_) => None
}
} Not really sure if this is exactly what you assumed by "benchmark", so if it's not what you wanted, please tell me what a benchmark for this should be like |
Beta Was this translation helpful? Give feedback.
-
By benchmark he means make a |
Beta Was this translation helpful? Give feedback.
-
Yeah, it would also help if you replicated our current |
Beta Was this translation helpful? Give feedback.
-
I replicated your
on Intel Core 2 3.00Ghz |
Beta Was this translation helpful? Give feedback.
-
My bad, didn't think this may be so bad for performance |
Beta Was this translation helpful? Give feedback.
-
I also tried to implement this a while ago but stopped since the performance was not great. |
Beta Was this translation helpful? Give feedback.
-
Yeah, they all like to print out their versions differently, the worst offender is probably bash. version info hides behind an entire paragraph, so it's not exactly made for parsing. |
Beta Was this translation helpful? Give feedback.
-
In it's current state, Macchina is limited in the amount of displayed data. We should display more information and this issue is here to collect some ideas:
Edited by @grtcdr: Migrated to a discussion.
Beta Was this translation helpful? Give feedback.
All reactions