This is a simple commandline Java utility which I wrote down in under 5 minutes to help in checking-in (svn commit) over 500 files which were modified but the dates weren't changed due to an error in our settings. Questo è un semplice programma di utilità di comando di Java che ho scritto in meno di 5 minuti per aiutare nel controllo-in (svn commettere) più di 500 file che sono stati modificati, ma le date non sono stati modificati a causa di un errore nelle nostre impostazioni. So subversion failed to recognize it. Così la sovversione non riconoscerlo. Anyway this simple utility updates the timestamp of any file(s) and directories recursively to current time . Comunque questo programma di utilità semplice aggiorna il timestamp di qualsiasi file (s) e le directory ricorsivamente per ora corrente. It is extremely fast and cross-platform. E 'estremamente veloce e multipiattaforma. It does one job and does it well. Che fa un posto di lavoro e lo fa bene. It is named after the unix utility touch , with similar functionality. E 'il nome dal programma di utilità unix tatto, con funzionalità simili.

 import java.io.File;  /** Super-fast file / directory(recursive) touch. importazione java.io.File; / ** Super-veloce di file / directory (ricorsiva) tatto. *  It doesn't ask for confirmation. * Non chiedere conferma. *  Arguments: File / Directories to touch to current time. * Argomenti: File / Directory a toccare per ora corrente. */ public class Touch {     public static void main(String ... args) {         long time = System.currentTimeMillis();         for(String fileName:args) touch(new File(fileName), time);     }      /** Recursively touch file and directories. * / Public class Touch (public static void main (String ... args) (lungo tempo = System.currentTimeMillis (); for (stringa nome file: args) Touch (nuovo file (filename), il tempo);) / ** ricorrentemente tocco di file e directory. *  @param File (file or directory) for touching. * @ Param file (file o directory) per toccare. */     public static void touch(File file, long time) {         if(file.isDirectory()) for(File childFile:file.listFiles()) touch(childFile, time);         file.setLastModified(time);     } } * / Public static void tocco (File file, lungo tempo) (if (file.isDirectory ()) per (File childFile: file.listFiles ()) touch (childFile, il tempo); file.setLastModified (tempo);)) 

You can also download the È anche possibile scaricare il java executable class file Java class file eseguibile . You can run it as follows: È possibile eseguire come segue:
java -classpath . java-classpath. Touch *.html Touch *. html

Replace *.html with file name(s) and directories you want to update. *. Html sostituire con il nome del file (s) e le directory che si desidera aggiornare. This requires JDK 1.5 or later. Ciò richiede JDK 1,5 o versione successiva.