Skip to content

Commit a4d828d

Browse files
authored
Merge pull request #11 from Asqit/feat/2862025
Feat/2862025
2 parents b015660 + e69c57c commit a4d828d

File tree

4 files changed

+37
-15
lines changed

4 files changed

+37
-15
lines changed
Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,20 @@
1-
name: Build Charon (macOS)
1+
name: Release Charon (macOS Universal)
22

33
on:
44
push:
55
branches:
6-
- main
6+
- main # Trigger only on push to main
7+
8+
env:
9+
NODE_OPTIONS: "--max-old-space-size=4096"
710

811
jobs:
912
build-macos:
10-
name: 🔨 Build macOS App
13+
name: 🔨 Build macOS App (x86_64 and arm64)
1114
runs-on: macos-latest
15+
strategy:
16+
matrix:
17+
arch: [x86_64, arm64]
1218

1319
steps:
1420
- name: ⬇️ Checkout Code
@@ -30,14 +36,17 @@ jobs:
3036
- name: 📦 Install Frontend Dependencies
3137
run: |
3238
cd frontend
33-
npm install
39+
npm ci
3440
npm run build
3541
36-
- name: 🔨 Build App via Makefile (includes ffmpeg copy)
37-
run: make build
42+
- name: 🔨 Build App for ${{ matrix.arch }}
43+
run: |
44+
export UNAME=${{ matrix.arch }}
45+
make clean
46+
make build
3847
3948
- name: 📤 Upload Built App Artifact
4049
uses: actions/upload-artifact@v4
4150
with:
42-
name: charon-macos-app
51+
name: charon-macos-${{ matrix.arch }}
4352
path: build/bin/charon.app

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
11

2+
## 0.4.0 - 28.06.2025
3+
### Added
4+
- updated bump.py for more convinient changelog editing
5+
- updated release action (hopefully works)
6+
27
## 0.3.0 - 28.06.2025
38
### Added
49
-## 0.2.0 - 23.06.2025

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.3.0
1+
0.4.0

bump.py

Lines changed: 15 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import subprocess
33
import datetime
44
import sys
5-
5+
import os
66

77
def read_version() -> str:
88
with open("VERSION", "r") as file:
@@ -15,14 +15,21 @@ def write_version(version: str) -> None:
1515

1616

1717
def add_changelog_record(version: str) -> None:
18+
editor = os.environ.get('EDITOR', 'TextEdit')
1819
today = datetime.date.today()
1920
formatted = today.strftime("%d.%m.%Y")
20-
with open("CHANGELOG.md", "r", encoding="utf-8") as file:
21-
prev = file.read()
22-
prev = f"\n## {version} - {formatted}\n### Added\n-" + prev
21+
prev: str = ""
22+
23+
with open("CHANGELOG.md", "r", encoding="UTF-8") as readFile:
24+
prev = readFile.read()
25+
prev = f"\n## {version} - {formatted}\n### Added\n-\n" + prev
26+
27+
with open("CHANGELOG.md", "w", encoding="utf-8") as writeFile:
28+
writeFile.write(prev)
2329

24-
with open("CHANGELOG.md", "w", encoding="utf-8") as file:
25-
file.write(prev)
30+
exit_code = subprocess.Popen([editor, "CHANGELOG.md"]).wait()
31+
if exit_code > 0:
32+
print("failed to update changelog")
2633

2734

2835
def bump(current: str, part: str) -> str:
@@ -45,7 +52,7 @@ def git_tag(version) -> None:
4552
subprocess.run(["git", "add", "."])
4653
subprocess.run(["git", "commit", "-m", f"Release v{version}"])
4754
subprocess.run(["git", "tag", "-a", f"v{version}", "-m", f"Release v{version}"])
48-
subprocess.run(["git", "push", "--follow-tags"])
55+
# subprocess.run(["git", "push", "--follow-tags"])
4956

5057

5158
def main() -> None:
@@ -61,6 +68,7 @@ def main() -> None:
6168
git_tag(new_version)
6269

6370
print(f"✔️ Bumped to v{new_version}")
71+
print("to continue do `git push --follow-tags` to push to remote with your latest tags")
6472

6573

6674
if __name__ == "__main__":

0 commit comments

Comments
 (0)