From d6d25c33d9cbed93f653da0bb22af9b349fded40 Mon Sep 17 00:00:00 2001 From: Ravi Sundriyal Date: Thu, 14 Nov 2024 16:30:22 -0500 Subject: [PATCH] Jenkins: Archive the cargo vcs file Adds clamav cargo vcs info for each rust component. --- Jenkinsfile | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 3b3b1aa924..e75ea0f31e 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -89,7 +89,7 @@ pipeline { dir(path: 'docs/html') { sh """# Move the clamav-documentation here. - cp -r ../../clamav_documentation/ . + cp -r ../../clamav_documentation/* . # Clean-up rm -rf ../../clamav_documentation rm -rf .git .nojekyll CNAME Placeholder || true @@ -122,6 +122,13 @@ pipeline { cpack --config CPackSourceConfig.cmake """ archiveArtifacts(artifacts: "clamav-${params.VERSION}*.tar.gz", onlyIfSuccessful: true) + + sh """ + jq -n '[ inputs | .package_version = (input_filename | split("/") | .[-2])]' $HOME/.cargo/registry/src/*/*/.cargo_vcs_info.json > clamav_cargo_vcs_info.json + """ + + archiveArtifacts(artifacts: "clamav_cargo_vcs_info.json", onlyIfSuccessful: true) + } cleanWs() }