copilot
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
pkgbase = github-copilot-cli
|
||||
pkgdesc = GitHub Copilot CLI brings the power of Copilot coding agent directly to your terminal.
|
||||
pkgver = 1.0.43
|
||||
pkgrel = 1
|
||||
url = https://github.com/github/copilot-cli
|
||||
arch = x86_64
|
||||
license = LicenseRef-GitHub-Copilot
|
||||
makedepends = npm
|
||||
makedepends = jq
|
||||
depends = glibc
|
||||
depends = gcc-libs
|
||||
depends = nodejs
|
||||
depends = glib2
|
||||
depends = libsecret
|
||||
provides = copilot
|
||||
conflicts = github-copilot
|
||||
conflicts = github-copilot-cli-legacy
|
||||
replaces = github-copilot
|
||||
noextract = copilot-1.0.43.tgz
|
||||
options = !strip
|
||||
options = emptydirs
|
||||
options = staticlibs
|
||||
options = zipman
|
||||
source = https://registry.npmjs.org/@github/copilot/-/copilot-1.0.43.tgz
|
||||
source = CHANGELOG-1.0.43.md::https://raw.githubusercontent.com/github/copilot-cli/v1.0.43/changelog.md
|
||||
b2sums = 0bfb5bf45ae16c6014e4c23460ee7750bbcf186672f8c7b6b2614d998090e08a97c3d91609b25c3f6d34d8dfc32c84b86f4bd8e9d48c4d539fa8f0e0eb84fda6
|
||||
b2sums = 0bc1f17025e60321fa296e9cef06704e834718b818d7b33f03fb5a37412229d86a92d2c70f074999838c03da5f497107e647b59ccd04ac3c3206e2e22f886c08
|
||||
|
||||
pkgname = github-copilot-cli
|
||||
@@ -0,0 +1,12 @@
|
||||
*
|
||||
!.nvchecker.toml
|
||||
!changelog.md
|
||||
!.gitignore
|
||||
!PKGBUILD
|
||||
!.SRCINFO
|
||||
|
||||
!LICENSES/*
|
||||
!LICENSE
|
||||
!REUSE
|
||||
!.omarchy/
|
||||
!.omarchy/**
|
||||
@@ -0,0 +1,5 @@
|
||||
[github-copilot-cli]
|
||||
source = "github"
|
||||
github = "github/copilot-cli"
|
||||
use_latest_release = true
|
||||
prefix = "v"
|
||||
@@ -0,0 +1,12 @@
|
||||
Copyright Arch Linux Contributors
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for
|
||||
any purpose with or without fee is hereby granted.
|
||||
|
||||
THE SOFTWARE IS PROVIDED “AS IS” AND THE AUTHOR DISCLAIMS ALL
|
||||
WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES
|
||||
OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE
|
||||
FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY
|
||||
DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
|
||||
AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
|
||||
OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
@@ -0,0 +1,90 @@
|
||||
# Maintainer: Rafael Dominiquini <rafaeldominiquini at gmail dot com>
|
||||
# Co-maintainer: edu4rdshl <edu4rdshl at protonmail dot com>
|
||||
|
||||
_npmmodule=@github/copilot
|
||||
|
||||
pkgname=github-copilot-cli
|
||||
_pkgexec=copilot
|
||||
|
||||
pkgver=1.0.43
|
||||
pkgrel=1
|
||||
|
||||
pkgdesc="GitHub Copilot CLI brings the power of Copilot coding agent directly to your terminal."
|
||||
|
||||
url="https://github.com/github/copilot-cli"
|
||||
_urlraw="https://raw.githubusercontent.com/github/copilot-cli/v${pkgver}"
|
||||
|
||||
arch=("x86_64")
|
||||
|
||||
license=("LicenseRef-GitHub-Copilot")
|
||||
|
||||
conflicts=("${pkgname%%-cli}" "${pkgname}-legacy")
|
||||
depends=("glibc" "gcc-libs" "nodejs" "glib2" "libsecret")
|
||||
replaces=("${pkgname%%-cli}")
|
||||
makedepends=("npm" "jq")
|
||||
provides=("${_pkgexec}")
|
||||
|
||||
options=(!strip emptydirs staticlibs zipman)
|
||||
|
||||
source=("https://registry.npmjs.org/${_npmmodule}/-/copilot-${pkgver}.tgz"
|
||||
"CHANGELOG-${pkgver}.md::${_urlraw}/changelog.md")
|
||||
noextract=("copilot-${pkgver}.tgz")
|
||||
|
||||
b2sums=('0bfb5bf45ae16c6014e4c23460ee7750bbcf186672f8c7b6b2614d998090e08a97c3d91609b25c3f6d34d8dfc32c84b86f4bd8e9d48c4d539fa8f0e0eb84fda6'
|
||||
'0bc1f17025e60321fa296e9cef06704e834718b818d7b33f03fb5a37412229d86a92d2c70f074999838c03da5f497107e647b59ccd04ac3c3206e2e22f886c08')
|
||||
|
||||
# Document: https://wiki.archlinux.org/title/Node.js_package_guidelines
|
||||
package() {
|
||||
msg2 "Install using Using NPM"
|
||||
npm install -s -g \
|
||||
--cache "${srcdir}/npm-cache" \
|
||||
--prefix "${pkgdir}/usr" \
|
||||
"${srcdir}/copilot-${pkgver}.tgz"
|
||||
|
||||
msg2 "Fix ownership of ALL FILES"
|
||||
find "${pkgdir}/usr" -type d -exec chmod 755 {} +
|
||||
chown -R root:root "${pkgdir}"
|
||||
|
||||
msg2 "Remove references to PKGDIR"
|
||||
find "${pkgdir}" -name package.json -print0 | xargs -r -0 sed -i '/_where/d'
|
||||
|
||||
msg2 "Fixing 'package.json'"
|
||||
local tmppackage="$(mktemp)"
|
||||
local pkgjson="${pkgdir}/usr/lib/node_modules/${_npmmodule}/package.json"
|
||||
jq '.|=with_entries(select(.key|test("_.+")|not))' "${pkgjson}" > "${tmppackage}"
|
||||
mv "${tmppackage}" "${pkgjson}"
|
||||
chmod 644 "${pkgjson}"
|
||||
|
||||
msg2 "More fixes for 'package.json'"
|
||||
find "${pkgdir}" -type f -name package.json | while read pkgjson; do
|
||||
local tmppackage="$(mktemp)"
|
||||
jq 'del(.man)' "${pkgjson}" > "${tmppackage}"
|
||||
mv "${tmppackage}" "${pkgjson}"
|
||||
chmod 644 "${pkgjson}"
|
||||
done
|
||||
|
||||
msg2 "Generating autocompletions for Bash"
|
||||
"${pkgdir}/usr/bin/copilot" completion bash > copilot
|
||||
install -Dm644 copilot "${pkgdir}/usr/share/bash-completion/completions/copilot"
|
||||
|
||||
msg2 "Generating autocompletions for Zsh"
|
||||
"${pkgdir}/usr/bin/copilot" completion zsh > _copilot
|
||||
install -Dm644 _copilot "${pkgdir}/usr/share/zsh/site-functions/_copilot"
|
||||
|
||||
msg2 "Generating autocompletions for Fish"
|
||||
"${pkgdir}/usr/bin/copilot" completion fish > copilot.fish
|
||||
install -Dm644 copilot.fish "${pkgdir}/usr/share/fish/vendor_completions.d/copilot.fish"
|
||||
|
||||
msg2 "Install README file"
|
||||
install -dm755 "${pkgdir}/usr/share/doc/${pkgname}/"
|
||||
ln -sf "/usr/lib/node_modules/${_npmmodule}/README.md" "${pkgdir}/usr/share/doc/${pkgname}/README.md"
|
||||
|
||||
msg2 "Install CHANGELOG file"
|
||||
install -Dm755 "${srcdir}/CHANGELOG-${pkgver}.md" "${pkgdir}/usr/share/doc/${pkgname}/CHANGELOG.md"
|
||||
|
||||
msg2 "Install LICENSE file"
|
||||
install -dm755 "${pkgdir}/usr/share/licenses/${pkgname}/"
|
||||
ln -sf "/usr/lib/node_modules/${_npmmodule}/LICENSE.md" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
|
||||
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user