generated from asdf-vm/asdf-plugin-template
-
Notifications
You must be signed in to change notification settings - Fork 4
55 lines (54 loc) · 2.13 KB
/
build.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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
name: Build
on:
pull_request:
paths-ignore:
- "**.md"
push:
branches:
- master
paths-ignore:
- "**.md"
jobs:
plugin_test:
name: asdf plugin test
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: asdf_plugin_test
uses: asdf-vm/actions/plugin-test@v2
with:
command: op --version
- name: Checkout code
uses: actions/checkout@v4
with:
path: 1password-cli
- name: Move 1password-cli plugin to plugins dir
run: |
mkdir -p ${HOME}/.asdf/plugins/
mv 1password-cli ${HOME}/.asdf/plugins/
- name: Run 1password-cli specific tests
run: |
echo "Trying to list all versions of 1password-cli"
asdf list all 1password-cli
echo "Will try to install 1password-cli 1.11.0 (Last version with amd64 for macOS)"
asdf install 1password-cli 1.11.0
echo "Will try to install 1password-cli 1.11.1 (First version with universal for macOS)"
asdf install 1password-cli 1.11.1
echo "Will try to install 1password-cli 2.0.0 (First 2.0 version)"
asdf install 1password-cli 2.0.0
echo "Will try to install 1password-cli 2.2.0 (First version with zip and pkg versions for macOS)"
asdf install 1password-cli 2.2.0
echo "Setting 1password-cli version 1.11.0 as the default value in ~/.tool-versions"
echo '1password-cli 1.11.0' > ~/.tool-versions
op --version 2>&1 | grep '1.11.0'
echo "Setting 1password-cli version 1.11.1 as the default value in ~/.tool-versions"
echo '1password-cli 1.11.1' > ~/.tool-versions
op --version 2>&1 | grep '1.11.1'
echo "Setting 1password-cli version 2.0.0 as the default value in ~/.tool-versions"
echo '1password-cli 2.0.0' > ~/.tool-versions
op --version 2>&1 | grep '2.0.0'
echo "Setting 1password-cli version 2.2.0 as the default value in ~/.tool-versions"
echo '1password-cli 2.2.0' > ~/.tool-versions
op --version 2>&1 | grep '2.2.0'