Skip to content

Commit

Permalink
Create deploy_by_tag.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
woin2ee authored Feb 5, 2025
1 parent 934ede3 commit dcb7494
Showing 1 changed file with 36 additions and 0 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/deploy_by_tag.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Deploy by tag

on:
push:
tags:
- '*.*.*'

jobs:
deploy_web_by_tag:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/[email protected]
with:
ref: ${{ github.ref_name }}
- name: Build for web release
env:
BASE_HREF: "/DST-Helper-web/"
run: flutter build web --base-href "${BASE_HREF}"
- name: Move to build dir for web
run: cd build/web
# - name: Commit the result of build
# env:
# COMMIT_MESSAGE: "Deploy ${{ github.ref_name }}"
# run: git add . && git commit -m "${COMMIT_MESSAGE}"
- name: Push directory to another repository
uses: cpina/[email protected]
env:
SSH_DEPLOY_KEY: ${{ secrets.SSH_DEPLOY_KEY }}
with:
source-directory: 'build/web'
destination-github-username: 'woin2ee'
destination-repository-name: 'DST-Helper-web'
user-email: [email protected]
target-branch: main
commit-message: "Deploy ${{ github.ref_name }}"

0 comments on commit dcb7494

Please sign in to comment.