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

Backup of old hosts files #80

Merged
merged 1 commit into from
Feb 14, 2016
Merged

Conversation

jaraujo98
Copy link

Modified the removeOldHostsFile() function to keep backups of the old hosts file.
This is a proposed enhancement in line with the following issue
#64

@StevenBlack
Copy link
Owner

Hey thanks @gigaslayer131890!

StevenBlack added a commit that referenced this pull request Feb 14, 2016
@StevenBlack StevenBlack merged commit 231dc43 into StevenBlack:master Feb 14, 2016
@StevenBlack
Copy link
Owner

@gigaslayer131890 since this brings in shutil what's your take on changing this line in method moveHostsFileIntoPlace?

My guess: nah, leave it.

@jaraujo98
Copy link
Author

Thanks for accepting. This was my first open source contribution, so I am glad it went so well.
I would also agree that you can leave that line be. It works, after all. Also, after a quick search, I found out that shutil is slower than subprocess, so you already have the code optimized.

@StevenBlack
Copy link
Owner

That's great @gigaslayer131890. They say you always remember the first time :-)

mitchellkrogza pushed a commit to mitchellkrogza/hosts that referenced this pull request Aug 14, 2017
Backup of old hosts files

Former-commit-id: 231dc43
Former-commit-id: ca32daa4102c2f6cfc98a8f3754fd789833fd71e
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.

None yet

2 participants