Skip to content

Commit

Permalink
Fix breaking changes since v0.17.0. (#10)
Browse files Browse the repository at this point in the history
* Add cron to check latest version biweekly.

* Change update install script location.

* Add DFXVM_INIT_YES flag.

* Use different paths after v0.17.0.

* Update bin locations.

* Add PATH to logs.

* Fix macos path.

* Escape spaces in macos bin path.

* Update README.

* Update action input descriptions.
  • Loading branch information
q-uint authored Mar 17, 2024
1 parent c2af325 commit 0762cc7
Show file tree
Hide file tree
Showing 9 changed files with 24,851 additions and 1,062 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/cron.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
on:
schedule:
- cron: '30 1 1,15 * *' # Run at 01:30 on the 1st and 15th day of the month.
jobs:
test_schedule:
strategy:
matrix:
os: [ ubuntu-latest, macos-latest ]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- run: |
latest=$(curl -s 'https://raw.githubusercontent.com/dfinity/sdk/master/public/manifest.json' | jq -r '.tags.latest')
echo "LATEST=$latest" >> "$GITHUB_ENV"
- uses: ./
with:
dfx-version: ${{ env.LATEST }}
install-moc: true
vessel-version: 0.7.0
- run: |
dfx --version
moc --version
vessel --version
7 changes: 4 additions & 3 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,15 @@ jobs:
strategy:
matrix:
os: [ ubuntu-latest, macos-latest ]
version: [ 0.16.0, 0.18.0 ]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: ./
with:
dfx-version: 0.14.2
dfx-version: ${{ matrix.version }}
install-moc: true
vessel-version: 0.6.5
vessel-version: 0.7.0
- run: |
dfx --version
moc --version
Expand Down
16 changes: 6 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ This action sets up a `dfx` environment, also includes `moc` and `vessel`.
```yml
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: aviate-labs/setup-dfx@v0.2.6
- uses: actions/checkout@v4
- uses: aviate-labs/setup-dfx@v0.3.0
with:
vessel-version: 0.6.5
vessel-version: 0.7.0
- run: for i in src/*.mo ; do $(vessel bin)/moc $(vessel sources) --check $i ; done
```
Expand All @@ -21,21 +21,17 @@ steps:
```yml
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: aviate-labs/setup-dfx@v0.2.6
- uses: actions/checkout@v4
- uses: aviate-labs/setup-dfx@v0.3.0
with:
dfx-version: 0.14.2
dfx-version: 0.18.0
env:
DFX_IDENTITY_PEM: ${{ secrets.DFX_IDENTITY_PEM }}
- run: |
dfx identity use action
dfx deploy --network ic --no-wallet
```
## Possible Improvements
- Make use of the [manifest.json](https://raw.githubusercontent.com/dfinity/sdk/public-manifest/manifest.json) to check versions.
## License
The scripts and documentation in this project are released under the [MIT License](./LICENSE).
10 changes: 5 additions & 5 deletions action.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
name: 'Setup dfx environment'
name: 'Setup DFX environment'
author: 'Quint Daenen'
description: 'Setup a dfx environment and add it to the PATH.'
inputs:
dfx-version:
description: 'The dfx version to download.'
description: 'The dfx version to download. If empty DFX will not be installed. You can also use "latest" to get the latest version.'
dfx-disable-encryption:
description: 'Wether to use the .pem encryption'
description: 'Whether to use the .pem encryption.'
default: "false"
install-moc:
description: 'Whether to install moc through dfx.'
default: "false"
vessel-version:
description: 'The vessel version to download.'
description: 'The vessel version to download. If empty vessel will not be installed.'
runs:
using: 'node16'
using: 'node20'
main: 'dist/index.js'
branding:
icon: 'box'
Expand Down
Loading

0 comments on commit 0762cc7

Please sign in to comment.