Did this two different ways in the same workspace. 
../workspace/Pipeline01/Artifact/my.zip
../workspace/Pipeline01/clonedRepo/

One for the artifact I needed.   
For this I used an attribute in the CopyArtifact plugin, like this 
(declarative pipeline):
stages {
    stage('Copy Archive') {
        steps {
            script {
                step ([$class: 'CopyArtifact',
                projectName: 'Create_archive',
                filter: "packages/my.zip",
                target: 'Artifact']);


And another for the code which was getting cloned.   
For this I used the "Check out to sub-directory" feature in the git plugin, 
like this:

<https://lh3.googleusercontent.com/-PorSaP02xBQ/Wdflji7qAUI/AAAAAAAAAE4/pDXzJCTkLHQ-HnvRiqZY3DzzlXBjrU2nACLcBGAs/s1600/CheckoutToSubDir.PNG>



-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/f6b55274-4823-47e3-b1a7-46892e9d3601%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to