Changeset 15492 in project for release/4/qwiki/trunk/qwiki-svn.scm


Ignore:
Timestamp:
08/15/09 13:12:42 (11 years ago)
Author:
sjamaan
Message:

Fix handling of directories - it was a mess before, it's better but slower now

File:
1 edited

Legend:

Unmodified
Added
Removed
  • release/4/qwiki/trunk/qwiki-svn.scm

    r15491 r15492  
    112112   (error "Could not store changes")))
    113113
    114 ;; This not only undoes the changes, but also updates to the latest version
    115 ;; of the file...
    116114(define (undo-changes! source-path)
    117   (if (get-info source-path) ; Existing file?
     115  (if (get-info source-path)            ; Existing file?
     116      (svn-client-revert (list source-path) #t
     117                         (qwiki-repos-username)
     118                         (qwiki-repos-password))
    118119      (begin
    119         (svn-client-revert (list source-path) #t
    120                            (qwiki-repos-username)
    121                            (qwiki-repos-password))
    122         (update-sources! source-path))
    123       (begin (delete-file* source-path)
    124              (let loop ((path (pathname-directory source-path)))
    125                (if (get-info path)
    126                    (update-sources! path)
    127                    (begin
    128                      (delete-directory path)
    129                      (loop (pathname-directory path))))))))
     120        (delete-file* source-path)
     121        (let loop ((path (pathname-directory source-path)))
     122          (unless (get-info path)
     123            (begin
     124              (delete-directory path)
     125              (loop (pathname-directory path))))))))
    130126
    131127)
Note: See TracChangeset for help on using the changeset viewer.