Skip to content

Commit

Permalink
Merge pull request #34 from mwestphall/SOFTWARE-5621-osg-23-naming-co…
Browse files Browse the repository at this point in the history
…nventions

SOFTWARE-5621: osg 23 naming conventions
  • Loading branch information
matyasselmeci authored Jul 27, 2023
2 parents a3e0413 + b3fd362 commit 8412bf3
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 8 deletions.
4 changes: 2 additions & 2 deletions bin/new_mashfile.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ title () { python -c 'import sys; print sys.argv[1].title()' "$*" ; }

TAG=$1
case $TAG in
osg-3.*-upcoming-*-* ) IFS='-' read osg SERIES upcoming DVER REPO <<< "$TAG"
SERIES+=-$upcoming ;;
osg-*-*-*-* ) IFS='-' read osg SERIES branch DVER REPO <<< "$TAG"
SERIES+=-$branch ;;
osg-*-*-* ) IFS='-' read osg SERIES DVER REPO <<< "$TAG" ;;
devops-*-*) IFS='-' read SERIES DVER REPO <<< "$TAG" ;;
* ) usage ;;
Expand Down
2 changes: 1 addition & 1 deletion bin/update_mashfiles.sh
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ else

[[ -e $OSGTAGS.exclude ]] || touch $OSGTAGS.exclude

osg_seriespat='[0-9]+\.[0-9]+(-upcoming)?'
osg_seriespat='([0-9]+\.[0-9]+|[2-9][0-9])(-upcoming|-main)?'
osg_repopat='contrib|development|release|rolling|testing|empty'
osg_tagpat="osg-($osg_seriespat)-el[5-9]-($osg_repopat)"
devops_tagpat='devops-el[7-9]-(itb|production)'
Expand Down
7 changes: 4 additions & 3 deletions bin/update_mirror.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import socket
import fcntl
import errno
import re

def log(log):
print("[%s]"%sys.argv[0], time.strftime("%a %m/%d/%y %H:%M:%S %Z: ", time.localtime()), log)
Expand Down Expand Up @@ -58,9 +59,9 @@ def lock(path):
hostname="repo-itb.opensciencegrid.org"

def tagsplit(tag):
if 'upcoming' in tag and tag.startswith("osg-3."):
series,_,dver,repo = tag.split('-')[-4:]
series += "-upcoming"
if re.match(r'osg-[0-9.]*-[a-z]*-el[0-9]+-[a-z]*', tag):
series,branch,dver,repo = tag.split('-')[-4:]
series += "-" + branch
else:
series,dver,repo = tag.split('-')[-3:]
return series,dver,repo
Expand Down
4 changes: 2 additions & 2 deletions bin/update_repo.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ usage () {
TAG=$1

case $TAG in
osg-3.*-upcoming-*-* ) IFS='-' read osg SERIES upcoming DVER REPO <<< "$TAG"
SERIES+=-$upcoming ;;
osg-*-*-*-* ) IFS='-' read osg SERIES branch DVER REPO <<< "$TAG"
SERIES+=-$branch ;;
osg-*-*-* ) IFS='-' read osg SERIES DVER REPO <<< "$TAG" ;;
devops-*-*) IFS='-' read SERIES DVER REPO <<< "$TAG" ;;
* ) usage ;;
Expand Down

0 comments on commit 8412bf3

Please sign in to comment.