forked from fujiwara/lambroll
-
Notifications
You must be signed in to change notification settings - Fork 0
/
action.yml
31 lines (29 loc) · 968 Bytes
/
action.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
inputs:
version:
description: "A version to install lambroll"
default: "v1.0.5"
runs:
using: "composite"
steps:
- name: Set file name
id: set-filename
run: |
case "${{ runner.os }}" in
Linux) BIN_OS="linux" ;;
macOS) BIN_OS="darwin" ;;
*) BIN_OS="linux" ;;
esac
case "${{ runner.arch }}" in
X64) BIN_ARCH="amd64" ;;
ARM64) BIN_ARCH="arm64" ;;
*) BIN_ARCH="amd64" ;;
esac
FILENAME=lambroll_${{ inputs.version }}_${BIN_OS}_${BIN_ARCH}.tar.gz
echo "FILENAME=$FILENAME" >> $GITHUB_OUTPUT
shell: bash
- run: |
mkdir -p /tmp/lambroll-${{ inputs.version }}
cd /tmp/lambroll-${{ inputs.version }}
curl -sL https://github.com/fujiwara/lambroll/releases/download/${{ inputs.version }}/${{ steps.set-filename.outputs.FILENAME }} | tar zxvf -
sudo install lambroll /usr/local/bin
shell: bash