Update text color for private notes to improve visibility and consist… #180
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: Deploy HappyNotes Web | |
on: | |
workflow_dispatch: | |
push: | |
branches: | |
- master | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Flutter | |
uses: subosito/flutter-action@v2 | |
with: | |
flutter-version: '3.24.x' | |
channel: 'stable' | |
- name: Fetch Git Commit Hash | |
id: get_commit | |
run: | | |
echo "::set-output name=commit_hash::$(git rev-parse --short HEAD)" | |
echo "::set-output name=build_date::$(date '+%Y-%b-%d')" | |
- name: Build web | |
run: | | |
cp .env.production .env | |
COMMIT_HASH=${{ steps.get_commit.outputs.commit_hash }} | |
BUILD_DATE=${{ steps.get_commit.outputs.build_date }} | |
VERSION_INFO="$COMMIT_HASH ($BUILD_DATE)" | |
sed -i "s/VERSION_PLACEHOLDER/$VERSION_INFO/" .env | |
flutter config --enable-web | |
flutter build web --release --base-href "/" --web-renderer html | |
- name: Create CNAME file | |
run: echo 'happynotes.shukebeta.com' > ./build/web/CNAME | |
- name: Deploy to GitHub Pages | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.RELEASE_TOKEN }} | |
publish_dir: ./build/web |