diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml new file mode 100644 index 0000000..c407ee9 --- /dev/null +++ b/.gitea/workflows/deploy.yml @@ -0,0 +1,38 @@ +name: Deploy to Cloudflare Pages +on: + push: + branches: + - main # O il nome del tuo branch principale + +jobs: + build-and-deploy: + runs-on: ubuntu-latest # O il runner configurato sul tuo Gitea + steps: + - name: Checkout del codice + uses: actions/checkout@v4 + + - name: Setup Flutter + uses: subosito/flutter-action@v2 + with: + channel: 'stable' + + - name: Crea il file .env per flutter_dotenv + run: | + echo "SUPABASE_URL=${{ secrets.SUPABASE_URL }}" >> .env + echo "SUPABASE_ANON_KEY=${{ secrets.SUPABASE_ANON_KEY }}" >> .env + + - name: Ottieni le dipendenze + run: flutter pub get + + - name: Compila per il Web + run: flutter build web --release + + - name: Crea file _redirects per Cloudflare + run: echo "/* /index.html 200" > build/web/_redirects + + - name: Deploy su Cloudflare Pages + env: + CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} + CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }} + # QUESTA È LA RIGA MAGICA: Gli diciamo di prendere SOLO la cartella build/web + run: npx wrangler@latest pages deploy build/web --project-name Flux --branch main \ No newline at end of file diff --git a/android/app/src/main/AndroidManifest.xml b/android/app/src/main/AndroidManifest.xml index b24b47c..2ffc11b 100644 --- a/android/app/src/main/AndroidManifest.xml +++ b/android/app/src/main/AndroidManifest.xml @@ -24,11 +24,11 @@ - + - +