Add an architecture prefix to the OS

Co-authored-by: Cole Helbling <cole.e.helbling@outlook.com>
This commit is contained in:
Graham Christensen 2023-05-22 15:45:55 -04:00
parent cef074e3b3
commit 3597849148
No known key found for this signature in database
5 changed files with 32 additions and 26 deletions

View file

@ -5,13 +5,16 @@ on:
workflow_call: workflow_call:
jobs: jobs:
build-artifacts-macOS: build-artifacts-X64-macOS:
runs-on: macos-12 runs-on: macos-12
steps: steps:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
- uses: DeterminateSystems/nix-installer-action-cache@main - uses: DeterminateSystems/nix-installer-action-cache@main
- name: Print the arch-os
run: "echo $RUNNER_ARCH-$RUNNER_OS"
- name: Build package - name: Build package
run: "nix build .# -L" run: "nix build .# -L"
@ -19,17 +22,20 @@ jobs:
uses: actions/upload-artifact@v3.1.2 uses: actions/upload-artifact@v3.1.2
with: with:
# Artifact name # Artifact name
name: nix-actions-cache-macOS name: nix-actions-cache-X64-macOS
path: result/bin/nix-actions-cache path: result/bin/nix-actions-cache
retention-days: 1 retention-days: 1
build-artifacts-Linux: build-artifacts-X64-Linux:
runs-on: ubuntu-22.04 runs-on: ubuntu-22.04
steps: steps:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
- uses: DeterminateSystems/nix-installer-action-cache@main - uses: DeterminateSystems/nix-installer-action-cache@main
- name: Print the arch-os
run: "echo $RUNNER_ARCH-$RUNNER_OS"
- name: Build package - name: Build package
run: "nix build .# -L" run: "nix build .# -L"
@ -37,6 +43,6 @@ jobs:
uses: actions/upload-artifact@v3.1.2 uses: actions/upload-artifact@v3.1.2
with: with:
# Artifact name # Artifact name
name: nix-actions-cache-Linux name: nix-actions-cache-X64-Linux
path: result/bin/nix-actions-cache path: result/bin/nix-actions-cache
retention-days: 1 retention-days: 1

View file

@ -35,17 +35,17 @@ jobs:
- uses: actions/download-artifact@v3 - uses: actions/download-artifact@v3
with: with:
name: nix-actions-cache-macOS name: nix-actions-cache-X64-macOS
path: cache-binary-macOS path: cache-binary-X64-macOS
- name: Persist the cache binary - name: Persist the cache binary
run: cp ./cache-binary-macOS/nix-actions-cache ./artifacts/nix-actions-cache-macOS run: cp ./cache-binary-macOS/nix-actions-cache ./artifacts/nix-actions-cache-X64-macOS
- uses: actions/download-artifact@v3 - uses: actions/download-artifact@v3
with: with:
name: nix-actions-cache-Linux name: nix-actions-cache-X64-Linux
path: cache-binary-Linux path: cache-binary-X64-Linux
- name: Persist the cache binary - name: Persist the cache binary
run: cp ./cache-binary-Linux/nix-actions-cache ./artifacts/nix-actions-cache-Linux run: cp ./cache-binary-Linux/nix-actions-cache ./artifacts/nix-actions-cache-X64-Linux
- name: Publish Release (Branch) - name: Publish Release (Branch)
env: env:

View file

@ -39,17 +39,17 @@ jobs:
- uses: actions/download-artifact@v3 - uses: actions/download-artifact@v3
with: with:
name: nix-actions-cache-macOS name: nix-actions-cache-X64-macOS
path: cache-binary-macOS path: cache-binary-X64-macOS
- name: Persist the cache binary - name: Persist the cache binary
run: cp ./cache-binary-macOS/nix-actions-cache ./artifacts/nix-actions-cache-macOS run: cp ./cache-binary-X64-macOS/nix-actions-cache ./artifacts/nix-actions-cache-X64-macOS
- uses: actions/download-artifact@v3 - uses: actions/download-artifact@v3
with: with:
name: nix-actions-cache-Linux name: nix-actions-cache-X64-Linux
path: cache-binary-Linux path: cache-binary-X64-Linux
- name: Persist the cache binary - name: Persist the cache binary
run: cp ./cache-binary-Linux/nix-actions-cache ./artifacts/nix-actions-cache-Linux run: cp ./cache-binary-X64-Linux/nix-actions-cache ./artifacts/nix-actions-cache-X64-Linux
- name: Configure AWS Credentials - name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v2 uses: aws-actions/configure-aws-credentials@v2

View file

@ -26,17 +26,17 @@ jobs:
- uses: actions/download-artifact@v3 - uses: actions/download-artifact@v3
with: with:
name: nix-actions-cache-macOS name: nix-actions-cache-X64-macOS
path: cache-binary-macOS path: cache-binary-X64-macOS
- name: Persist the cache binary - name: Persist the cache binary
run: cp ./cache-binary-macOS/nix-actions-cache ./artifacts/nix-actions-cache-macOS run: cp ./cache-binary-X64-macOS/nix-actions-cache ./artifacts/nix-actions-cache-X64-macOS
- uses: actions/download-artifact@v3 - uses: actions/download-artifact@v3
with: with:
name: nix-actions-cache-Linux name: nix-actions-cache-X64-Linux
path: cache-binary-Linux path: cache-binary-X64-Linux
- name: Persist the cache binary - name: Persist the cache binary
run: cp ./cache-binary-Linux/nix-actions-cache ./artifacts/nix-actions-cache-Linux run: cp ./cache-binary-X64-Linux/nix-actions-cache ./artifacts/nix-actions-cache-X64-Linux
- name: Configure AWS Credentials - name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v2 uses: aws-actions/configure-aws-credentials@v2

View file

@ -73,13 +73,13 @@ This commit's nix-actions-cache binaries can be fetched from:
Intel macOS: Intel macOS:
\`\`\` \`\`\`
curl --output nix-actions-cache --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix-actions-cache/macOS/rev/$GIT_ISH curl --output nix-actions-cache --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix-actions-cache/rev/$GIT_ISH/X64-macOS
\`\`\` \`\`\`
x86_64 Linux: x86_64 Linux:
\`\`\` \`\`\`
curl --output nix-actions-cache --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix-actions-cache/Linux/rev/$GIT_ISH curl --output nix-actions-cache --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix-actions-cache/rev/$GIT_ISH/X64-Linux
\`\`\` \`\`\`
Or generally from this ${TYPE}: Or generally from this ${TYPE}:
@ -87,12 +87,12 @@ Or generally from this ${TYPE}:
Intel macOS: Intel macOS:
\`\`\` \`\`\`
curl --output nix-actions-cache --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix-actions-cache/macOS/${TYPE}/${DEST} curl --output nix-actions-cache --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix-actions-cache/${TYPE}/${DEST}/X64-macOS
\`\`\` \`\`\`
x86_64 Linux: x86_64 Linux:
\`\`\` \`\`\`
curl --output nix-actions-cache --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix-actions-cache/Linux/${TYPE}/${DEST} curl --output nix-actions-cache --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix-actions-cache/${TYPE}/${DEST}/X64-Linux
\`\`\` \`\`\`
EOF EOF