Skip to content

Commit 3f370cc

Browse files
committed
(chore): Rework github workflows
1 parent 061f381 commit 3f370cc

11 files changed

+146
-217
lines changed

.github/pull_request_template.md

Lines changed: 30 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,45 @@
11
<!--- IMPORTANT: If this PR addresses multiple unrelated issues, it will be closed until separated. -->
22

3-
### Description
3+
### Overview
44

5-
<!--- REQUIRED: Describe what changed in detail -->
5+
<!--- REQUIRED: Provide a brief summary of what this PR does and its purpose. -->
66

7-
### Related issues
7+
### Implementation Details
8+
9+
<!--- REQUIRED: Describe the changes made in the implementation. Highlight any key decisions or trade-offs. -->
10+
11+
### Related Issues
812

913
<!--- REQUIRED: Tag all related issues (e.g. * #123) -->
10-
<!--- If this PR resolves the issue please specify (e.g. * closes #123) -->
11-
<!--- If this PR addresses multiple issues, these issues must be related to one other -->
14+
<!--- If this PR resolves an issue, please specify (e.g. * closes #123) -->
15+
<!--- If this PR addresses multiple issues, these issues must be related to one another. -->
16+
17+
* Related Issues:
18+
- * #ISSUE_NUMBER
1219

13-
* #ISSUE_NUMBER
20+
### Testing
21+
22+
<!--- REQUIRED: Describe how you tested your changes. Include any relevant test cases or scenarios. -->
1423

1524
### Checklist
1625

17-
<!--- Add things that are not yet implemented above -->
26+
<!--- Please ensure the following are completed before submitting your PR: -->
1827

19-
- [ ] I read and understood the [contributing guide](https://github.com/ScribbleLabApp/ScribbleLab/blob/main/CONTRIBUTING.md) as well as the [code of conduct](https://github.com/ScribbleLabApp/ScribbleLab/blob/main/CODE_OF_CONDUCT.md)
20-
- [ ] The issues this PR addresses are related to each other
21-
- [ ] My changes generate no new warnings
22-
- [ ] My code builds and runs on my machine
23-
- [ ] My changes are all related to the related issue above
24-
- [ ] I documented my code
25-
- [ ] I fixed all my swiftlint warnings
28+
- [ ] I have read and understood the [contributing guide](https://github.com/ScribbleLabApp/ScribbleLab/blob/main/CONTRIBUTING.md) and the [code of conduct](https://github.com/ScribbleLabApp/ScribbleLab/blob/main/CODE_OF_CONDUCT.md).
29+
- [ ] The issues this PR addresses are related to one another.
30+
- [ ] My changes generate no new warnings.
31+
- [ ] My code builds and runs on my machine without errors.
32+
- [ ] I have documented my code where applicable.
33+
- [ ] I have added tests to cover my changes, if applicable.
34+
- [ ] All existing tests pass.
35+
- [ ] I have fixed all SwiftLint warnings.
2636

2737
### Screenshots
2838

29-
<!--- REQUIRED: if issue is UI related -->
39+
<!--- OPTIONAL: If this issue is UI-related, include before and after screenshots or mockups. -->
40+
41+
### Additional Notes
42+
43+
<!--- OPTIONAL: Include any other information that may be relevant to the PR. For example, potential impacts, known issues, or future considerations. -->
3044

31-
<!--- IMPORTANT: Fill out all required fields. Otherwise we might close this PR temporarily -->
45+
<!--- IMPORTANT: Fill out all required fields. Otherwise, we might close this PR temporarily. -->

.github/workflows/CI-ScribbleLab.yml

Lines changed: 0 additions & 67 deletions
This file was deleted.

.github/workflows/CI-bumb-build-number.yml

Lines changed: 0 additions & 39 deletions
This file was deleted.

.github/workflows/greetings.yml renamed to .github/workflows/autorespond.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Greetings
1+
name: Autoresponder
22

33
on: [pull_request_target, issues]
44

@@ -12,5 +12,5 @@ jobs:
1212
- uses: actions/first-interaction@v1
1313
with:
1414
repo-token: ${{ secrets.GITHUB_TOKEN }}
15-
issue-message: "Hi there, Thank you for reporting this issue - @N3v1 will look into it. To make communication even better join our Discord Community [here]() `(not available yet)`."
16-
pr-message: "Hi there, Thank you for creating this PR - @N3v1 will look into it. To make communication even better join our Discord Community [here]() `(not available yet)."
15+
issue-message: "Hi there, Thank you for reporting this issue - Our maintainers and interns will soon respond. To make communication even better join our Discord Community [here](https://discord.gg/Y5mUJbNC8h)."
16+
pr-message: "Hi there, Thank you for creating this PR - Our maintainers and interns will soon respond. To make communication even better join our Discord Community [here](https://discord.gg/Y5mUJbNC8h)."

.github/workflows/build_test.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: Build & Test ScribbleLab
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
branches:
9+
- main
10+
11+
jobs:
12+
build:
13+
runs-on: macos-latest
14+
15+
strategy:
16+
matrix:
17+
os: [macOS, iOS]
18+
configuration: [Alpha, Beta, Debug, Release]
19+
20+
steps:
21+
- name: Check out the repository
22+
uses: actions/checkout@v4
23+
24+
- name: Select Xcode version
25+
run: sudo xcode-select --switch /Applications/Xcode_16.app/Contents/Developer
26+
27+
- name: Install dependencies
28+
run: |
29+
swift package update
30+
31+
- name: Build project using Matrix build system
32+
run: |
33+
if [ "${{ matrix.os }}" == "iOS" ]; then
34+
xcodebuild -scheme ScribbleLab -configuration ${{ matrix.configuration }} build
35+
else
36+
xcodebuild -scheme ScribbleLab -configuration ${{ matrix.configuration }} build
37+
fi
38+
39+
- name: Run Tests
40+
run: |
41+
if [ "${{ matrix.os }}" == "iOS" ]; then
42+
xcodebuild test -scheme ScribbleLab -configuration ${{ matrix.configuration }}
43+
else
44+
xcodebuild test -scheme ScribbleLab -configuration ${{ matrix.configuration }}
45+
fi
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: Compile gyb sources
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
branches:
9+
- main
10+
11+
jobs:
12+
compile_gyb_sources:
13+
runs-on: macOS-latest
14+
steps:
15+
- name: Checkout code
16+
uses: actions/checkout@v3
17+
- name: Run generate_sources.sh
18+
run: |
19+
chmod +x ./Utilities/generate_sources.sh
20+
./Utilities/generate_sources.sh
21+
22+
- name: Check for changes
23+
id: check_changes
24+
run: |
25+
git diff --quiet || echo "Change detected"
26+
- name: Commit and push changes
27+
if: steps.check_changes.outputs.changed == 'true'
28+
run: |
29+
git config user.name "GitHub Actions"
30+
git config user.email "actions@github.com"
31+
git add .
32+
git commit -m "(automated/ci): Generate missing swift.gyb Sources"
33+
git push origin HEAD:automated-update-sourcefile-generation
34+
- name: Install GitHub CLI on macOS
35+
run: |
36+
brew install gh
37+
38+
- name: Create Pull Request
39+
if: steps.check_changes.outputs.changed == 'true'
40+
run: |
41+
gh auth login --with-token <<< "${{ secrets.GITHUB_TOKEN }}"
42+
gh pr create --title "Automated compiling of gyb sources" \
43+
--body "This pull request includes newly generated sources after running the gyb compilation." \
44+
--base main \
45+
--head automated-update-sourcefile-generation \
46+
--repo ${{ github.repository }}

.github/workflows/update-spm.yml renamed to .github/workflows/dependencies.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
1-
name: Update SPM
1+
name: Update Dependencies
22

33
on:
44
schedule:
5-
- cron: '0 0 */2 * *' # Run every 2 days
5+
- cron: '0 0 */2 * *'
66
workflow_dispatch:
77

88
jobs:
99
update-dependencies:
10-
runs-on: macos-14
10+
runs-on: macos-latest
1111

1212
steps:
1313
- name: Select Xcode
14-
run: sudo xcode-select -switch /Applications/Xcode_15.0.1.app/Contents/Developer
14+
run: sudo xcode-select -switch /Applications/Xcode_16.app/Contents/Developer
1515

1616
- name: Delete DerivedData directory
1717
run: rm -rf ~/Library/Developer/Xcode/DerivedData
@@ -36,7 +36,7 @@ jobs:
3636
git config --local user.name "GitHub Actions"
3737
git checkout -b auto-update-dependencies
3838
git add .
39-
git commit -m "Auto-update dependencies"
39+
git commit -m "(chore/ci): Auto-update dependencies"
4040
git push origin auto-update-dependencies
4141
4242
- name: Create Pull Request

.github/workflows/lint.yml

Lines changed: 0 additions & 13 deletions
This file was deleted.

.github/workflows/publish-pages.yml

Lines changed: 0 additions & 48 deletions
This file was deleted.

0 commit comments

Comments
 (0)