Open jorgeelmundoso opened 4 years ago
This sounds really good and it would remove the hassle with gcd-token files if the token is stored by duplicacy. And for the Web edition it could be encrypted with the rest of the config.
I second this.
Some points that imho are relevant:
I'm happy to submit a PR about this and plan to do so, I hope I'll find the time to work on it in the coming days/weeks.
UPDATE: apologies, but after wasting ~5 hours trying and failing to build the project due to the use of the old Go build system and unversioned dependencies, I decided to abandon the endeavour. If anyone wishes to take time to help me with the build, I'm happy to resume work.
There is a oauth schema for installed apps, nicely implemented in https://github.com/gdrive-org/gdrive/blob/c3cbcceedd6beb1fcff30f06ea7be7c29558d181/handlers_drive.go#L393-L406
It's only a few lines of code, but it will allow to print a url:
and scan the token from stdin without having to download the file, and without visiting a third party website like:
Same approach could be pushed to the web gui, just have an input text field to paste the token back in.
Of course you would need to come up with a place to store the token, could be pushed into the config.
This would improve usability and remove the need to trust https://duplicacy.com/gcd_start to not nick a token.