[f-spot: 2/4] simplify f-spot-import



commit 6ce0d7ca8350af8d18afcbe1b7924d1b059ee876
Author: Christian Krause <chkr plauener de>
Date:   Sun Oct 17 23:08:19 2010 +0200

    simplify f-spot-import
    
    - don't touch the supplied URL / path
    - don't umount gvfs gphoto2 mounts
    
    https://bugzilla.gnome.org/show_bug.cgi?id=633059

 tools/f-spot-import |   31 ++-----------------------------
 1 files changed, 2 insertions(+), 29 deletions(-)
---
diff --git a/tools/f-spot-import b/tools/f-spot-import
index e27917e..05b6201 100755
--- a/tools/f-spot-import
+++ b/tools/f-spot-import
@@ -1,30 +1,3 @@
-#!/bin/bash -x
+#!/bin/bash
 
-udi="$1"
-#xmessage $udi
-
-if [ "$udi" != "${udi#gphoto2:}" ]; then
-	# gphoto2, as passed by gvfs/nautilus
-	gvfs-mount -u "$udi" || true
-	f-spot --import "$udi"
-	exit
-fi
-mnt=${udi#file://}
-if [ "$udi" != "$mnt" ]; 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"
-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"
-fi
+f-spot --import "$1"



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]