chore: cpp framework improvements and additions (#8640) #44
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: InGamePanels Checklist Fix | |
on: | |
push: | |
branches: | |
- master | |
paths: | |
- 'fbw-ingamepanels-checklist-fix/**' | |
- 'scripts/build_ingamepanels_checklist_fix.js' | |
- 'scripts/build_ingamepanels_checklist_fix.sh' | |
- 'igniter.config.mjs' | |
- 'package.json' | |
- 'package-lock.json' | |
jobs: | |
build-ingamepanels-checklist-fix: | |
# Prevent running this on forks | |
if: github.repository_owner == 'flybywiresim' | |
name: 'Build InGamePanels Checklist Fix' | |
runs-on: ubuntu-latest | |
env: | |
FBW_PRODUCTION_BUILD: 1 | |
MASTER_ZIP_NAME: ingamepanels-checklist-fix-master.zip | |
BUILD_DIR_NAME: master | |
steps: | |
- name: Checkout source | |
uses: actions/checkout@v2 | |
- name: Set BUILT_DATE_TIME | |
run: echo "BUILT_DATE_TIME=$(date -u -Iseconds)" >> $GITHUB_ENV | |
- name: Create .env file | |
run: | | |
echo FBW_PRODUCTION_BUILD=1 >> .env | |
echo CLIENT_ID=${{ secrets.NAVIGRAPH_CLIENT_ID }} >> .env | |
echo CLIENT_SECRET=${{ secrets.NAVIGRAPH_CLIENT_SECRET }} >> .env | |
echo CHARTFOX_SECRET=${{ secrets.CHARTFOX_SECRET }} >> .env | |
echo SENTRY_DSN=${{ secrets.SENTRY_DSN }} >> .env | |
echo BUILD_DIR_NAME=${{ env.BUILD_DIR_NAME }} >> .env | |
echo LOCALAZY_READ_KEY=${{ secrets.LOCALAZY_READ_KEY }} >> .env | |
- name: Build In-Game Panels Checklist Fix | |
run: | | |
./scripts/dev-env/run.sh ./scripts/setup.sh --clean | |
./scripts/dev-env/run.sh ./scripts/build_ingamepanels_checklist_fix.sh --no-tty -j 4 | |
- name: Build ZIP files | |
run: | | |
./scripts/dev-env/run.sh node ./scripts/fragment-ingamepanels-checklist-fix.js | |
cp ./fbw-ingamepanels-checklist-fix/out/build-modules/modules.json ./fbw-ingamepanels-checklist-fix/out/flybywire-ingamepanels-checklist-fix/install.json | |
./scripts/dev-env/run.sh node ./scripts/install-source-ingamepanels-checklist-fix.js | |
mkdir ./${{ env.BUILD_DIR_NAME }} | |
cd ./fbw-ingamepanels-checklist-fix/out/ | |
zip -r ../../${{ env.BUILD_DIR_NAME }}/${{ env.MASTER_ZIP_NAME }} ./flybywire-ingamepanels-checklist-fix/ | |
cd ../../ | |
- name: Upload to CloudFlare CDN | |
env: | |
CLOUDFLARE_BUCKET_PASSWORD: ${{ secrets.CLOUDFLARE_BUCKET_PASSWORD }} | |
CDN_BUCKET_DESTINATION: addons/ingamepanels-checklist-fix/master | |
run: | | |
./scripts/cf-cdn.sh $CDN_BUCKET_DESTINATION ./fbw-ingamepanels-checklist-fix/out/build-modules |