Skip to content

Commit

Permalink
Fix Github action main.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
iqyx committed Apr 6, 2024
1 parent dc3777b commit e828c39
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
4 changes: 0 additions & 4 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,6 @@ jobs:

- run: |
git fetch --prune --unshallow --no-recurse-submodules
git branch develop
git branch -u origin/develop develop
git branch master
git branch -u origin/master master
- name: Install python venv & dependencies
run: |
Expand Down
7 changes: 6 additions & 1 deletion version.SConscript
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,12 @@ if str(repo.head.ref)[:8] == "feature/":
dev_branch = str(repo.head.ref)
dev_feature = dev_branch[8:]
dev_tag = [str(tag)[:-4] for tag in repo.tags if str(tag)[-3:] == "dev"][-1]
commits_from_develop = len(list(repo.iter_commits("develop..." + dev_branch)))
try:
commits_from_develop = len(list(repo.iter_commits("develop..." + dev_branch)))
except:
# local develop branch doesn't exist (most probably)
commits_from_develop = len(list(repo.iter_commits("origin/develop..." + dev_branch)))

v = dev_tag + "-" + dev_feature + ".%s" % commits_from_develop


Expand Down

0 comments on commit e828c39

Please sign in to comment.