-
Notifications
You must be signed in to change notification settings - Fork 15
Description
Describe your use-case which is not covered by existing documentation.
If I create a Stashed file parameter named "my_file", and after choosing "Build with Parameters" the parameter params.my_file is null. This is unexpected as we're typically validating parameters by accessing them this way.
Through internal conversation I've learned that (in this particular case) my_file_FILENAME will be unset if the file is missing. It would be good to mention this in the documentation explicitly, as the build will happily continue without providing a file.
Reference any relevant documentation, other materials or issues/pull requests that can be used for inspiration.
https://plugins.jenkins.io/file-parameters/
Accessing original upload filename
Original filename will be stored in evironment in <parameter_name>_FILENAME variable - assuming parameter is named FILE, snippet below will give you file with original filename in current workspace:
node {
unstash 'FILE'
sh 'mv FILE $FILE_FILENAME'
}
Potentially related to: #26 as a feature.
Also related: #217
It's kinda there, but not quite...
Are you interested in contributing to the documentation?
No response