Results 1 to 6 of 6

Thread: Removable Media - How to save default behaviour

  1. #1
    Join Date
    Aug 2013
    Beans
    41

    Removable Media - How to save default behaviour

    DISTRIB_ID=Ubuntu
    DISTRIB_RELEASE=18.04
    DISTRIB_CODENAME=bionic
    DISTRIB_DESCRIPTION="Ubuntu 18.04.6 LTS"

    Hi

    I've created a wrapper for abcde to auto-rip CDs when they're inserted into the CD draw. (See here: https://askubuntu.com/questions/6711...sert-music-cds ).

    This shows up as an option in the desktop screen Settings > Devices > Removable Media.

    So I can select for CD audio - "abcde CD wrapper" - but there's no way of saving it - and it just defaults back to VLC.

    Code:
    /usr/share/applications/abcde.wrapper

    Code:
    [Desktop Entry]
    Type=Application
    Name=abcde CD wrapper
    Icon=brasero
    Exec=/home/myUser/rip_CD.sh %F
    Terminal=false
    Categories=AudioVideo;DiscBurning;
    MimeType=application/x-cd-image;application/x-cdrdao-toc;application/x-cue;application/x-toc;audio/x-scpls;audio/x-ms-asx;audio/x-mp3-playlist;audio/x-mpegurl;application/x-brasero;x-content/audio-cdda;x-content/video-dvd;x-content/video-vcd;x-content/video-svcd;x-content/image-picturecd;
    Keywords=abcde;disc;cdrom;dvd;burn;audio;video;
    NoDisplay=false
    X-Desktop-File-Install-Version=0.23
    I also tried editing /usr/share/applications/defaults.list - which doesn't seem to do anything.

    Code:
    #x-content/audio-cdda=rhythmbox-device.desktop
    x-content/audio-cdda=abcde.desktop
    It used to work?! Clearly I'm missing something - not sure what though. Any help gratefully received.
    Last edited by z7APXKm; May 1st, 2023 at 07:29 PM.

  2. #2
    Join Date
    Mar 2010
    Location
    Squidbilly-Land
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Removable Media - How to save default behaviour

    Standard support for 18.04 ends this month. Time to move to a supported LTS. I'm in the same boat with a few systems here. Can't put it off any longer. Soon (days, not weeks), all the repos will be gone and upgrading will become much harder without a fresh install.

  3. #3
    Join Date
    Aug 2013
    Beans
    41

    Re: Removable Media - How to save default behaviour

    Thanks for the warning! That's done now.. A few more problems to fix.

  4. #4
    Join Date
    Dec 2014
    Beans
    2,634

    Re: Removable Media - How to save default behaviour

    The command 'xdg-mime' should allow you to query and set the association between mime-type and program.
    Code:
    xdg-mime query default x-content/audio-cdda
    to check the currently set default
    Code:
    xdg-mime default abcde.desktop x-content/audio-cdda
    should set abcde as the default.

    Holger

  5. #5
    Join Date
    Aug 2013
    Beans
    41

    Re: Removable Media - How to save default behaviour

    Thanks,

    This is what I have now:

    Code:
    root@Myth:/home/myUser# cat /etc/lsb-release
    DISTRIB_ID=Ubuntu
    DISTRIB_RELEASE=22.04
    DISTRIB_CODENAME=jammy
    DISTRIB_DESCRIPTION="Ubuntu 22.04.2 LTS"
    root@Myth:/home/myUser#  xdg-mime query default x-content/audio-cdda
    abcde.desktop
    The Removable Media settings screen still shows VLC media player as the default against CD audio, although I can drop down to select abcde-CD wrapper. Same issue though - it doesn't save (and I might be being dense but I don't see a save button). So when you click off and back on to this screen it's back to VLC.

    I have the abcde wrapper as a favourite on the left, so I can click it manually, but would be nice to have it run automatically.

  6. #6
    Join Date
    Dec 2014
    Beans
    2,634

    Re: Removable Media - How to save default behaviour

    This is the point where I actually tried it and found that on my XUbuntu it also didn't work. Associating things with a mime type is overridden by the settings in 'Removable Drives and Media'. But in XUbuntu you actually get to type in a command with some obvious variables you can use as parameters and it does store these settings and uses them. There is no save botton here either, but the 'close' button saves the settings.

    Holger

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •