Page 3 of 10 FirstFirst 12345 ... LastLast
Results 21 to 30 of 94

Thread: HOWTO: Nautilus Script to mount .iso files

  1. #21
    Join Date
    Dec 2005
    Location
    Lund, Skåne
    Beans
    580

    Re: HOWTO: Nautilus Script to mount .iso files

    Great script, very useful.

    But why pollute your scripts menu, when we can do this context-sensitive?

    Put the scripts in a local place, like ~/bin or ~/scripts or wherever you like. Select an iso, choose properties, and look at the Open With.. tab.
    Click add, click 'use custom command' and click browse. Select your Mount script, then repeat this with your Unmount script. Now you have in your context menu whenever you select .iso files, an option to mount or unmount!

    I write Kupfer, a smart, quick launcher.
    Recommended apps and tools: Vim!

  2. #22
    Join Date
    Dec 2004
    Location
    Barcelona
    Beans
    264
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: HOWTO: Nautilus Script to mount .iso files

    Nice and useful. Just works.

    Thanks
    Registered Linux User #371167

  3. #23
    Join Date
    Aug 2005
    Location
    North of the Artic
    Beans
    85
    Distro
    Ubuntu Intrepid Ibex (testing)

    Re: HOWTO: Nautilus Script to mount .iso files

    Thanks I needed this .

    -Ounas
    I forgot that love existed - Van Morrison

  4. #24
    Join Date
    Mar 2006
    Location
    Toronto, Canada
    Beans
    855

    Re: HOWTO: Nautilus Script to mount .iso files

    How to mount ISO BIN/CUE IMG/CCD NRG:
    http://ubuntuforums.org/showthread.php?t=144236

  5. #25
    Join Date
    Nov 2004
    Beans
    5

    Re: HOWTO: Nautilus Script to mount .iso files

    No, those are defective
    gksu segfaults with -k root, i don't think it needs it anyway. also, it attempted for me to create directories with the full path, which is not what i want. so, here's a quick fix and a cleanup.
    Mount:
    Code:
    #!/bin/bash
    #
    # nautilus-mount-iso
    
    gksudo -k /bin/echo "got r00t?"
    BASENAME=`basename "$*"`
    sudo mkdir /media/"$BASENAME"
    echo $BASENAME
    
    if sudo mount -o loop -t iso9660 "$*" /media/"$BASENAME"
    then
            if zenity --question --title "ISO Mounter" --text "$BASENAME Successfully Mounted.
    
            Open Volume?"
            then
                    nautilus /media/"$BASENAME" --no-desktop
            fi
            exit 0
    else
            sudo rmdir /media/"$BASENAME"
            zenity --error --title "ISO Mounter" --text "Cannot mount $BASENAME!"
            exit 1
    fi
    Unmount:
    Code:
    #!/bin/bash
    #
    BASENAME=`basename "$*"`
    foo=`gksudo -u root -k -m "enter your password for root terminal access" /bin/echo "got r00t?"`
    sudo umount /media/"$BASENAME" && zenity --info --text "Successfully unmounted /media/$BASENAME/" && sudo rmdir "/media/$BASENAME/"
    cleaned up the unmount code, BTW.

  6. #26
    Join Date
    Apr 2005
    Location
    Norway
    Beans
    150
    Distro
    Ubuntu Development Release

    Re: HOWTO: Nautilus Script to mount .iso files

    Quote Originally Posted by tr4veler
    The scripts wheren't working for me under Dapper. Turns out gksudo was seg faulting. Pulling out the
    Code:
    -u root -k
    fixed that.
    Thanks for this.Works well now.
    And thanks a lot to the original scripter too of course.

  7. #27
    Join Date
    May 2006
    Beans
    30

    Re: HOWTO: Nautilus Script to mount .iso files

    Just wanted to say thanks to the original poster, tried this on iso's and nrg's worked perfect don't have bin/cue's to try.

  8. #28
    Join Date
    Jun 2006
    Location
    Winterfell
    Beans
    2,487

    Re: HOWTO: Nautilus Script to mount .iso files

    Well the mount script from Nightwish works but the unmount doesn't

    #!/bin/bash
    #
    BASENAME=`basename "$*"`
    foo=`gksudo -m "enter your password for root terminal access" /bin/echo "got r00t?"`
    sudo umount /media/"$BASENAME" && zenity --info --text "Successfully unmounted /media/$BASENAME/" && sudo rmdir "/media/$BASENAME/"

    Any Idea's or is it something stupid I don't understand which is possible and still trying to grasp the whole permissions thing.

    Any Help is always appreciated.

  9. #29
    Join Date
    Jun 2006
    Location
    Winterfell
    Beans
    2,487

    Re: HOWTO: Nautilus Script to mount .iso files

    Sidenote:
    sudo umount /media/FIREWALL.iso
    from the term works fine

  10. #30
    Join Date
    May 2005
    Beans
    4

    Re: HOWTO: Nautilus Script to mount .iso files

    Hi at all!

    I've patched the iso mounter...now it can mount a file from every position in the home directory and it creates a mount point without the .iso extension.

    #!/bin/bash
    # mount

    gksudo -k /bin/echo "got r00t?"

    BASENAME=`basename $NAUTILUS_SCRIPT_SELECTED_FILE_PATHS .iso`

    sudo mkdir "/media/$BASENAME"

    zenity --info --title "ISO Mounter" --text "$BASENAME e $NAUTILUS_SCRIPT_SELECTED_FILE_PATHS"


    if sudo mount -o loop -t iso9660 $NAUTILUS_SCRIPT_SELECTED_FILE_PATHS "/media/$BASENAME"
    then
    if zenity --question --title "ISO Mounter" --text "$BASENAME Successfully Mounted. Open Volume?"

    then
    nautilus /media/"$BASENAME" --no-desktop
    fi

    exit 0
    else
    sudo rmdir "/media/$BASENAME"

    zenity --error --title "ISO Mounter" --text "Cannot mount $BASENAME!"

    exit 1
    fi



    #!/bin/bash
    # unmount

    gksudo -k /bin/echo "got r00t?"

    BASENAME=`basename $NAUTILUS_SCRIPT_SELECTED_FILE_PATHS .iso`

    sudo umount "/media/$BASENAME"

    sudo rmdir "/media/$BASENAME"

    zenity --info --text "Successfully unmounted /media/$BASENAME"

    exit 0

Page 3 of 10 FirstFirst 12345 ... LastLast

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
  •