Skip to content

Commit

Permalink
Merge pull request #556 from Artsdatabanken/upgrade/deps
Browse files Browse the repository at this point in the history
Upgrade/deps
  • Loading branch information
bjornreppen authored Dec 15, 2023
2 parents e571a4c + c26eb18 commit 4bef625
Show file tree
Hide file tree
Showing 21 changed files with 18,358 additions and 73 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/build-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: build and test PR

on:
pull_request:
branches:
- '*'
jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Use Node.js
uses: actions/setup-node@v3
- run: npm install
- run: npm run build
- run: cd wms-assistent
- run: npm install
- run: npm run build
- run: cd ..
3 changes: 3 additions & 0 deletions .github/workflows/deploy.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
mkdir build/static
cp -R wms-assitent/build/ build/static/
tar czf $(basename $GITHUB_REPOSITORY).tar.gz -C build .
38 changes: 38 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: build and publish

on:
push:
branches: [master]

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Use Node.js
uses: actions/setup-node@v3
- run: npm install
- run: npm run build
- run: cd wms-assistent
- run: npm install
- run: npm run build
- run: cd ..
- name: Check downloaded files
run: ./.github/workflows/filecheck.sh
- name: Checkout
uses: actions/checkout@v3
with:
path: "./destinationRepo"
token: ${{secrets.PUSH_TOKEN}}
- name: Run deployment script
run: ./.github/workflows/deploy.sh
shell: bash
- name: Create release
uses: ncipollo/release-action@v1
with:
artifacts: ${{ github.event.repository.name }}.tar.gz
tag: v_${{ github.run_number }}
- name: post to slack
run: ./.github/workflows/slack.sh ${{ secrets.POST_SLACK }}
shell: bash
2 changes: 2 additions & 0 deletions .github/workflows/filecheck.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
ls -l temp
ls -l build
1 change: 1 addition & 0 deletions .github/workflows/slack.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
curl -X POST -H 'Content-type: application/json' --data '{"text":"deploy forvaltningsportal"}' $1
2 changes: 1 addition & 1 deletion src/Kart/Leaflet.js
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ class Leaflet extends React.Component {
} else {
favoritesUrlString = "&favorites=" + favoritesUrlString;
}
this.props.history.push(
this.props.navigate(
"?lng=" + lng + "&lat=" + lat + layersUrlString + favoritesUrlString
);
this.props.handleUpdateChangeInUrl(true);
Expand Down
Loading

0 comments on commit 4bef625

Please sign in to comment.