-
Notifications
You must be signed in to change notification settings - Fork 323
190 lines (186 loc) · 6.3 KB
/
test-plugins.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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
name: test-plugins
# Test Top 50 asdf plugins install correctly and the most common can print their
# current version
on:
push:
tags: ["v*"]
branches: ["test-plugins"]
schedule:
# run at midnight on sunday (utc?)
- cron: 0 0 * * 0
# pull_request:
# branches: ["main"]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
env:
CARGO_TERM_COLOR: always
jobs:
build-linux:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: Rust Cache
uses: Swatinem/rust-cache@v2
with:
shared-key: "build-linux-x86_64-unknown-linux-gnu"
save-if: false
- run: scripts/build-tarball.sh mise --release --target x86_64-unknown-linux-gnu
- uses: actions/upload-artifact@v4
with:
name: tarball-x86_64-unknown-linux-gnu
path: |
dist/*.tar.xz
dist/*.tar.gz
if-no-files-found: error
test-install-and-run:
runs-on: ubuntu-22.04
needs: [build-linux]
env:
GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }}
strategy:
fail-fast: false
matrix:
include:
- plugin: node
command: mise exec node@latest -- node -v
- plugin: ruby
command: mise exec ruby@latest -- ruby --version
- plugin: python
command: mise exec python@latest -- python -V
- plugin: direnv
command: mise exec direnv@latest -- direnv --version
- plugin: erlang
command: mise exec [email protected] -- erl -eval 'erlang:display(erlang:system_info(otp_release)), halt().' -noshell
- plugin: elixir
command: |
mise use --global [email protected]
eval "$(mise env bash)"
mise use --global elixir@main-otp-24
eval "$(mise env bash)"
mise exec -- elixir --version
- plugin: golang
command: mise exec golang@latest -- go version
- plugin: java
command: mise exec java@openjdk -- java -version
- plugin: terraform
command: mise exec terraform@latest -- terraform -v
# - plugin: yarn
# command: mise exec yarn@latest -- yarn --version
- plugin: deno
command: mise exec deno@latest -- deno --version
- plugin: bun
command: mise exec bun@latest -- bun --version
- plugin: kubectl
command: mise exec kubectl@latest -- kubectl version --client
- plugin: dotnet
command: mise exec dotnet@latest -- dotnet --list-sdks
- plugin: flutter
command: mise exec flutter@latest -- flutter --version
- plugin: crystal
command: mise exec crystal@latest -- crystal -v
- plugin: neovim
command: mise exec neovim@latest -- nvim --version
- plugin: php
command: mise exec php@latest -- php -v php
- plugin: rust
command: mise exec rust@nightly -- rustc -V
- plugin: postgres
command: mise exec postgres@latest -- psql -V
steps:
- name: apt-get
run: sudo apt-get update; sudo apt-get install zsh fish direnv re2c libcurl4-openssl-dev libgd-dev libonig-dev autoconf bison build-essential curl gettext git libgd-dev libcurl4-openssl-dev libedit-dev libicu-dev libjpeg-dev libmysqlclient-dev libonig-dev libpng-dev libpq-dev libreadline-dev libsqlite3-dev libssl-dev libxml2-dev libzip-dev openssl pkg-config re2c zlib1g-dev libwxgtk-webview3.0-gtk3-dev
- uses: actions/download-artifact@v4
with:
name: tarball-x86_64-unknown-linux-gnu
path: dist
# dist/mise-v1.16.0-linux-x64.tar.xz
# x86_64-unknown-linux-gnu-v1.16.0-linux-x64.tar.xz
- run: tar -C "$HOME" -xvJf dist/mise-*-linux-x64.tar.xz
- run: echo "$HOME/mise/bin" >> "$GITHUB_PATH"
- run: mise -v
- name: ${{matrix.command}}
uses: nick-fields/retry@v2
with:
timeout_minutes: 20
max_attempts: 3
retry_wait_seconds: 30
command: ${{matrix.command}}
env:
MISE_EXPERIMENTAL: "1"
test-install:
# Tests installing the top 50 plugins not already tested in `test-install-and-run`.
# installing is a better-than-nothing smoke test that the plugin is correctly implemented
# and behaves as expected with mise.
runs-on: ubuntu-22.04
needs: [build-linux]
env:
GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }}
strategy:
fail-fast: false
matrix:
plugins:
- waypoint
- vault
- tfc-agent
- terraform-ls
- serf
- sentinel
- packer
- nomad
- levant
- consul
- boundary
- postgres
- rust
- action-validator
- dotnet-core
- neovim
- poetry
# TODO: - haskell not working due to already existing on image
- link
- lua
- redis
- gcloud
- helm
- gleam
- awscli
- dart
- conan
# TODO: - awsebcli fails in asdf and mise the same way
- aws-sam-cli
- ansible-base
- kotlin
- pnpm
- ocaml
# TODO: - rebar install erlang first
# TODO: - julia seems to have quit working, likely an issue with the plugin
- elm
# TODO: - R install libcurl
- nim
- alias
- mysql
- minikube
- gradle
- zig
- shellcheck
- scala
- maven
- kustomize
- graalvm
- sbcl
steps:
- name: Install zsh/fish/direnv
run: sudo apt-get update; sudo apt-get install zsh fish direnv
- uses: actions/download-artifact@v4
with:
name: tarball-x86_64-unknown-linux-gnu
path: dist
- run: tar -C "$HOME" -xvJf dist/mise-*-linux-x64.tar.xz
- run: echo "$HOME/mise/bin" >> "$GITHUB_PATH"
- name: mise install ${{matrix.plugins}}@latest
uses: nick-fields/retry@v2
with:
timeout_minutes: 20
max_attempts: 3
retry_wait_seconds: 30
command: mise install ${{matrix.plugins}}@latest