Update build_dyno.yml #37
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: Build and Release Dyno Executables | ||
# ... previous content remains the same until the create-release job | ||
create-release: | ||
needs: [build-windows, build-macos] | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Download all artifacts | ||
uses: actions/download-artifact@v4 | ||
with: | ||
path: dist | ||
- name: Create Release | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
# Get the date and short SHA | ||
DATE=$(date +'%Y-%m-%d') | ||
SHA=$(git rev-parse --short HEAD) # Fixed: SHA -> HEAD | ||
RELEASE_TAG="build-${DATE}-${SHA}" | ||
# Create release notes with Mac instructions | ||
cat > release_notes.md << 'EOL' | ||
Automated build from commit: $(git log -1 --pretty=%B) | ||
## Mac Installation Instructions | ||
1. Download dyno-mac.zip | ||
2. Double-click to extract | ||
3. Open Terminal | ||
4. Navigate to the extracted folder: cd ~/Downloads/dyno-mac | ||
5. Run the program: ./dyno | ||
Note: If you get a security warning, go to System Preferences > Security & Privacy and click "Open Anyway" | ||
EOL | ||
# Create release | ||
gh release create "$RELEASE_TAG" \ | ||
--title "Build ${DATE} (${SHA})" \ | ||
--notes-file release_notes.md \ | ||
dist/windows-build/dyno-windows.exe \ | ||
dist/macos-build/dyno-mac.zip |