diff --git a/.github/workflows/gulp-build.yml b/.github/workflows/gulp-build.yml index 601a84b..f4b330b 100644 --- a/.github/workflows/gulp-build.yml +++ b/.github/workflows/gulp-build.yml @@ -68,54 +68,54 @@ jobs: branch: ${{ (github.base_ref || github.ref) }} github_token: ${{ secrets.GITHUB_TOKEN }} - # Job name - rclone-dev: - # Run after build - needs: build - - # Runner name - runs-on: ubuntu-latest - if: ${{ (github.event.release.target_commitish || github.ref_name) == 'dev' }} - - steps: - # Checkout to the branch to use the last (build) commit - - uses: actions/checkout@v2 - with: - ref: ${{ (github.event.release.target_commitish || github.ref_name) }} - - # rclone - - name: Copy files on dev - uses: wei/rclone@v1 - env: - RCLONE_CONFIG_HDX_TYPE: ${{ secrets.RCLONE_CONFIG_HDX_TYPE }} - RCLONE_CONFIG_HDX_HOST: ${{ secrets.RCLONE_CONFIG_HDX_HOST }} - RCLONE_CONFIG_HDX_USER: ${{ secrets.RCLONE_CONFIG_HDX_USER_DEV }} - RCLONE_CONFIG_HDX_PASS: ${{ secrets.RCLONE_CONFIG_HDX_PASS_DEV }} - with: - args: copy build HDX:${{ env.dest_path }} - - # Job name - rclone-prod: - # Run after build - needs: build - - # Runner name - runs-on: ubuntu-latest - if: ${{ (github.event.release.target_commitish || github.ref_name) == 'prod' }} - - steps: - # Checkout to the branch to use the last (build) commit - - uses: actions/checkout@v2 - with: - ref: ${{ (github.event.release.target_commitish || github.ref_name) }} - - # rclone - - name: Copy files on prod - uses: wei/rclone@v1 - env: - RCLONE_CONFIG_HDX_TYPE: ${{ secrets.RCLONE_CONFIG_HDX_TYPE }} - RCLONE_CONFIG_HDX_HOST: ${{ secrets.RCLONE_CONFIG_HDX_HOST }} - RCLONE_CONFIG_HDX_USER: ${{ secrets.RCLONE_CONFIG_HDX_USER_PROD }} - RCLONE_CONFIG_HDX_PASS: ${{ secrets.RCLONE_CONFIG_HDX_PASS_PROD }} - with: - args: copy build HDX:${{ env.dest_path }} +# # Job name +# rclone-dev: +# # Run after build +# needs: build +# +# # Runner name +# runs-on: ubuntu-latest +# if: ${{ (github.event.release.target_commitish || github.ref_name) == 'dev' }} +# +# steps: +# # Checkout to the branch to use the last (build) commit +# - uses: actions/checkout@v2 +# with: +# ref: ${{ (github.event.release.target_commitish || github.ref_name) }} +# +# # rclone +# - name: Copy files on dev +# uses: wei/rclone@v1 +# env: +# RCLONE_CONFIG_HDX_TYPE: ${{ secrets.RCLONE_CONFIG_HDX_TYPE }} +# RCLONE_CONFIG_HDX_HOST: ${{ secrets.RCLONE_CONFIG_HDX_HOST }} +# RCLONE_CONFIG_HDX_USER: ${{ secrets.RCLONE_CONFIG_HDX_USER_DEV }} +# RCLONE_CONFIG_HDX_PASS: ${{ secrets.RCLONE_CONFIG_HDX_PASS_DEV }} +# with: +# args: copy build HDX:${{ env.dest_path }} +# +# # Job name +# rclone-prod: +# # Run after build +# needs: build +# +# # Runner name +# runs-on: ubuntu-latest +# if: ${{ (github.event.release.target_commitish || github.ref_name) == 'prod' }} +# +# steps: +# # Checkout to the branch to use the last (build) commit +# - uses: actions/checkout@v2 +# with: +# ref: ${{ (github.event.release.target_commitish || github.ref_name) }} +# +# # rclone +# - name: Copy files on prod +# uses: wei/rclone@v1 +# env: +# RCLONE_CONFIG_HDX_TYPE: ${{ secrets.RCLONE_CONFIG_HDX_TYPE }} +# RCLONE_CONFIG_HDX_HOST: ${{ secrets.RCLONE_CONFIG_HDX_HOST }} +# RCLONE_CONFIG_HDX_USER: ${{ secrets.RCLONE_CONFIG_HDX_USER_PROD }} +# RCLONE_CONFIG_HDX_PASS: ${{ secrets.RCLONE_CONFIG_HDX_PASS_PROD }} +# with: +# args: copy build HDX:${{ env.dest_path }} diff --git a/build/header.php b/build/header.php index 75e1885..6a1dba0 100644 --- a/build/header.php +++ b/build/header.php @@ -42,25 +42,30 @@ - + // Get the current hostname + var hostname = window.location.hostname; + var mixpanelToken; + + // Check the hostname and set the Mixpanel token + if (hostname === 'centre.humdata.org') { + mixpanelToken = '5cbf12bc9984628fb2c55a49daf32e74'; + } else if (hostname === 'dev-centre.humdata.org') { + mixpanelToken = '99035923ee0a67880e6c05ab92b6cbc0'; + } else { + mixpanelToken = '875bfe50f9cb981f4e2817832c83c165'; + } - if(!empty(get_option($mixpanelToken))) : ?> - - - - + + + See all