I tried using this this conversion utility to convert Hello World jacl script to jython by following these steps
- Create test.jacl script like this
puts "Hello world"
- Then go to <applicationservertoolkitroot>/bin folder and execute
Jacl2Jython.bat c:\temp\test.jaclto convert my test.jacl into jython file
- The conversion utility creates a .py file in the same directory as that of the .jacl script, in my case it created test.py file like this
if (len(inStr)>0 and inStr=='[' and inStr[-1]==']'):
tmpList = inStr[1:-1].split(" ")
tmpList = inStr.split("\n") #splits for Windows or Linux
for item in tmpList:
item = item.rstrip(); #removes any Windows "\r"
print "Hello world"
If you search for wsadmin script samples on google most of the examples that you will find are developed using the JACL syntax so this utility comes in handy to convert those samples into jython