From 1cdf83968faf676f2478f5d583c525f200a9f48e Mon Sep 17 00:00:00 2001 From: Zergling_man Date: Sun, 3 Nov 2024 16:32:44 +1100 Subject: [PATCH] Bash pls --- swat-codegen/PKGBUILD | 2 +- swat-codegen/codegen.sh | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/swat-codegen/PKGBUILD b/swat-codegen/PKGBUILD index 5fb27fe..03d8028 100644 --- a/swat-codegen/PKGBUILD +++ b/swat-codegen/PKGBUILD @@ -1,7 +1,7 @@ # Maintainer: Zergling_man, from fedora.email pkgname=swat-codegen -pkgver=1.0.3 +pkgver=1.0.4 pkgrel=1 pkgdesc="A simple CLI interface to RCPDv3, the rank code management service for the game SWAT: Aftermath" arch=('any') diff --git a/swat-codegen/codegen.sh b/swat-codegen/codegen.sh index b7ed676..b4077ed 100755 --- a/swat-codegen/codegen.sh +++ b/swat-codegen/codegen.sh @@ -31,7 +31,7 @@ function get function post { TOKE=`get_token` - curl -H "Authorization:Bearer $TOKE" https://swataftermath.com:9443/account/$1 --json "${*:2}" + curl -H "Authorization:Bearer $TOKE" https://swataftermath.com:9443/account/$1 --json "$2" } function delete_code @@ -65,7 +65,7 @@ function builds function save { if [ -n "$2" ]; then name=',"buildName":"'"${*:2}"'"'; fi - post rank-code '{"rankCode":"'$1'"'$name'}' | jq + post rank-code '{"rankCode":"'$1'"'"$name"'}' | jq if [ -z "$2" ]; then delete_code $1; fi # Don't bother storing any build that doesn't have a name. Assume it's just logging the results of a game. } @@ -102,4 +102,4 @@ function generate } # DO SHIT -$@ \ No newline at end of file +"$@" \ No newline at end of file