Thanks to java portability. This helps to develop code in Windows system and deploy in UNIX system. But sometimes it brings some more steps to be included to ant build script. Most of the time need to run dos2unix and make it as executable (mode) at the time of deployment. This can be easily controlled by adding below steps in ant script.
Removing special codes from executable files, so that it will be compatible with UNIX system.
<fixcrlf eof="remove" eol="lf" includes="**/*.sh" srcdir="${src}">
Replaces EOLs with LF characters and removes eof characters from the shell scripts. Tabs and spaces are left as is.
Changing the file type as executable by setting mode=755 at the time of tar
<tarfileset dir="${src}" mode="755" prefix="/bin">
<include name="runScript.sh">
</tarfileset>
Sample ant build script:
<?xml version="1.0" encoding="UTF-8"?>
<project name="doscommands" default="test" basedir=".">
<target name="test" depends="">
<echo message="Fixing dos2unix"/>
<fixcrlf srcdir="." includes="**/*.sh" eol="lf" eof="remove" />
<echo message="Fixed dos2unix"/>
<echo message="Fixing chmod to 755"/>
<chmod dir="." perm="755" includes="**/*.*"/>
<echo message="Fixed chmod to 755"/>
</target>
</project>
Wednesday, October 3, 2007
Subscribe to:
Post Comments (Atom)
5 comments:
converse shoes
yeezy 500 blush
golden goose
jordan shoes
vapormax
timberland boots
jordan shoes
christian louboutin outlet
adidas stan smith
nike shoes
bathing ape
supreme hoodie
yeezy shoes
kyrie irving shoes
lebron 16 shoes
golden goose outlet
supreme outlet
yeezy
kd 10
off-white
this contact formfrom this source get redirected herecheck my site have a peek at this web-siteRecommended Reading
helpful hints www.dolabuy.ru Recommended Site Celine Dolabuy his comment is here Dolabuy Louis Vuitton
replica ysl u39 w1d98d9m31 replica gucci bags d25 x2k25q8k06 replica designer bags h47 c7x59o7x12
Post a Comment