Compare commits

...

6 Commits
0.2.0 ... main

Author SHA1 Message Date
bdd8835a07 Fix trailing punctuation 2023-10-20 16:23:24 -05:00
858994eef1 remove path from example 2023-10-20 16:22:21 -05:00
4dd86376c9 install now always uses latest release and updated
README with installation instructions
2023-10-18 00:02:46 -05:00
b438f31f89 Adding install script. Fixes #4 2023-10-17 23:40:18 -05:00
54736f440a revert 1f202279c9f0d11bd5d148fd77fb102d669337d2
revert Adding install script.  Fixes #3
2023-10-17 23:39:37 -05:00
1f202279c9 Adding install script. Fixes #3 2023-10-17 23:37:40 -05:00
2 changed files with 79 additions and 2 deletions

View File

@ -38,10 +38,10 @@ password: apiclient12345
clientId: default
```
## Example usage:
## Example usage
```shell
% ./bin/tps_darwin_arm64 list -f conversation-service
tps list -f conversation-service
```
```shell
@ -60,3 +60,9 @@ Using config file: /Users/Peter.Morton/.tps.yaml
## Building
make
## Installing
```shell
curl -sSL https://git.mortons.site/verint.com/tps-cli/raw/branch/main/install.sh | bash
```

71
install.sh Executable file
View File

@ -0,0 +1,71 @@
#!/usr/bin/env bash
# shellcheck disable=SC1090
set -e
OS="$(uname -s)"
ARCH="$(uname -m)"
VERSION=0.2.0
case $OS in
"Linux")
case $ARCH in
"x86_64")
ARCH=amd64
;;
"aarch64")
ARCH=arm64
;;
"armv6" | "armv7l")
ARCH=armv6l
;;
"armv8")
ARCH=arm64
;;
"i686")
ARCH=386
;;
.*386.*)
ARCH=386
;;
esac
PLATFORM="linux_$ARCH"
;;
"Darwin")
case $ARCH in
"x86_64")
ARCH=amd64
;;
"arm64")
ARCH=arm64
;;
esac
PLATFORM="darwin_$ARCH"
;;
esac
print_help() {
echo "Usage: bash goinstall.sh OPTIONS"
echo -e "\nOPTIONS:"
echo -e " --remove\tRemove currently installed version"
echo -e " --version\tSpecify a version number to install"
}
if [ -z "$PLATFORM" ]; then
echo "Your operating system is not supported by the script."
exit 1
fi
# get latest tag path
TAG_PATH="$(curl -s https://git.mortons.site/verint.com/tps-cli/releases/latest | sed -n 's/^<a.* href="\([^"]*\).*/\1/p')"
TAG_PATH="${TAG_PATH/tag/download}"
if hash wget 2>/dev/null; then
wget https://git.mortons.site${TAG_PATH}/tps_${PLATFORM} -O "tps"
else
curl -o "tps" https://git.mortons.site${TAG_PATH}/tps_${PLATFORM}
fi
chmod u+x tps