Un1q32 / pfetch

🐧 A pretty system information tool written in POSIX sh.
MIT License
30 stars 9 forks source link

Adding new modules #7

Closed narukeh closed 8 months ago

narukeh commented 1 year ago

Adding new modules, terminal, resolution, and maybe ip if i can... pic-selected-231022-1338-13

p.s.: really nice that you are maintaining posix pfetch 💪

narukeh commented 1 year ago

i am also working on a ip module but im having trouble displaying it. here is the main magic:

ip a | grep 'inet ' | awk '{print $2}' | grep -v '127.0.0.1'

here is the code that does not have effect:

get_ip() {
        ip_strman() {
                ip a | grep 'inet ' | awk '{print $2}' | grep -v '127.0.0.1'
        }
        localips=$(ip_strman)
        log ips "${localips}" >&6
}

this neither:

get_ip() {
        log ips "$(ip a | grep 'inet ' | awk '{print $2}' | grep -v '127.0.0.1')" >&6
}
xplshn commented 10 months ago

Hi, could you add something like this to the PR too? I implemented it but its too janky.

2024-01-06-123609_306x167_scrot

narukeh commented 10 months ago

thats really dope post your diff so that i dont have to start from scratch 😅 but i dont think he is merging PRs anyways.....

xplshn commented 10 months ago

Heh, okay. You have to disable the normal palette and set PF_VERTP=1 to display it:

https://github.com/narukeh/pfetch/compare/master...xplshn:pfetch:master

There it is. Tell me what you think, I am quite useless when it comes to scripting.

Un1q32 commented 8 months ago

Not sure how I didn't see this for so long, my notifications must be broken or something

xplshn commented 8 months ago

Hi! @OldWorldOrdr., Did you add the vertical color palette? Or is it too out of scope?

Un1q32 commented 8 months ago

You can make another or if you want

xplshn commented 8 months ago

I don't know how to make it work when specified in PF_INFO, like, if palette and pfvertp are in that variable

Un1q32 commented 8 months ago

Sorry autocorrect, you can make another PR for the vertical colors, I might look at the diff and merge it myself anyway.

xplshn commented 8 months ago

Ah, okay.