]> gitweb @ CieloNegro.org - sugar.git/commitdiff
Auto commit by The Sugar System.
authorPHO <pho@cielonegro.org>
Sun, 7 Dec 2008 12:16:59 +0000 (21:16 +0900)
committerPHO <pho@cielonegro.org>
Sun, 7 Dec 2008 12:16:59 +0000 (21:16 +0900)
GNUmakefile
dot-files/_zshrc
tools/update.pl

index bf199c4d610593d8aa0aab924c20ed6199cf0a1c..d79d0fa54ab601291dc13c541fa7f83d1a02e2db 100644 (file)
@@ -7,5 +7,11 @@ update:
        git pull
        perl ./tools/list-files.pl | perl ./tools/update.pl
        perl ./tools/list-files.pl | perl ./tools/find-outdated.pl
+       git status
+
+commit:
+       git add -A
+       git commit -m 'Auto commit by The Sugar System.'
+       git push
 
 .PHONY: lint
\ No newline at end of file
index b6d220773525b562cc83dad4070d0a22e6f0ee06..85bdc4b9b7d6f321a30a9592e7abe758080b60fe 100644 (file)
@@ -33,7 +33,6 @@ setopt auto_remove_slash
 setopt c_bases
 setopt chase_links
 setopt complete_aliases
-# setopt correct_all
 setopt correct
 setopt equals
 setopt glob_complete
index d91e35a3e519965559c4aae9d4a07adfe0422bfd..624b3eb68c9f8deed9500a03b58d8eaa16531201 100644 (file)
@@ -16,7 +16,14 @@ sub main {
 
         my $abs = File::Spec->rel2abs($rel, $ENV{HOME});
 
-        copy($abs, $saved) or die $!;
+        my $current_st = stat($abs);
+        my $saved_st   = stat($saved);
+
+        if ($current_st->mtime > $saved_st->mtime &&
+              compare($abs, $saved) != 0) {
+            print "Copying $abs to $saved...\n";
+            copy($abs, $saved) or die $!;
+        }
     }
 }