Updated pipeline to use submodule of recipe repo fork
Some checks failed
autoBIGS.cli-bioconda/pipeline/head There was a failure building this commit

This commit is contained in:
Harrison Deng 2025-02-26 17:22:14 +00:00
parent 65a3bc3f64
commit c0a5c34380
3 changed files with 35 additions and 21 deletions

3
.gitmodules vendored Normal file
View File

@ -0,0 +1,3 @@
[submodule "auto-updated-bioconda-recipes"]
path = auto-updated-bioconda-recipes
url = https://github.com/Syph-and-VPD-Lab/auto-updated-bioconda-recipes.git

52
Jenkinsfile vendored
View File

@ -6,14 +6,23 @@ pipeline {
inheritFrom 'miniforge' inheritFrom 'miniforge'
} }
} }
environment {
TOOL_VER = """${sh(
returnStdout: true,
script: 'python pypi_latest_ver.py autoBIGS.cli'
)}"""
}
stages { stages {
stage("prepare") { stage("prepare") {
parallel { parallel {
stage("recipes repo") { stage("recipes repo") {
steps { steps {
sh 'git clone https://github.com/Syph-and-VPD-Lab/auto-updated-bioconda-recipes.git' sh 'git config --global --add safe.directory /home/jenkins/agent/workspace/autoBIGS.cli-bioconda_main'
sh 'git config --global --add safe.directory /home/jenkins/agent/workspace/autoBIGS.cli-bioconda_main/auto-updated-bioconda-recipes'
sh 'git submodule init'
sh 'git submodule update'
dir('auto-updated-bioconda-recipes') { dir('auto-updated-bioconda-recipes') {
sh 'git checkout update-autobigs-cli' sh 'git checkout -b update-autobigs-cli-${TOOL_VER}'
} }
} }
} }
@ -30,31 +39,32 @@ pipeline {
sh 'grayskull pypi autoBIGS.cli --maintainers "Harrison Deng"' sh 'grayskull pypi autoBIGS.cli --maintainers "Harrison Deng"'
sh 'python patch_recipe.py' sh 'python patch_recipe.py'
sh 'cp -r autobigs-cli/* auto-updated-bioconda-recipes/recipes/autobigs-cli/.' sh 'cp -r autobigs-cli/* auto-updated-bioconda-recipes/recipes/autobigs-cli/.'
sh 'cat auto-updated-bioconda-recipes/recipes/autobigs-cli/meta.yaml'
}
}
stage("lint") {
steps {
dir('auto-updated-bioconda-recipes') {
sh 'bioconda-utils lint recipes/ --packages autobigs-cli'
}
} }
} }
stage("build") { stage("build") {
steps { steps {
dir('auto-updated-bioconda-recipes') { sh 'conda build auto-updated-bioconda-recipes/recipes/autobigs-cli --output-folder ./conda-bld'
sh 'conda build recipes/autobigs-cli'
}
} }
} }
stage("commit") { stage("publish to bioconda") {
environment { stages {
TOKEN = credentials('github.com') stage('lint') {
} steps {
steps { dir('auto-updated-bioconda-recipes') {
dir('auto-updated-bioconda-recipes') { sh 'bioconda-utils lint recipes/ --packages autobigs-cli'
sh 'git commit -a -m "Automatically updated autobigs-cli bioconda recipe to $(python ../pypi_latest_ver.py autoBIGS.cli)."' }
sh 'git push https://${TOKEN}@github.com/Syph-and-VPD-Lab/auto-updated-bioconda-recipes.git update-autobigs-cli' }
}
stage('commit') {
environment {
TOKEN = credentials('github.com')
}
steps {
dir('auto-updated-bioconda-recipes') {
sh 'git commit -a -m "Automatically updated autobigs-cli bioconda recipe to ${TOOL_VER}."'
sh 'git push https://${TOKEN}@github.com/Syph-and-VPD-Lab/auto-updated-bioconda-recipes.git update-autobigs-cli'
}
}
} }
} }
} }

@ -0,0 +1 @@
Subproject commit d3a720566fbbc63e32571ade8d643a6f6b1a4e25