undur / vermilingua-maven-plugin

A maven plugin to build WO applications and frameworks
5 stars 1 forks source link

Figure out where ${build.finalName} ends and bundle name begins #15

Closed hugithordarson closed 3 years ago

hugithordarson commented 3 years ago

With reference to #8.

Currently we're using ${build.finalName} as the name of the built Application. Everywhere. I've got a feeling this is wrong, since people might want to add stuff like classifiers, timestamps etc. to the build product, stuff we don't neccessarily want reflected in the bundle name.

Correct semantics are probably: 1) ${finalName} should only control the name of the WOA 2) The actual application name comes from build.properties/${project.name}

timcu commented 3 years ago

When I was using ant I would specify

<property name="build.app.name" value="${project.name}${DSTAMP}${TSTAMP}" />

and it would change the folder name and the script name. ie MyApp20210716125959.woa/MyApp20210716125959.

Now I use wolifecycle-maven-plugin and specify

<properties><build_timestamp>${maven.build.timestamp}</build_timestamp>...</properties>
<build><finalName>${project.artifactId}${maven.build.timestamp}</finalName>...</build>

and only the folder name gets changed. ie MyApp20210716125959.woa/MyApp. I can work with either way but I am finding the wolifecycle-maven-plugin way slightly easier when I deploy new versions. And, as you surmised, it is very important to me to be able to add a timestamp to the folder name.

I am not sure what you are calling the Application name. I searched through my built app and found another file MyApp20210716125959.woa/Contents/MacOS/MyApp20210716125959. I don't think this is being called so I don't care if this has the timestamp or not.

hugithordarson commented 3 years ago

Thanks for the input @timcu! I agree that it's best to change nothing inside the bundle, i.e. use the finalName only for the .WOA.

And pardon for the ambigious terms. When I said "application name" I should have said "bundle name" or "project name". As in "The name given to the project in WOLips and that WO will subsequently use to identify the bundle".

hugithordarson commented 3 years ago

finalName now sets the name of the .WOA folder and nothing else (apart from the interim .jar in /target — the final Jar inside the woa will keep it's name set to the bundle name, as will Launch scripts and the references to them in Info.plist. Case closed.