ctubbsii commented on issue #275:
URL: https://github.com/apache/fluo-uno/issues/275#issuecomment-976929559


   @milleruntime wrote:
   > Since we have scripts calling other scripts, it may be less confusing to 
just refactor the scripts to not use shift. Otherwise, we may have to do lots 
of checking of the parameters to figure out if they were shifted or not.
   
   `shift` merely strips `$1` out of the functions `$@` argument list, so that 
`$@` now contains only the stuff after the first argument. This is done 
correctly in both those methods, where `$component` is read from `$1`, and then 
`shift` is called to pass the remaining `$@` to the next script.
   
   @Manno15 wrote:
   > Apparently the issue in this case is the extra "$component" added in the 
script call:
   > 
   > 
https://github.com/apache/fluo-uno/blob/fc519d6b4a407575f3ce73ad28d33869a98021f9/bin/impl/util.sh#L102
   > 
   > Removing that fixed the position issue.
   
   I think that's the right fix. I think this was a bug that was introduced 
when the run command was refactored from a single script, prior to which we had 
to pass the component so that single script could know which one to run. Now 
that they are running their own `$component.sh`, it shouldn't be necessary to 
pass the component anymore. However, each possible `impl/run/*.sh` should be 
checked to make sure they process their parameters correctly and aren't relying 
on that extra `$component` being present.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to