H/secret temp changed #7
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Preprod Burgan Git Flow Checker | |
on: | |
pull_request: | |
branches: | |
- preprod | |
jobs: | |
check_commits_preprod: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Checkout PR Branch | |
uses: actions/checkout@v2 | |
with: | |
ref: ${{ github.event.pull_request.head.sha }} | |
fetch-depth: 0 | |
- name: Source Branch PR Checker | |
run: | | |
if [[ "$GITHUB_HEAD_REF" == "test" || "$GITHUB_HEAD_REF" == "dev" ]]; then | |
echo "Lütfen kendi branch'inizden PR oluşturun." | |
exit 1 | |
fi | |
- name: Check Dev Branch for Commits | |
run: | | |
commit=${{ github.event.pull_request.head.sha }} | |
git checkout origin/dev | |
git log --oneline | grep $(echo ${commit:0:5}) | |
echo "Commit'lerinizi önce Dev branchine PR yapmalısınız." | |
- name: Check Test Branch for Commits | |
run: | | |
commit=${{ github.event.pull_request.head.sha }} | |
git checkout origin/test | |
git log --oneline | grep $(echo ${commit:0:5}) | |
echo "Commit'lerinizi önce Test branchine PR yapmalısınız." | |