mirror of
git://git.yoctoproject.org/layerindex-web.git
synced 2025-07-19 20:59:01 +02:00
scripts/tools/rrs_upgrade_history.py: Fix branch deletion
Add try/catch to branch deletion because at initial loop the branch don't exist. Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
This commit is contained in:
parent
f613270207
commit
c2dc59357a
|
@ -222,7 +222,10 @@ def upgrade_history(logger):
|
||||||
datestr = date.strftime("%Y-%m-%d")
|
datestr = date.strftime("%Y-%m-%d")
|
||||||
date_next = date + timedelta(days=1)
|
date_next = date + timedelta(days=1)
|
||||||
date_nextstr = date_next.strftime("%Y-%m-%d")
|
date_nextstr = date_next.strftime("%Y-%m-%d")
|
||||||
utils.runcmd("git branch -D " + datestr + " &> /dev/null", repodir)
|
try:
|
||||||
|
utils.runcmd("git branch -D " + datestr + " &> /dev/null", repodir)
|
||||||
|
except:
|
||||||
|
pass
|
||||||
utils.runcmd("git checkout -b " + datestr, repodir)
|
utils.runcmd("git checkout -b " + datestr, repodir)
|
||||||
|
|
||||||
# Get commits for the current day
|
# Get commits for the current day
|
||||||
|
|
Loading…
Reference in New Issue
Block a user