go-toolbox/scripts/workers/mockery.sh
Stanislav N. aka pztrn ea9a6db5b4
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/tag Build is passing
Update software to latest versions.
2024-09-21 23:59:52 +05:00

15 lines
504 B
Bash
Executable File

#!/bin/bash
mockery_v2_version=2.46.0
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*