Skip to content

Commit

Permalink
Merge pull request #13 from holochain/add-template
Browse files Browse the repository at this point in the history
Add template
  • Loading branch information
ThetaSinner authored Jun 5, 2024
2 parents 16a5629 + f537b3e commit f5580b8
Show file tree
Hide file tree
Showing 4 changed files with 276 additions and 211 deletions.
30 changes: 25 additions & 5 deletions .github/workflows/build-and-cache.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,16 +28,23 @@ jobs:
build:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, macos-13]
os: [ ubuntu-latest, macos-latest, macos-13 ]
packages:
- [holochain, hc, hc-run-local-services, hc-sandbox, hcterm]
- [lair-keystore]
- [hc-launch]
- [hc-scaffold]
- [ holochain, hc, hc-run-local-services, hc-sandbox, hcterm ]
- [ lair-keystore ]
- [ hc-launch ]
- [ hc-scaffold ]
include:
- os: ubuntu-latest
template: holonix-default
fail-fast: false

runs-on: ${{ matrix.os }}

permissions:
contents: read
id-token: write

steps:
- name: Print platform information
run: uname -ms
Expand All @@ -57,6 +64,19 @@ jobs:
run: |
echo '${{ toJSON(matrix.packages) }}' | jq -r '.[]' | xargs -I% nix run .#% -- --version
- name: Extract branch name
shell: bash
run: echo "branch=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}" >> $GITHUB_OUTPUT
id: extract_branch

- name: Init from template
if: ${{ matrix.os == 'ubuntu-latest' }}
run: |
cd $(mktemp -d)
echo "Fetching template from branch ${{ steps.extract_branch.outputs.branch }}"
nix flake init -t "github:holochain/holonix/${{ steps.extract_branch.outputs.branch }}#${{ matrix.template }}"
nix develop -c holochain --version
# - name: Setup tmate session
# if: failure()
# uses: mxschmitt/action-tmate@v3
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
result

templates/*/flake.lock
Loading

0 comments on commit f5580b8

Please sign in to comment.