diff options
-rw-r--r-- | .SRCINFO | 2 | ||||
-rw-r--r-- | PKGBUILD | 22 |
2 files changed, 9 insertions, 15 deletions
@@ -1,7 +1,7 @@ pkgbase = chatgpt-shell-cli pkgdesc = Use OpenAI's ChatGPT and DALL-E from the terminal. pkgver = 0.1 - pkgrel = 2 + pkgrel = 3 url = https://github.com/0xacx/chatGPT-shell-cli.git arch = any license = MIT @@ -1,29 +1,23 @@ # Maintainer: Adrian Lopez <zeioth@hotmail.com> pkgname=chatgpt-shell-cli pkgver=0.1 -pkgrel=2 -epoch= +pkgrel=3 pkgdesc="Use OpenAI's ChatGPT and DALL-E from the terminal." arch=(any) url="https://github.com/0xacx/chatGPT-shell-cli.git" license=('MIT') -groups=() depends=(jq curl) -makedepends=() -checkdepends=() -optdepends=() provides=(chatgpt-shell-cli) conflicts=(chatgpt-shell-cli-git) -replaces=() -backup=() -options=() -install= -changelog= source=("git+$url#commit=e47853176d2cc36602ca04507fd3b5525f623737") -noextract=() sha256sums=('SKIP') -validpgpkeys=() package() { - install -Dm755 "${srcdir}/chatGPT-shell-cli/chatgpt.sh" "${pkgdir}/usr/local/bin/chatgpt" + # Install + install -Dm755 "${srcdir}/chatGPT-shell-cli/chatgpt.sh" "${pkgdir}/usr/local/bin/chatgpt" + + # Replace open image command with xdg-open for linux systems + if [[ "$OSTYPE" == "linux-gnu"* ]] || [[ "$OSTYPE" == "freebsd"* ]]; then + sudo sed -i 's/open "\${image_url}"/xdg-open "\${image_url}"/g' '/usr/local/bin/chatgpt' + fi } |