6.0.0-git
2019-03-18

[#8929] Small fixes to import script
Summary Small fixes to import script
Queue Ansel
Queue Version 1.1.1
Type Enhancement
State Resolved
Priority 1. Low
Owners mrubinsk (at) horde (dot) org
Requester lameventanas (at) gmail (dot) com
Created 2010-03-23 (3282 days ago)
Due
Updated 2010-09-12 (3109 days ago)
Assigned 2010-05-10 (3234 days ago)
Resolved 2010-09-12 (3109 days ago)
Milestone
Patch Yes

History
2010-09-12 22:48:55 Michael Rubinsky Comment #11
Assigned to Michael Rubinsky
State ⇒ Resolved
Version ⇒ 1.1.1
Reply to this comment
Sorry for the delay, but finally tweaked and committed to both FW_3 
and git master.

Thanks!
2010-09-12 22:38:11 CVS Commit Comment #9 Reply to this comment
Changes have been made in CVS for this ticket:

Add sort order parameter to import script.
Request: 8929
Submitted by: lameventanas (at) gmail (dot) com
http://cvs.horde.org/diff.php/ansel/scripts/recursive_import.php?rt=horder1=1.11.2.2r2=1.11.2.3ty=u
2010-05-10 13:28:00 Jan Schneider State ⇒ Assigned
 
2010-04-14 06:27:24 lameventanas (at) gmail (dot) com Comment #8
New Attachment: ansel_import_sort.diff Download
Reply to this comment
This patch adds the desired sorting functionality.
2010-04-13 15:30:13 Michael Rubinsky Comment #7 Reply to this comment
Would you want to add a switch for this, or should I mark this as resolved?
2010-03-25 13:38:22 Michael Rubinsky Comment #6 Reply to this comment
If you install ansel in a different directory (rather than 
HORDE_BASE . '/ansel'), the script won't work.
With my change, it always works.
True...committed, thanks.
I think most people would rather have an alphabetical order rather 
than no order at all (which is how it works now).
It's not "no order at all" - it's the order that the files are 
returned by readdir(), which should be the order that they are stored 
on the filesystem. http://php.net/readdir

Additionally, I wouldn't want my images imported sorted alphabetically 
by default. If anything, I'd want them sorted by the image DateCreated 
time.  If you add a switch for this, I'd be willing to commit it.
2010-03-25 13:31:21 CVS Commit Comment #5 Reply to this comment
Changes have been made in CVS for this ticket:

Fix import script for installations where Ansel is not installed under
horde root.
Bug: 8929
Submitted by: lameventanas (at) gmail (dot) com
http://cvs.horde.org/diff.php/ansel/scripts/recursive_import.php?rt=horde&r1=1.11.2.1&r2=1.11.2.2&ty=u
2010-03-25 13:16:39 lameventanas (at) gmail (dot) com Comment #4 Reply to this comment
Eh, sorry, not a duplicate, but I don't really understand what you 
are attempting to fix.  The definition of ANSEL_BASE should be fine 
as is.  Why is the ANSEL_BASE definition that is built from 
HORDE_BASE not working for you?
If you install ansel in a different directory (rather than HORDE_BASE 
. '/ansel'), the script won't work.
With my change, it always works.
Regarding the sorting, I'm inclined to reject this. It's assuming 
that the user wants images sorted by filename when importing. Not 
always the case. At the very least if you really want this feature 
to be included you should make it a configuration switch on the 
command line.
I think most people would rather have an alphabetical order rather 
than no order at all (which is how it works now).


2010-03-24 22:02:04 Michael Rubinsky Comment #3
State ⇒ Feedback
Reply to this comment
Eh, sorry, not a duplicate, but I don't really understand what you are 
attempting to fix.  The definition of ANSEL_BASE should be fine as is. 
  Why is the ANSEL_BASE definition that is built from HORDE_BASE not 
working for you?

Regarding the sorting, I'm inclined to reject this. It's assuming that 
the user wants images sorted by filename when importing. Not always 
the case. At the very least if you really want this feature to be 
included you should make it a configuration switch on the command line.
2010-03-24 21:52:12 Michael Rubinsky Comment #2
State ⇒ Duplicate
Reply to this comment
Duplicate of Bug: 8760
2010-03-23 08:57:18 lameventanas (at) gmail (dot) com Comment #1
Type ⇒ Enhancement
State ⇒ New
Priority ⇒ 1. Low
Summary ⇒ Small fixes to import script
Queue ⇒ Ansel
Milestone ⇒
Patch ⇒ Yes
New Attachment: ansel_import.diff Download
Reply to this comment
I have made some trivial but important changes in Ansel's import script.

First, it fixes the hard-coding of the installation path of ansel.
Second, it sorts alphabetically the galleries/pictures when importing them.

I have also written a script to import comments from text-files into 
Ansel, but I guess this is too system specific.

Saved Queries