sanbornm / go-selfupdate

Enable your Go applications to self update
MIT License
1.53k stars 176 forks source link

update does not works if app is in at an un-writable location #24

Closed sushilkm closed 8 years ago

sushilkm commented 8 years ago

If the app is located for eg. in /usr/local/bin then update does not works if executing update as a normal user, this is fine because thats expected that if app is for eg. "root" controlled then it should not be updateable by any random user, but the problems is that update does not gives you an error, that it failed to update rather it returns success.

sushilkm commented 8 years ago

I tried to fix this in PR https://github.com/sanbornm/go-selfupdate/pull/23 that in case, the location is not writable, it would fail to create directory and then the error should not be ignored, rather it should be propagated to caller of BackgroundRun