-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2772 from cal-itp/more-speedmap-tweaks
more speedmap tweaks (follow-ups from pairing session)
- Loading branch information
Showing
8 changed files
with
134 additions
and
29 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,59 @@ | ||
name: Build and publish apps/maps | ||
|
||
on: | ||
push: | ||
paths: | ||
- 'apps/maps/**' | ||
pull_request: | ||
paths: | ||
- 'apps/maps/**' | ||
workflow_dispatch: | ||
|
||
jobs: | ||
build-apps-maps: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
- uses: actions/setup-python@v1 | ||
- uses: actions/setup-node@v3 | ||
- run: | | ||
npm install | ||
npm run build | ||
working-directory: apps/maps | ||
# Production | ||
- name: Deploy apps/maps production to Netlify | ||
if: ${{ github.ref == 'refs/heads/main' }} | ||
run: | | ||
npm install -g netlify-cli | ||
netlify deploy --site=embeddable-maps-calitp-org --dir=apps/maps/build --prod | ||
env: | ||
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }} | ||
|
||
# Preview on PRs | ||
- name: Deploy apps/maps preview to Netlify | ||
if: ${{ github.ref != 'refs/heads/main' }} | ||
run: | | ||
npm install -g netlify-cli | ||
netlify deploy --site=embeddable-maps-calitp-org --dir=apps/maps/build --alias=${GITHUB_REPOSITORY#*/}-${PR_NUMBER} | ||
env: | ||
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }} | ||
PR_NUMBER: ${{ github.event.number }} | ||
|
||
- uses: peter-evans/find-comment@v2 | ||
if: ${{ github.event_name == 'pull_request' }} | ||
id: fc | ||
with: | ||
issue-number: ${{ github.event.number }} | ||
comment-author: 'github-actions[bot]' | ||
body-includes: --embeddable-maps-calitp-org.netlify.app | ||
|
||
- uses: peter-evans/create-or-update-comment@v2 | ||
if: ${{ github.event_name == 'pull_request' }} | ||
with: | ||
comment-id: ${{ steps.fc.outputs.comment-id }} | ||
issue-number: ${{ github.event.number }} | ||
body: "Preview url: https://${{github.event.repository.name}}-${{ github.event.number }}--embeddable-maps-calitp-org.netlify.app" | ||
edit-mode: replace |
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
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 |
---|---|---|
|
@@ -143,3 +143,6 @@ dmypy.json | |
|
||
#.DS_Store files that Macs create | ||
.DS_Store | ||
|
||
# Local Netlify folder | ||
.netlify |
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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
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
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