From 2ec7c77cdf1f2e8ae650ec339d5c2df0e335b00b Mon Sep 17 00:00:00 2001 From: Oscar Date: Tue, 12 Dec 2023 10:57:46 +0100 Subject: [PATCH 1/2] chore: remove url --- .github/workflows/deploy_app_staging.yaml | 2 +- lib/main_production.dart | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/deploy_app_staging.yaml b/.github/workflows/deploy_app_staging.yaml index 230e6b0..895e455 100644 --- a/.github/workflows/deploy_app_staging.yaml +++ b/.github/workflows/deploy_app_staging.yaml @@ -14,7 +14,7 @@ jobs: flutter-version: "3.16.2" channel: "stable" - run: flutter packages get - - run: flutter build web -t lib/main_production.dart --dart-define SHARING_ENABLED=true --dart-define="AI_API_URL=${{ secrets.AI_API_URL }}" + - run: flutter build web -t lib/main_production.dart - uses: FirebaseExtended/action-hosting-deploy@v0 with: repoToken: "${{ secrets.GITHUB_TOKEN }}" diff --git a/lib/main_production.dart b/lib/main_production.dart index ca78926..7016e31 100644 --- a/lib/main_production.dart +++ b/lib/main_production.dart @@ -8,8 +8,7 @@ void main() async { await bootstrap( () async { final apiClient = ApiClient( - realApiEnabled: true, - baseUrl: const String.fromEnvironment('AI_API_URL'), + baseUrl: 'http://production', ); final questionsRepository = From 897dacc4b14d993b2b404b9935d5367a43b5ea70 Mon Sep 17 00:00:00 2001 From: Oscar Date: Tue, 12 Dec 2023 11:01:44 +0100 Subject: [PATCH 2/2] chore: fix --- .github/workflows/deploy_app_staging.yaml | 6 +++--- .idea/runConfigurations/production.xml | 7 ------- lib/{main_production.dart => main_staging.dart} | 2 +- 3 files changed, 4 insertions(+), 11 deletions(-) delete mode 100644 .idea/runConfigurations/production.xml rename lib/{main_production.dart => main_staging.dart} (94%) diff --git a/.github/workflows/deploy_app_staging.yaml b/.github/workflows/deploy_app_staging.yaml index 895e455..d710b74 100644 --- a/.github/workflows/deploy_app_staging.yaml +++ b/.github/workflows/deploy_app_staging.yaml @@ -1,4 +1,4 @@ -name: deploy_app_production +name: deploy_app_staging on: workflow_dispatch: @@ -6,7 +6,7 @@ on: jobs: deploy-dev: runs-on: ubuntu-latest - name: Deploy App Production + name: Deploy App Staging steps: - uses: actions/checkout@v4 - uses: subosito/flutter-action@v2 @@ -14,7 +14,7 @@ jobs: flutter-version: "3.16.2" channel: "stable" - run: flutter packages get - - run: flutter build web -t lib/main_production.dart + - run: flutter build web -t lib/main_staging.dart - uses: FirebaseExtended/action-hosting-deploy@v0 with: repoToken: "${{ secrets.GITHUB_TOKEN }}" diff --git a/.idea/runConfigurations/production.xml b/.idea/runConfigurations/production.xml deleted file mode 100644 index 1c5c774..0000000 --- a/.idea/runConfigurations/production.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - - diff --git a/lib/main_production.dart b/lib/main_staging.dart similarity index 94% rename from lib/main_production.dart rename to lib/main_staging.dart index 7016e31..91806ff 100644 --- a/lib/main_production.dart +++ b/lib/main_staging.dart @@ -8,7 +8,7 @@ void main() async { await bootstrap( () async { final apiClient = ApiClient( - baseUrl: 'http://production', + baseUrl: 'http://staging', ); final questionsRepository =