Skip to content

Commit

Permalink
fixup! Added github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
JanGalek committed Dec 9, 2024
1 parent d95264c commit 5bc5e51
Showing 1 changed file with 2 additions and 11 deletions.
13 changes: 2 additions & 11 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,12 +59,7 @@ jobs:
COMMITS="<ul>"
while read -r commit_hash; do
COMMIT_MSG=$(git log -n 1 --pretty=format:"%s" "$commit_hash")
AUTHOR_EMAIL=$(git log -n 1 --pretty=format:"%ae" "$commit_hash")
# Získání GitHub username z API
AUTHOR_USERNAME=$(gh api "/search/users?q=$AUTHOR_EMAIL+in:email" --jq ".items[0].login" || echo "UnknownUser")
AUTHOR=$AUTHOR_USERNAME
AUTHOR=$(gh api "/repos/${{ github.repository }}/commits/$commit_hash" --jq '.author.login')
COMMITS+="<li>$COMMIT_MSG (@$AUTHOR)</li>"
done < <(git log --format="%H" HEAD)
COMMITS+="</ul>"
Expand All @@ -75,11 +70,7 @@ jobs:
# Iterace přes všechny commity od posledního tagu
while read -r commit_hash; do
COMMIT_MSG=$(git log -n 1 --pretty=format:"%s" "$commit_hash")
AUTHOR_EMAIL=$(git log -n 1 --pretty=format:"%ae" "$commit_hash")
# Získání GitHub username z API
AUTHOR_USERNAME=$(gh api "/search/users?q=$AUTHOR_EMAIL+in:email" --jq ".items[0].login" || echo "UnknownUser")
AUTHOR=$AUTHOR_USERNAME
AUTHOR=$(gh api "/repos/${{ github.repository }}/commits/$commit_hash" --jq '.author.login')
# Kontrola, zda jde o fixup commit
if [[ "$COMMIT_MSG" == fixup!* ]]; then
Expand Down

0 comments on commit 5bc5e51

Please sign in to comment.