-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
990e875
commit 3e1ed9f
Showing
3 changed files
with
91 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
name: Deploy Flutter App on AppCenter | ||
on: | ||
push: | ||
branches: | ||
- main | ||
- 'releases/**' | ||
jobs: | ||
setup-flutter: | ||
name: Setup Flutter | ||
runs-on: self-hosted | ||
steps: | ||
- run: echo "π Triggered by a ${{ github.event_name }} on ${{ github.ref }}" | ||
- name: Check out repository code | ||
uses: actions/checkout@v3 | ||
- name: Install jq | ||
uses: dcarbone/install-jq-action@v2.0.2 | ||
- uses: subosito/flutter-action@v2 | ||
with: | ||
channel: master | ||
architecture: x64 | ||
- run: flutter pub get | ||
setup-appcenter-cli: # must have node and npm installed! | ||
name: Setup AppCenter CLI | ||
runs-on: self-hosted | ||
steps: | ||
- name: Install appcenter-cli | ||
uses: charliealbright/appcenter-cli-action@v1.0.1 | ||
with: | ||
token: '${{secrets.APPCENTER_API_TOKEN}}' | ||
command: 'appcenter help' | ||
# deploy_iOS: | ||
# name: Deploy iOS | ||
# needs: [setup-flutter, setup-appcenter-cli] | ||
# uses: ./.github/workflows/deploy_ios.yml | ||
deploy_android: | ||
name: Deploy Android | ||
needs: [ setup-flutter, setup-appcenter-cli ] | ||
uses: ./.github/workflows/deploy_android.yml | ||
secrets: inherit | ||
with: | ||
file: './build/app/outputs/apk/release/app-release.apk' | ||
name: 'AlvaroBarrosC/GithubAction-Android' |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
name: Deploy Android App on AppCenter | ||
on: | ||
workflow_call: | ||
inputs: | ||
file: | ||
description: 'The path to the file to be released' | ||
required: true | ||
type: string | ||
name: | ||
description: 'The name of the app' | ||
required: true | ||
type: string | ||
group: | ||
description: 'The group that will have access to the version released' | ||
required: false | ||
type: string | ||
default: '"Collaborators"' | ||
jobs: | ||
build: | ||
name: Build .apk file | ||
runs-on: self-hosted | ||
steps: | ||
- run: flutter build apk --release --verbose | ||
Deploy: | ||
name: Deploy file to AppCenter | ||
needs: [ build ] | ||
runs-on: self-hosted | ||
steps: | ||
- name: AppCenter CLI Action | ||
uses: charliealbright/appcenter-cli-action@v1.0.1 | ||
with: | ||
token: ${{secrets.APPCENTER_API_TOKEN}} | ||
command: 'appcenter distribute release -f ${{inputs.file}} --app ${{inputs.name}} --group ${{inputs.group}}' |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
name: Deploy iOS App on AppCenter | ||
on: workflow_call | ||
jobs: | ||
Build: | ||
runs-on: self-hosted | ||
steps: | ||
- run: flutter build ipa --release --verbose --no-codesign | ||
# Deploy: | ||
# needs: Build | ||
# runs-on: self-hosted | ||
# steps: | ||
# - name: AppCenter CLI Action | ||
# uses: charliealbright/appcenter-cli-action@v1.0.1 | ||
# with: | ||
# token: '${{secrets.APPCENTER_API_TOKEN}}' | ||
# command: 'appcenter apps show' |