![]() |
ubuntu.com - launchpad.net - ubuntu help
|
|
|||||||
Ubuntu 9.10 is out!!!
When downloading Ubuntu 9.10 please consider using bittorrent to get your copy of Ubuntu. The Ubuntu Developers Summit for Lucid Lynx will be held the week of 16-Nov-2009 till 20-Nov-2009 in Dallas, TX USA. Visit the the Ubuntu wiki for more information about UDS and how to participate remotely. |
|
Tutorials & Tips The place to find Ubuntu related Tips & Tricks. |
|
|
Thread Tools | Display Modes |
|
|
#21 |
|
Dipped in Ubuntu
![]() Join Date: Dec 2005
Location: Lund, Skåne
Beans: 571
|
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! |
|
|
|
|
|
#22 |
|
Way Too Much Ubuntu
![]() Join Date: Dec 2004
Location: Barcelona
Beans: 274
Ubuntu 8.04 Hardy Heron
|
Re: HOWTO: Nautilus Script to mount .iso files
Nice and useful. Just works.
Thanks
__________________
Registered Linux User #371167 |
|
|
|
|
|
#23 |
|
A Carafe of Ubuntu
![]() Join Date: Aug 2005
Location: North of the Artic
Beans: 89
Ubuntu Intrepid Ibex (testing)
|
Re: HOWTO: Nautilus Script to mount .iso files
Thanks I needed this .
-Ounas ![]()
__________________
I forgot that love existed - Van Morrison |
|
|
|
|
|
#24 |
|
100% Pure Ubuntu
![]() |
Re: HOWTO: Nautilus Script to mount .iso files
How to mount ISO BIN/CUE IMG/CCD NRG:
http://ubuntuforums.org/showthread.php?t=144236 |
|
|
|
|
|
#25 |
|
First Cup of Ubuntu
![]() 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
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/" |
|
|
|
|
|
#26 | |
|
A Carafe of Ubuntu
![]() |
Re: HOWTO: Nautilus Script to mount .iso files
Quote:
And thanks a lot to the original scripter too of course. |
|
|
|
|
|
|
#27 |
|
5 Cups of Ubuntu
![]() |
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.
__________________
How'd I do that again, You'd think by now I'd know to write it down...
|
|
|
|
|
|
#28 |
|
Tall Cafè Ubuntu
![]() Join Date: Jun 2006
Location: 1 Quarry Road - Two River
Beans: 2,384
Ubuntu 7.04 Feisty Fawn
|
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.
__________________
Psychocats Tut's..Ubuntu Tutorials...Ubuntu 7.04 (Feisty Fawn) Starter ...180 Ubuntu HowTo's..Tut's and Tips |
|
|
|
|
|
#29 |
|
Tall Cafè Ubuntu
![]() Join Date: Jun 2006
Location: 1 Quarry Road - Two River
Beans: 2,384
Ubuntu 7.04 Feisty Fawn
|
Re: HOWTO: Nautilus Script to mount .iso files
Sidenote:
sudo umount /media/FIREWALL.iso from the term works fine
__________________
Psychocats Tut's..Ubuntu Tutorials...Ubuntu 7.04 (Feisty Fawn) Starter ...180 Ubuntu HowTo's..Tut's and Tips |
|
|
|
|
|
#30 |
|
First Cup of Ubuntu
![]() 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 |
|
|
|
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|