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

Fix brioche self-update setting wrong permissions #95

Closed
kylewlacy opened this issue Jul 17, 2024 · 0 comments · Fixed by #112
Closed

Fix brioche self-update setting wrong permissions #95

kylewlacy opened this issue Jul 17, 2024 · 0 comments · Fixed by #112
Assignees
Labels
bug Something isn't working good first issue Good for newcomers

Comments

@kylewlacy
Copy link
Member

brioche self-update updates Brioche itself to the latest version. It does so by downloading a manifest, downloading a linked file, validating the hash, and overwriting its own binary with the linked file.

Currently, if an update is published, the step where Brioche overwrites its own binary doesn't set permissions properly. Once the update is complete, the Brioche executable will no longer have the executable permission, effectively bricking the installation without manual user intervention.

(Luckily, I anticipated an "unknown unknown" breakage in the update process, and made it so the manifest can print a message without performing an update, letting users know that an update is available and needs to be manually installed)

This bug is present in 0.1.0 and 0.1.1. This also means the next update will require manual installation as well.

The fix should be pretty straightforward: ensure that the executable bit is set properly when overwriting the Brioche executable.

@kylewlacy kylewlacy added bug Something isn't working good first issue Good for newcomers labels Jul 17, 2024
@kylewlacy kylewlacy added this to the Brioche v0.1.2 milestone Aug 2, 2024
@jaudiger jaudiger self-assigned this Aug 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants