Skip to content

Conversation

@mivalsten
Copy link

This PR makes tgswitch working on windows by changing default path. It also allows to have different default path on each OS.

@mivalsten
Copy link
Author

Added windows specific CreateSymlink as windows requires admin privilage to create symlinks, so if the program was ran as unprivileged user it would fail no matter what. Windows version instead copies the file to path location.

Not the best solution, but option to symlink as non-admin user only became available in windows 10 and requires customized syscall that is not available in go libraries yet.

@williamoconnorme
Copy link

@warrensbox can this PR be reviewed please? tswitch in it's current state is not compatible with Windows due to the download URL not appending .exe file extension to the URL. This results in tgswitch downloading the 404 HTML response page from github

@mivalsten thank you for distributing the built binary in your fork. I've tested it locally and it's working great for me

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