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

Add ability to change "-" char of the line that separates hostname from other info #132

Closed
ErykDarnowski opened this issue Feb 24, 2022 · 28 comments

Comments

@ErykDarnowski
Copy link

Basically I'd like to add a variable to the config file that let's the user set above mentioned char. This is something that neofetch let's you do and I think it'd be a good addition to winfetch.

screenshot

Let me know if this aligns your plan for winfetch!
(BTW this is my first contribution to a github project not owned by me so I may need some help)

@rashil2000
Copy link
Member

Hmm, may I know your use case for this?

It's definitely possible, but too much customization options will slow down winfetch.

@ErykDarnowski
Copy link
Author

Well essentially it's only customization but I don't think it would slow winfetch down, I'd love to measure the difference but unfortunately I'm getting an unexptected token error when I try to run the file cloned from github. Do you know what may be the cause of that?

@rashil2000
Copy link
Member

This customization option alone won't slow it down, but it opens up room for other such customizations (i.e. that don't have a 'defined' purpose), which can pile up.

Can you post a screenshot of the error?

@ErykDarnowski
Copy link
Author

ErykDarnowski commented Feb 24, 2022

Ohh I understand what you mean, in this case I'm ok with not adding this feature. This is the error I'm getting:
error

@ErykDarnowski
Copy link
Author

I'd like to get these errors resolved cause I also wanted to have a crack at adding another feature (the ability to display monitors refresh rate).

@rashil2000
Copy link
Member

This is a bug in Windows PowerShell, that can be caused in certain regions/languages. PowerShell 7+ solves this.

A workaround can be to use pure ASCII characters instead of Unicode symbols for drawing the boxes in these lines: https://github.com/kiedtl/winfetch/blob/f759d8b3e74e9bb2eecc0734d5c3ed2b5cfb93a3/winfetch.ps1#L462-L469

Would you like to work on this? (it's a good first issue).

@ErykDarnowski
Copy link
Author

ErykDarnowski commented Feb 24, 2022

Ok, I've prepared this ASCII replacement does it look ok?
ASCII
I was also curious if you meant, just change to ASCII or add some sort of detection to display the unicode version when available and ASCII when not.

@rashil2000
Copy link
Member

Can something be done for the corner elements? They look out-of-place. The rest looks good.

just change to ASCII

This one.

@ErykDarnowski
Copy link
Author

Sure, give me a sec.

@rashil2000
Copy link
Member

What happens if we keep using the previous elements for the corners? Does it still throw errors?

@ErykDarnowski
Copy link
Author

ErykDarnowski commented Feb 24, 2022

In my case it doesn't print correctly instead of the corner it prints: â”

What about these versions? In the first one I modified the . at the bottom the second one is a new design:
ASCII1
ASCII2
ASCII3
ASCII4

@rashil2000
Copy link
Member

The first one gives a rounded-corners vibe (which is quite uncharacteristic of the logo).

The second one increases the height in comparison to width, but we need it to be a square.

Hmm, let me investigate a bit more.

@HO-COOH do you have any suggestions?

@ErykDarnowski
Copy link
Author

ErykDarnowski commented Feb 24, 2022

How about the last two widened logos?

@rashil2000
Copy link
Member

Can you try this one:

|‾‾‾‾‾|
|     |
|_____|

@ErykDarnowski
Copy link
Author

Unfortunately, this is how it looks:
ASCII

@rashil2000
Copy link
Member

Can you try changing your output encoding as described here - #126 (comment)

There are more details in that thread that might help.

@ErykDarnowski
Copy link
Author

ErykDarnowski commented Feb 24, 2022

Weird, I managed to set my $OutputEncoding to UTF8 but the logo still looks like this:
ASCII
Should I restart my computer?

@rashil2000
Copy link
Member

@ErykDarnowski
Copy link
Author

Yup, that solved it. But by accident I have found out that if the uptime is less than 1 minute, winfetch just leaves a blank space!

@rashil2000
Copy link
Member

Hmm that's because we start counting the lowest unit as a minute. I think it fits most use cases.

@ErykDarnowski
Copy link
Author

Okay, this is how the logo looks now:
ASCII

@rashil2000
Copy link
Member

I think the old logo will work too, now. No change needed. Can you test it?

@ErykDarnowski
Copy link
Author

ErykDarnowski commented Feb 24, 2022

Yup, after changing these settings the old, 100% unicode version of the logo also works for me:
ASCII

@rashil2000
Copy link
Member

Nice!

We can mention the steps in the above comment in the Wiki, in case someone else faces the same problem.

So this issue can be closed now?

@ErykDarnowski
Copy link
Author

Sure! Mentioning this in the Wiki will definitely help with the confusion. Thank you for everything!

@rashil2000
Copy link
Member

No worries, you're welcome.

Note that the display resolution part is getting refactored, which will enable us to show refresh rates too. See #126 (comment).

@HO-COOH
Copy link
Contributor

HO-COOH commented Feb 25, 2022

Can you try these steps here and restart the computer:

https://www.windowsphoneinfo.com/threads/some-unicode-characters-suddenly-not-displaying-properly-in-every-program-windows-10.557285/#post-2619733

image

Thanks for this piece of info 👍 , my issue in #126 is solved. I suggest this could be put in readme or something.

@rashil2000
Copy link
Member

Will update the Wiki (when the feature is released).

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

No branches or pull requests

3 participants