2024-05-04 13:18:37 +05:00
|
|
|
#!/bin/bash
|
|
|
|
|
2024-07-07 20:38:54 +05:00
|
|
|
mockery_v2_version=2.43.2
|
2024-05-04 13:18:37 +05:00
|
|
|
|
|
|
|
cd /tmp || exit 1
|
|
|
|
|
|
|
|
# mockery v2 we download from releases page
|
|
|
|
arch=$(uname -m)
|
|
|
|
download_url="https://github.com/vektra/mockery/releases/download/v${mockery_v2_version}/mockery_${mockery_v2_version}_Linux_${arch}.tar.gz"
|
|
|
|
curl -L ${download_url} -o "/tmp/mockery_${arch}.tar.gz"
|
|
|
|
mkdir /tmp/mockery_v2
|
|
|
|
tar xf "/tmp/mockery_${arch}.tar.gz" -C /tmp/mockery_v2
|
|
|
|
mv /tmp/mockery_v2/mockery /usr/local/bin/mockery_v2
|
|
|
|
rm -rf "/tmp/mockery_$(uname -m).tar.gz" /tmp/mockery*
|