Quantcast
Channel: UltraEdit, UltraCompare, UEStudio forums
Viewing all articles
Browse latest Browse all 307

Custom User Tools/Tool Configuration • Applying Artistic Style Formatting to multiple .java scripts

$
0
0
I'm using the following version of UltraEdit:
0g60iyzr.png
I'm trying to apply Artisitc Style Formatting to a list of java files/scripts via the command line.

The formatting settings that I'm trying to apply, are as follows:
Artisitc Style Formatter Java.png
When I click the Reformat button while having a java script open, it works as expected.
The command line options which are the result of the above setup are as follows (copied from the above screenshot):

Code:

--style=java --mode=java -Y --convert-tabs --break-blocks --break-elseifs -j --break-after-logical --pad-oper --pad-header
The way I am trying to apply this formatting in bulk, is with a following batch file:

Code:

cd "C:\PathToFolderStructureWithJavaFiles"dir/s/b *.java > FileList.txttimeout 3"C:\Program Files\IDM Computer Solutions\UltraEdit\uedit64.exe" /fni /f FileList.txt --style=java --mode=java -Y --convert-tabs --break-blocks --break-elseifs -j --break-after-logical --pad-oper --pad-header
I'm changing the current directory to the folder with all the subfolder that contain the Java scripts.
Then I'm generating the list of files (FileList.txt) with the ".java" extension in the current directory with:

Code:

dir/s/b *.java > FileList.txt
I use the timeout command to make sure that the file list is generated.
Then, using the information I found on UltraEdit online help I run the final command, which should open the new instance of UltraEdit (/fni) and apply to the files specified in a separate TXT file (/f FileList.txt) the prescribed formatting.
What happens is the instance of UltraEdit is opened, along with all the files specified in the FileList.txt file, however they are not being reformatted.

statistics: Posted by AnxiousLobsterOct 29, 2024 — Replies 3 — Views 29186



Viewing all articles
Browse latest Browse all 307

Trending Articles