externpro / buildpro

build images for projects that use externpro
MIT License
2 stars 1 forks source link

use ARG BPROTAG #54

Closed smanders closed 1 year ago

smanders commented 1 year ago

every release I manually change the TAG from latest to the tagged release number for example: 'latest' to '23.03.1' https://github.com/smanders/buildpro/commit/a496a5e9669e40f9ef71e4cf3ca57908f284b4d1

and then I manually change the TAG from the tagged release to latest https://github.com/smanders/buildpro/commit/f4e1e8f14d5830884931cf1a2a7e639fbb5b565d

it would be nice to automate this! using a BPROTAG environment variable

if building buildpro, it should use the tagged release if on the tagged release commit, and 'latest' if there are untracked changes or on a commit that's not a tagged release commit

similar to what it already done in a couple of scripts, for example ghimg.sh https://github.com/smanders/buildpro/blob/23.03/public/ghimg.sh#L3-L6

gtag=`git describe --tags`
if [ -n "$(git status --porcelain --untracked=no)" ] || [[ ${gtag} == *"-g"* ]]; then
  gtag=latest
fi

for a project that's using buildpro (a copy of the .devcontainer/ directory), look in toplevel.cmake for

set(buildpro_REV

similar to other releases that we track that way (externpro, internpro, webpro, etc)

smanders commented 1 year ago

haha, used "fix" in commit message

smanders commented 1 year ago

completed with commits to dev branch referenced above

smanders commented 1 year ago

[extern|intern]pro need to look for buildpro_REV in CMakeLists.txt (not toplevel.cmake)

smanders commented 1 year ago

last commit fixes externpro, internpro search for buildpro_REV