Skip to content
This repository has been archived by the owner on May 10, 2019. It is now read-only.

Commit

Permalink
Merge branch 'exifread'
Browse files Browse the repository at this point in the history
Conflicts:
	README.md
  • Loading branch information
richq committed Mar 22, 2014
2 parents 0be280b + d03d924 commit c49763b
Show file tree
Hide file tree
Showing 5 changed files with 45 additions and 15 deletions.
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@ language: python
python:
- "2.7"
- "2.6"
install: "pip install -r requirements.txt"
script: nosetests
32 changes: 18 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,20 +24,7 @@ So keep the database it creates in a safe place!

## INSTALLATION

The easiest way is to just make a local clone of the repository

git clone https://github.com/richq/folders2flickr.git

Then you will need to configure the directories to use:

cp uploadr.ini.sample uploadr.ini
sensible-editor uploadr.ini
# modify at least 'imagedir' to point to the location of new images

I try to keep the master branch usable and for now there are no external
dependencies, so this should be fine.

As an alternative, you can also use [pip](http://www.pip-installer.org).
The easiest way is to use [pip](http://www.pip-installer.org).

pip install --user git+https://github.com/richq/folders2flickr.git

Expand All @@ -48,6 +35,23 @@ The sample configuration file can be created like this:
sensible-editor ~/.uploadr.ini
# modify 'imagedir', etc.

If you want to use a local clone of the repository then please be aware that
folders2flickr depends on the [python-exif](https://github.com/ianare/exif-py)
package. Once you have installed that package, create a clone of folders2flickr using git:

git clone https://github.com/richq/folders2flickr.git

Then you will need to configure the directories to use:

cp uploadr.ini.sample uploadr.ini
sensible-editor uploadr.ini
# modify at least 'imagedir' to point to the location of new images

I try to keep the master branch usable, but there are point releases if you
prefer a stable fixed version. To install a release, download the zip file,
unpack it and away you go. The python-exif dependency will be included in these
zips.

## WHAT IS UPLOADED

The photos and videos in the directory given in the uploadr.ini file are
Expand Down
2 changes: 1 addition & 1 deletion f2flickr/uploadr.py
Original file line number Diff line number Diff line change
Expand Up @@ -405,7 +405,7 @@ def uploadImage( self, image ):
if XPKEYWORDS in exiftags:
printable = exiftags[XPKEYWORDS].printable
if len(printable) > 4:
exifstring = exif.make_string(eval(printable))
exifstring = exifread.make_string(eval(printable))
picTags += exifstring.replace(';', ' ')

picTags = picTags.strip()
Expand Down
24 changes: 24 additions & 0 deletions other/makezip.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#!/bin/sh

P=folders2flickr
V=$(git describe)
exifpymd5=fb99ecc1919494600aa6965ffb41dd60

tempdir=$(mktemp -d)
trap "rm -rf $tempdir" EXIT
outdir=$tempdir/$P-$V
exifpyversion=$(awk -F= '/ExifRead/ {print $3}' requirements.txt)
exifpy=${exifpyversion}.tar.gz
mkdir $outdir

wget -q https://github.com/ianare/exif-py/archive/$exifpy -O $tempdir/$exifpy || exit 1
echo "$exifpymd5 $tempdir/$exifpy" | md5sum -c - || exit 1
tar -C $outdir -xf $tempdir/$exifpy exif-py-$exifpyversion/exifread/ --strip-components=1
tar -C $outdir -xf $tempdir/$exifpy exif-py-$exifpyversion/LICENSE.txt
git archive --format=tar HEAD | tar -C $outdir -x

here=$PWD
cd $tempdir
zip -r -o $here/$P-$V.zip $P-$V
cd -
rm -rf $tempdir
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
ExifRead==1.4.2

0 comments on commit c49763b

Please sign in to comment.