niallsco / kettle-cookbook

Automatically exported from code.google.com/p/kettle-cookbook
GNU Lesser General Public License v3.0
1 stars 0 forks source link

Parameterised command line issue #31

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
sh ${WORKSPACE}/etl/data-integration/software/4.1/data-integration/kitchen.sh 
-file=${WORKSPACE}/etl/data-integration/software/kettle-cookbook/pdi/document-al
l.kjb -param:"INPUT_DIR"=${WORKSPACE}/etl/data-integration/projects/wex/code/ 
-param:"OUTPUT_DIR"=${WORKSPACE}/output

The toc doesn't link properly and every entry is linked to html.html, but their 
names are correct so I know it mostly works, oh and I can't get the hierarchy 
display to display anything at all either.

But when I remove the input dir params ${WORKSPACE} directive, it populates the 
category toc properly(still no hierarchy though).

Anyway the long and short of if is I need the ${WORKSPACE} directive, or a 
variation on a theme cause hudson is running this for me and the exe directory 
is arbitrary.

Original issue reported on code.google.com by TomBarbe...@googlemail.com on 2 Dec 2010 at 1:59

GoogleCodeExporter commented 9 years ago

Original comment by roland.bouman on 2 Dec 2010 at 2:08

GoogleCodeExporter commented 9 years ago
For the Kettle API it is easy to replace variables. I was wondering if we 
couldn't create an exporter for Kettle Cookbook that retains file structures 
and all but simply replaces variables to get an absolute path.  Let me know if 
you need a solution like that and I'll be happy to help out.

Original comment by mattcast...@gmail.com on 3 Dec 2010 at 11:55

GoogleCodeExporter commented 9 years ago
Hi Matt! thanks for your comment. 

I have been thinking about replacing variables inside the cookbook job. But 
when looking at trouts command, I was wondering, why isn't the parameter value 
already expanded by the shell? I mean, in the first part:

sh ${WORKSPACE}/etl/data-integration/software/4.1/data-integration/kitchen.sh 
-file=${WORKSPACE}/etl/data-integration/software/kettle-cookbook/pdi/document-al
l.kjb 

its seems to me that it is the shell that expands ${WORKSPACE} to whatever the 
value is of the (shell) environment variable WORKSPACE. Presumably that 
variable will be set to some value so that the resultant paths actually point 
to the on-disk location of the kettle software, and the on-disk location of the 
kettle cookbook PDI job. 

But for some reason, the occurrence of ${WORKSPACE} in the kettle parameters 
does not seem to be replaced automatically by the shell. I am no UNIX shell 
script guy, so I don't know why that is not the case. But I hope it may be 
fixed at that level so cookbook can always presume the parameters are good to 
go.

Original comment by roland.bouman on 3 Dec 2010 at 3:08

GoogleCodeExporter commented 9 years ago
Issue 33 has been merged into this issue.

Original comment by roland.bouman on 17 Dec 2010 at 8:09

GoogleCodeExporter commented 9 years ago

Original comment by roland.bouman on 17 Dec 2010 at 11:53

GoogleCodeExporter commented 9 years ago
A fix for this issue was added in r64

Original comment by roland.bouman on 18 Dec 2010 at 1:38