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

use %SystemRoot% environment variable for hosts file location on Windows #27

Merged
merged 1 commit into from
Jan 30, 2024

Conversation

errpunk
Copy link

@errpunk errpunk commented Jan 25, 2024

This Pull Request aims to enhance the method for locating the hosts file on Windows systems by utilizing the SystemRoot environment variable, ensuring a more reliable approach.

it first try to get $SystemRoot environment variable, if the environment variable is not set, fallback to C:\Windows\System32\Drivers\etc\hosts

document about SystemRoot

@cjimti cjimti merged commit 4cd7860 into txn2:master Jan 30, 2024
@errpunk errpunk deleted the feature/win-locate-hosts-via-systemroot branch February 4, 2024 16:31
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

Successfully merging this pull request may close these issues.

2 participants