Skip to content

Commit

Permalink
Merge pull request #3 from nifty-oss/refactor/batch-mint-instructions
Browse files Browse the repository at this point in the history
use new mint fn from nifty client; pack instructions
  • Loading branch information
samuelvanderwaal authored Apr 18, 2024
2 parents bfe52fc + d5eb535 commit 3e3d226
Show file tree
Hide file tree
Showing 17 changed files with 356 additions and 313 deletions.
44 changes: 44 additions & 0 deletions .github/actions/install-solana/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Install Solana

inputs:
version:
description: The Solana version to install
required: true
default: "stable"
cache:
description: Whether the downloaded Solana release should be cached
required: true
default: "true"

runs:
using: "composite"
steps:
- name: Cache Solana
id: cache
if: inputs.cache == 'true'
uses: buildjet/cache@v4
with:
path: ~/.local/share/solana/install/releases/${{ inputs.version }}
key: ${{ runner.os }}-${{ runner.arch }}-solana-v${{ inputs.version }}

- name: Install Solana
if: inputs.cache != 'true' || steps.cache.outputs.cache-hit != 'true'
run: |
sh -c "$(curl -sSfL https://release.solana.com/v${{ inputs.version }}/install)"
shell: bash

- name: Set Active Solana Version
run: |
rm -f "$HOME/.local/share/solana/install/active_release"
ln -s "$HOME/.local/share/solana/install/releases/${{ inputs.version }}/solana-release" "$HOME/.local/share/solana/install/active_release"
shell: bash

- name: Add Solana bin to Path
run: |
echo "$HOME/.local/share/solana/install/active_release/bin" >> $GITHUB_PATH
shell: bash

- name: Verify Solana install
run: |
solana --version
shell: bash
4 changes: 2 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
matrix:
os:
- buildjet-8vcpu-ubuntu-2004
- macos-latest
- macos-13
- macos-14
runs-on: ${{ matrix.os }}
steps:
Expand All @@ -46,7 +46,7 @@ jobs:
toolchain: ${{ inputs.rust || env.RUST_VERSION }}

- name: Install Solana
uses: nifty-oss/actions/install-solana@v1
uses: ./.github/actions/install-solana
with:
version: ${{ inputs.solana || env.SOLANA_VERSION }}
cache: ${{ env.CACHE }}
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
.vscode
/target
Loading

0 comments on commit 3e3d226

Please sign in to comment.