Package org.alfresco.util
Class Convert
- java.lang.Object
-
- org.alfresco.util.Convert
-
public class Convert extends java.lang.Object
Utility to convert text files. Check the usage options with the --help option. Here are some examples of how to use themain
method:-
--help
Produce the help output. -
--dry-run --encoding=UTF-8 --line-ending=WINDOWS --match="(.java|.xml|.jsp|.properties)$" --ignore="(.svn|classes)" "w:\"
Find all source (.java, .xml, .jsp and .properties) files in directory "w:\".
List files and show which would change when converting to CR-LF (Windows) line endings.
Where auto-detection of the file is ambiguous, assume UTF-8. -
--encoding=UTF-8 --line-ending=WINDOWS --match="(.java|.xml|.jsp|.properties)$" --ignore="(.svn|classes)" "w:\"
Find all source (.java, .xml, .jsp and .properties) files in directory "w:\". Recurse into subdirectories.
Convert files, where necessary, to have CR-LF (Windows) line endings.
Where auto-detection of the file encoding is ambiguous, assume UTF-8.
Backups (.bak) files will be created. -
--svn-update --no-backup --encoding=UTF-8 --line-ending=WINDOWS --match="(.java|.xml|.jsp|.properties)$" "w:\"
Issue a 'svn status' command on directory "w:\" and match the regular expressions given to find files.
Convert files, where necessary, to have CR-LF (Windows) line endings.
Where auto-detection of the file encoding is ambiguous, assume UTF-8. Write out as UTF-8.
No backups files will be created.
- Author:
- Derek Hulley
-
--help
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
main(java.lang.String[] args)
static void
printUsage()
-