-
Notifications
You must be signed in to change notification settings - Fork 340
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Target parameter is resolved from environment variable before command-line positional argument #300
Comments
Hi @RobSmyth, NUKE picks up parameters (including |
Hi @matkoch I appreciate the frank response. Thank you. |
Hi @matkoch , Unfortunately, in order to use Nuke, I need to fork and compile a version of nuke with the environment variable "TARGET" renamed to something like "NUKE_TARGET". But looking at the source code I do not see where it is reading the environment variable "TARGET". Can you help me find the code? |
I assume you called |
Hi matkoch, Sorry I have not given this the attention I should have. But coming back to this issue it looks like you have redefined my issue as being about command line argument having precedence over an environment variable and that has been fixed. Thank you. The fix done is good but it is a work around and does not fix the issue I reported. We are building by a command "nuke" (without parameters). That fails and I assume it will still fail as Nuke and another application are both using an environment variable "TARGET". I put that both apps have a bug in that neither should be using such a generic environment variable name. So, while thank you for your providing a work around, I think the reported issue remains. What is the best way to deal with that? Rename this issue or I can create a new one? |
Except from unsetting the environment variable or explicitly passing the targets, I guess you can't do anything. For the 1.0 release, we will introduce |
Yes the NUKE_ prefix is a solution to the bug. Given that you have that on a todo list I do not think an open issue is necessary. Thanks. |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Hi,
My Windows development environment has a system environment variable "Target". It seems that Nuke keeps picking this up in preference to the command line as I get an error that target "XX" (value of the environment variable) does not exist.
I'm running:
nuke --target Compile
(I'm a newbie, so maybe I'm just getting the command line wrong?)
It does the same when I invoke via the PowerShell script build.ps1 without arguments.
The text was updated successfully, but these errors were encountered: