-
Notifications
You must be signed in to change notification settings - Fork 28.7k
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
Register mimetype for *.code-workspace #95637
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Haven't tested it but looks good overall 👍
Was there anything else needed to merge this? |
Ping @Tyriar @joaomoreno |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good. I can't test it at the moment but it seems like a safe change to make. If you could verify the change once Insiders 1.50 comes out that would be great, we'll also test it when we test stable 1.50.
@@ -46,17 +47,24 @@ ln -sf /usr/share/@@NAME@@/bin/@@NAME@@ %{_bindir}/@@NAME@@ | |||
# fi | |||
#fi | |||
|
|||
# Update mimetype database to pickup workspace mimetype | |||
update-mime-database /usr/share/mime &> /dev/null || : |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@luqmana should we also be testing for the executable's existence here?
Register a new mimetype for workspace files so that they aren't just classified as text/plain. This lets users specify VS Code to open workspace files without also associating it with every other text/plain type file.
Fixes: #59040 and #80818
The deb and rpm scripts were updated to install the mimetype but unfortunately Snap doesn't support this yet (see https://forum.snapcraft.io/t/allow-snaps-to-register-new-mime-types/6467/7).