Announcement

Collapse
No announcement yet.

Cannot create file association for SuperCollider source files

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Cannot create file association for SuperCollider source files

    Hi all

    I use the audio processing language SuperCollider (SC), which has its own IDE. When I double click SC source files, I want them to open in the IDE. Kubuntu doesn't seem to know what to use to open them, so it asks me what program to use, but it forgets immediately after opening the file.

    I can right-click one of the files and choose Properties, and then File Type Options, and in the dialog box click Add in the section Application Preference Order. I select the SC IDE, but as soon as click Apply, the IDE disappears from the list.

    Interesting, Kubuntu does seem to recognise that the mime type for SC source files is text/x-sc. It's getting it to remember the file association that appears to be the problem.

    I've tried working through the suggestions on this page: https://help.ubuntu.com/community/AddingMimeTypes

    Modifying /etc/mime.types and adding the line:

    Code:
    text/x-sc                       sc scd schelp
    Made no difference at all, even after a restart.

    I then tried the second suggestion (i.e. adding an XML file to /usr/share/mime/application). One issue is that there is already a file in there called x-sc.xml: it's used for the mime type application/x-sc, which is a different type of file altogether.

    Initially I just overwrote the contents of x-sc.xml with the following:

    Code:
    <?xml version="1.0" encoding="utf-8"?>
    <mime-type xmlns="http://www.freedesktop.org/standards/shared-mime-info" type="text/x-sc">
    <glob pattern="*.sc"/>
    <glob pattern="*.scd"/>
    <glob pattern="*.schelp"/>
    </mime-type>
    But as soon as I run
    Code:
    sudo update-mime-database /usr/share/mime
    , the file is restored to its initial state and Kubuntu still doesn't know what to open SC source files with.

    Then I tried adding a new file instead called text-x-sc.xml with the same contents, but again, running
    Code:
    sudo update-mime-database /usr/share/mime
    simply removed the file.

    I'm out of ideas. Can anyone help?
Working...
X