-
Notifications
You must be signed in to change notification settings - Fork 1
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
Missing 0.0.0.0 in front of the last line in the output file #1
Comments
Sorry to hear you are having issues; I have tested extensively in both CMD and Powershell before and have none of these issues, but I will try and help if I can. I just need a little more input from you for the CMD output:
The problem with the displayed output is that your terminal is not displaying Unicode characters nor ANSI escaped sequenced output correctly. Since the program is not throwing errors/exceptions this means the code page is being set correctly during the program's runtime. I'll check out my source code in a few hours for the 0.0.0.0 issue. Edit: I just tested and you're correct in that the last line does not prepend the and as for the main issue: Edit 2: Already found the issue and fixed: If you want to test the new version early you can download the attached zip file and test or wait a day or two for me to upload the new version (v1.1.1.*) with the fix (but without a display fix as I don't know what the issue is here): |
Ran the new one, the results are better indeed:
chcp in cmd returns:
Get-WinSystemLocale in PowerShell shows:
Python has no trouble at all showing output in cmd: for e.g., if I test with code
I do get the three shades in my cmd box: |
Glad it's working for you! I'm going to officially release the bug fix today or tomorrow, but as for the display issue I'm not sure what I'm going to do yet so I'll keep this issue open. The progress bar is only there so people have a good idea of how fast it works, but this works so fast compared to my scripts that it's almost not necessary so I may or may not remove it in the next release. As for the main functionality of the program itself it makes no difference. I think I see the display issue now though. The code page is not being set properly or something in the program. The necessary code page is 65001 (I forgot that I manually set mine via the registry in If you're interested in changing your code page via registry you can start your default editor up via |
With such small amount of data to process the function of keeping the progress bar updated may actually slow down the program.
|
It's still fast no matter what, but I know you're right to a point. Trivial slow down though. I edited the above message if you're interested. It's early in the morning and I'm tired so I jumped the gun on my original reply. |
If it's not enabled by default by Microsoft it's best to keep your system in standard configuration so your developed applications would be compatible with as many clients as possible. :) |
I know, but I don't always like default crap for my main machines and I don't always do tests locally, lots of times it's in a CI nowadays, but I wrote this program for myself originally and wasn't worried about other users at the time as I didn't think I was going to release it. The only reason I released it is because I seen so many people having issues on Steven's hosts repo that I thought I'd help. I've been programming 30+ years, so I'm well aware of how the crappy environment of the Windows and its registry works lol. I don't even need to release this for Linux because it's not necessary over there lol. |
Since StevenBlack specifically mentions your tool for hosts compression in hosts repo README I wanted to make sure it works. :) Since the problems are solved this issue can be closed, or close after you upload the final fixed version under Releases. |
Yep, I wrote that paragraph :D. |
…ry 5, 2024 Universal Time Coordinated
Official 1.1.1.0 version with this bug fix (for prepended IP only) has been released: 1.1.1.0 |
Version 2 has been officially released and removes the progress bar if anyone is interested. https://github.com/Lateralus138/hosts-compress-windows/releases/tag/2.0.0.1709747905001 |
Thought to try out hostscompress-x64.exe on StevenBlack's "Unified hosts + gambling + porn" hosts file
Gave it switches /d /i and /o
99% all good until I noticed that the last line in the output file is missing the 0.0.0.0 at front
This is the output from my cmd window:
Reading "C:\[at the end of the rainbow]\hosts" content...
Compiling urls for [0.0.0.0]...
Found urls for [0.0.0.0]; Compressing...
〘
〘█
〘██
[Multiple pages of pyramid shaped pattern repetition until it's just a block]
〘███████████████████████████████████████████████████████████████████████████████〘████████████████████████████████████████████████████████████████████████████████████████████████████〙100%
Compressed [210554] urls to [23394] lines...
Compiling urls for [127.0.0.1]...
No urls found for [127.0.0.1]...
Compressed data has been successfully written to:
"C:\[at the end of the rainbow]\hostsNEW"...
I tried without /d and /i too.
The text was updated successfully, but these errors were encountered: