-
Notifications
You must be signed in to change notification settings - Fork 17
40 lines (40 loc) · 1.3 KB
/
upload.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
name: Upload
permissions:
contents: write
on:
workflow_dispatch:
#inputs:
# version:
# description: 'Version Number'
# required: true
jobs:
merge_and_update:
runs-on: macos-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Configure Git
run: |
git config user.name github-actions
git config user.email github-actions@github.com
- name: Force merge develop into master
run: |
git checkout master
git merge -X theirs --no-edit origin/develop || (
git merge --abort
git reset --hard origin/develop
echo "Merge failed. Master reset to develop."
)
# We manually change the version number for now
#- name: Update version in Xcode project
# run: |
# /usr/libexec/PlistBuddy -c "Set :CFBundleShortVersionString ${{ github.event.inputs.version }}" "Supporting Files/Info.plist"
# /usr/libexec/PlistBuddy -c "Set :CFBundleIdentifier org.YuKaBu.app" "Supporting Files/Info.plist"
#- name: Commit version change
# run: |
# git add .
# git commit -m "Upload with Version ${{ github.event.inputs.version }}" --allow-empty
- name: Force push changes
run: git push --force origin master