Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
ede9bc6
test_mac_build
nb950 Jul 7, 2025
f8e2d52
Update test_mac_build.yml
nb950 Jul 7, 2025
6c94afb
Update test_mac_build.yml
nb950 Jul 7, 2025
9d3238c
Update test_mac_build.yml
nb950 Jul 7, 2025
f358ced
brew install python-setuptools
nb950 Jul 7, 2025
e9fc7de
Update package.json version to 2.1.0
nb950 Jul 7, 2025
8f0fbdf
pip install setuptools
nb950 Jul 7, 2025
8da8023
set github.token
nb950 Jul 7, 2025
81682e5
check dmg file created ok
nb950 Jul 7, 2025
3702d04
Update package-lock.json to 2.1.0
nb950 Jul 7, 2025
e607408
checkout specific branch not main
nb950 Jul 7, 2025
7fa33a5
check specific branch build ok
nb950 Jul 7, 2025
d7d7588
Update package-lock.json
nb950 Jul 7, 2025
c14f822
Update package.json
nb950 Jul 7, 2025
cc24e02
add backend exe build steps
nb950 Jul 7, 2025
5bcf09f
brew install gdown for artifacts
nb950 Jul 7, 2025
09a3a0f
fix unzip typo
nb950 Jul 7, 2025
d3543e4
update gdown
nb950 Jul 8, 2025
4609c8f
fix existing age_detect models
nb950 Jul 8, 2025
b896a19
brew install ffmpeg 7.1.1_3
nb950 Jul 8, 2025
42b8bf0
ffmpeg version 7.1
nb950 Jul 8, 2025
0d67b7e
ffmpeg remove version
nb950 Jul 8, 2025
24baa12
find ffmpeg binary
nb950 Jul 8, 2025
1841599
copy ffmpeg from /opt/homebrew/Cellar
nb950 Jul 8, 2025
ef253dc
fix poetry lock error
nb950 Jul 8, 2025
e2db41a
cp ffmpeg to /usr/local/bin
nb950 Jul 8, 2025
0b49434
add whisper weights file
nb950 Jul 8, 2025
b0de727
Update register-model-service.ts for mac backend startup
nb950 Jul 8, 2025
559bfb8
Update package.json from universal to arm64
nb950 Jul 8, 2025
e09fef5
check for arm64 mac build dmg file
nb950 Jul 8, 2025
c6c2109
update publish repo in package.json
nb950 Jul 9, 2025
eca2eef
Update package.json repo name
nb950 Jul 9, 2025
a15e783
Update test_mac_build.yml to publish always
nb950 Jul 9, 2025
ec9eeee
add permissions
nb950 Jul 10, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
100 changes: 100 additions & 0 deletions .github/workflows/test_mac_build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,100 @@
name: Publish

on:
push:
branches:
- test_mac_build
workflow_dispatch:

permissions:
contents: write

jobs:
publish:
# To enable auto publishing to github, update your electron publisher
# config in package.json > "build" and remove the conditional below
# D:\a\RescueBox-FlaskML-xxx\RescueBox-FlaskML-xxx
if: ${{ github.repository_owner == 'UMass-Rescue' }}

runs-on: ${{ matrix.os }}

strategy:
matrix:
os: [macos-latest]

steps:
- name: Checkout git repo
uses: actions/checkout@v4
with:
ref: 'test_mac_build'

- name: Install Node and NPM
uses: actions/setup-node@v4
with:
node-version: 18
cache: npm
cache-dependency-path: '**/package-lock.json'
- run: npm --version

- name: Install Python
uses: actions/setup-python@v5
with:
python-version: '3.12'

- name: Install and build
env:
GH_TOKEN: ${{ github.token }}
run: |
cd $RUNNER_WORKSPACE/RescueBox
brew install gdown
gdown 1kN8BYEDinWfs9Qv5G1T_bILiwfuT5o-V
ls -lrt
mkdir tmp
cd tmp
unzip ../rb_mac_files.zip
# mv -f age_and_gender_detection/models ../src/age_and_gender_detection
mv face-detection-recognition/face_detection_recognition/models ../src/face-detection-recognition/face_detection_recognition
mv deepfake-detection/deepfake_detection/onnx_models ../src/deepfake-detection/deepfake_detection
mv whisper ..
mv hook.py ..
mv mac.spec ..
rm -f ../pyproject.toml
mv pyproject.toml ../pyproject.toml
cd ..
rm -rf tmp
rm -f rb_mac_files.zip
brew install ffmpeg
brew list ffmpeg | grep "bin/ffmpeg"
ls -l /opt/homebrew/Cellar/ffmpeg/7.1.1_3/bin/ffmpeg
cp /opt/homebrew/Cellar/ffmpeg/7.1.1_3/bin/ffmpeg .
pipx install poetry
rm -f poetry.lock
poetry lock
poetry install
poetry env list
poetry env info
poetry run pyinstaller mac.spec
ls -l dist/rescuebox/rescuebox
if [ -f "dist/rescuebox/rescuebox" ]; then
echo "backend rescuebox exe build ok"
else
echo "backend rescuebox exe build not ok"
exit 1
fi
mv dist RescueBox-Desktop/assets/rb_server
echo "backend rescuebox build completed"
cd $RUNNER_WORKSPACE/RescueBox/RescueBox-Desktop
ls package.json
brew install python-setuptools
python3 -m pip install setuptools
echo "run install"
npm install
echo "run postinstall"
npm run postinstall
echo "run build"
npm run build
echo "run rebuild"
npm run rebuild
echo "run exec"
npm exec electron-builder -- --publish always --mac
shell: sh
4 changes: 2 additions & 2 deletions RescueBox-Desktop/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 6 additions & 6 deletions RescueBox-Desktop/package.json
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
{
"name": "rescuebox-desktop",
"version": "2.0.0",
"version": "2.1.0",
"description": "A foundation for scalable desktop apps",
"keywords": [],
"homepage": "https://github.com/UMass-Rescue/RescueBox-Desktop#readme",
"homepage": "https://github.com/UMass-Rescue/RescueBox#readme",
"bugs": {
"url": "https://github.com/UMass-Rescue/RescueBox-Desktop/issues"
"url": "https://github.com/UMass-Rescue/RescueBox/issues"
},
"repository": {
"type": "git",
"url": "git+https://github.com/UMass-Rescue/RescueBox-Desktop.git"
"url": "git+https://github.com/UMass-Rescue/RescueBox.git"
},
"license": "MIT",
"author": "UMass Rescue Lab",
Expand Down Expand Up @@ -265,7 +265,7 @@
"target": {
"target": "default",
"arch": [
"universal"
"arm64"
]
},
"additionalArguments": [
Expand Down Expand Up @@ -330,7 +330,7 @@
"publish": {
"provider": "github",
"owner": "UMass-Rescue",
"repo": "RescueBox-Desktop"
"repo": "RescueBox"
}
},
"electronmon": {
Expand Down
4 changes: 2 additions & 2 deletions RescueBox-Desktop/release/app/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion RescueBox-Desktop/release/app/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "RescueBox-Desktop",
"version": "2.0.0",
"version": "2.1.0",
"description": "A desktop application with a collection of ML models for forensics, and a job engine to run them",
"license": "MIT",
"author": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export default class RegisterModelService {
'dist',
'rescuebox',
);
public static serverExe = path.join(RegisterModelService.serverPath, 'rescuebox.exe',);
public static serverExe = path.join(RegisterModelService.serverPath, 'rescuebox',);
public static childprocess: ChildProcess;

public static async startServer() {
Expand All @@ -62,6 +62,9 @@ export default class RegisterModelService {
};
if (RegisterModelService.IS_SERVER_RUNNING)
return;
if (process.platform === 'win32') {
RegisterModelService.serverExe = path.join(RegisterModelService.serverPath, 'rescuebox.exe',);
}
RegisterModelService.childprocess = spawn(RegisterModelService.serverExe, options, defaults);
if (RegisterModelService.childprocess != null) {
RegisterModelService.childprocess.stdout?.on('data', (data: any) => {
Expand Down
Loading