summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorZeioth2023-03-20 17:07:57 +0100
committerZeioth2023-03-20 17:07:57 +0100
commit8c75459624d0795a70e7db7e65f351bff92f4844 (patch)
tree7c805b0a43e1e2139e30a6a45c359f6a3724c445
parent2c191c0fbc2e326c9210d5b4ffeac802b405cffe (diff)
downloadaur-8c75459624d0795a70e7db7e65f351bff92f4844.tar.gz
Added necessary xdg-open sed to the installer
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD22
2 files changed, 9 insertions, 15 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 9b87b8e87b70..1c7505dd2cff 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -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
diff --git a/PKGBUILD b/PKGBUILD
index 8f4b4420777f..5de9d22779cf 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -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
}