mirror of
https://github.com/archlinux/aur.git
synced 2026-02-08 13:12:02 +01:00
Update to version 1.4.2 (commit d01860bc5f5a36b62f8a77cd42578126270db343)
This commit is contained in:
parent
299f1845a6
commit
ecb2aa5b0a
2 changed files with 55 additions and 49 deletions
33
.SRCINFO
33
.SRCINFO
|
|
@ -1,21 +1,24 @@
|
|||
pkgbase = cursor-bin
|
||||
pkgdesc = Cursor App - AI-first coding environment
|
||||
pkgdesc = AI-first coding environment
|
||||
pkgver = 1.4.2
|
||||
pkgrel = 2
|
||||
url = https://www.cursor.com/
|
||||
pkgrel = 4
|
||||
url = https://www.cursor.com
|
||||
arch = x86_64
|
||||
license = custom:Proprietary
|
||||
depends = fuse2
|
||||
depends = gtk3
|
||||
noextract = cursor-bin-1.4.2.AppImage
|
||||
license = LicenseRef-Cursor_EULA
|
||||
depends = ripgrep
|
||||
depends = xdg-utils
|
||||
depends = gcc-libs
|
||||
depends = hicolor-icon-theme
|
||||
depends = libxkbfile
|
||||
options = !strip
|
||||
source_x86_64 = cursor-bin-1.4.2.AppImage::https://downloads.cursor.com/production/d01860bc5f5a36b62f8a77cd42578126270db343/linux/x64/Cursor-1.4.2-x86_64.AppImage
|
||||
source_x86_64 = cursor.png
|
||||
source_x86_64 = cursor-bin.desktop.in
|
||||
source_x86_64 = cursor-bin.sh
|
||||
sha512sums_x86_64 = 4347b62fd647177c209fd9d232e5cc9ca864414a968f17eaef71772960d6b005f13f7910be4e30df605cb8345f9ef20566d29f309bb15d654e26ba76f8d62690
|
||||
sha512sums_x86_64 = f948c5718c2df7fe2cae0cbcd95fd3010ecabe77c699209d4af5438215daecd74b08e03d18d07a26112bcc5a80958105fda724768394c838d08465fce5f473e7
|
||||
sha512sums_x86_64 = 813d42d46f2e6aad72a599c93aeb0b11a668ad37b3ba94ab88deec927b79c34edf8d927e7bb2140f9147b086562736c3f708242183130824dd74b7a84ece67aa
|
||||
sha512sums_x86_64 = ec3fa93a7df3ac97720d57e684f8745e3e34f39d9976163ea0001147961ca4caeb369de9d1e80c877bb417a0f1afa49547d154dde153be7fe6615092894cff47
|
||||
source = cursor-bin-1.4.2.AppImage::https://downloads.cursor.com/production/d01860bc5f5a36b62f8a77cd42578126270db343/linux/x64/Cursor-1.4.2-x86_64.AppImage
|
||||
source = https://gitlab.archlinux.org/archlinux/packaging/packages/code/-/raw/main/code.sh
|
||||
sha512sums = 4347b62fd647177c209fd9d232e5cc9ca864414a968f17eaef71772960d6b005f13f7910be4e30df605cb8345f9ef20566d29f309bb15d654e26ba76f8d62690
|
||||
sha512sums = 937299c6cb6be2f8d25f7dbc95cf77423875c5f8353b8bd6cd7cc8e5603cbf8405b14dbf8bd615db2e3b36ed680fc8e1909410815f7f8587b7267a699e00ab37
|
||||
|
||||
pkgname = cursor-bin
|
||||
depends = ripgrep
|
||||
depends = xdg-utils
|
||||
depends = gcc-libs
|
||||
depends = hicolor-icon-theme
|
||||
depends = libxkbfile
|
||||
|
|
|
|||
71
PKGBUILD
71
PKGBUILD
|
|
@ -2,43 +2,46 @@
|
|||
|
||||
pkgname=cursor-bin
|
||||
pkgver=1.4.2
|
||||
pkgrel=2
|
||||
pkgdesc="Cursor App - AI-first coding environment"
|
||||
pkgrel=4
|
||||
pkgdesc='AI-first coding environment'
|
||||
arch=('x86_64')
|
||||
url="https://www.cursor.com/"
|
||||
license=('custom:Proprietary') # Replace with the correct license if known
|
||||
depends=('fuse2' 'gtk3')
|
||||
options=(!strip)
|
||||
url="https://www.cursor.com"
|
||||
license=('LicenseRef-Cursor_EULA')
|
||||
# electron* is added at package()
|
||||
depends=('ripgrep' 'xdg-utils'
|
||||
'gcc-libs' 'hicolor-icon-theme' 'libxkbfile')
|
||||
options=(!strip) # Don't break ext of VSCode
|
||||
_appimage="${pkgname}-${pkgver}.AppImage"
|
||||
source_x86_64=("${_appimage}::https://downloads.cursor.com/production/d01860bc5f5a36b62f8a77cd42578126270db343/linux/x64/Cursor-1.4.2-x86_64.AppImage" "cursor.png" "${pkgname}.desktop.in" "${pkgname}.sh")
|
||||
noextract=("${_appimage}")
|
||||
sha512sums_x86_64=('4347b62fd647177c209fd9d232e5cc9ca864414a968f17eaef71772960d6b005f13f7910be4e30df605cb8345f9ef20566d29f309bb15d654e26ba76f8d62690'
|
||||
'f948c5718c2df7fe2cae0cbcd95fd3010ecabe77c699209d4af5438215daecd74b08e03d18d07a26112bcc5a80958105fda724768394c838d08465fce5f473e7'
|
||||
'813d42d46f2e6aad72a599c93aeb0b11a668ad37b3ba94ab88deec927b79c34edf8d927e7bb2140f9147b086562736c3f708242183130824dd74b7a84ece67aa'
|
||||
'ec3fa93a7df3ac97720d57e684f8745e3e34f39d9976163ea0001147961ca4caeb369de9d1e80c877bb417a0f1afa49547d154dde153be7fe6615092894cff47')
|
||||
|
||||
prepare() {
|
||||
# Set correct version in .desktop file
|
||||
sed "s/@@PKGVERSION@@/${pkgver}/g" "${srcdir}/${pkgname}.desktop.in" > "${srcdir}/cursor-cursor.desktop"
|
||||
}
|
||||
_commit=d01860bc5f5a36b62f8a77cd42578126270db343
|
||||
source=("${_appimage}::https://downloads.cursor.com/production/d01860bc5f5a36b62f8a77cd42578126270db343/linux/x64/Cursor-1.4.2-x86_64.AppImage"
|
||||
https://gitlab.archlinux.org/archlinux/packaging/packages/code/-/raw/main/code.sh)
|
||||
sha512sums=('4347b62fd647177c209fd9d232e5cc9ca864414a968f17eaef71772960d6b005f13f7910be4e30df605cb8345f9ef20566d29f309bb15d654e26ba76f8d62690'
|
||||
'937299c6cb6be2f8d25f7dbc95cf77423875c5f8353b8bd6cd7cc8e5603cbf8405b14dbf8bd615db2e3b36ed680fc8e1909410815f7f8587b7267a699e00ab37')
|
||||
|
||||
_app=usr/share/cursor/resources/app
|
||||
package() {
|
||||
# Create directories
|
||||
install -d "${pkgdir}/opt/${pkgname}"
|
||||
install -d "${pkgdir}/usr/bin"
|
||||
install -d "${pkgdir}/usr/share/applications"
|
||||
install -d "${pkgdir}/usr/share/icons"
|
||||
rm -rf squashfs-root
|
||||
chmod +x ${_appimage}
|
||||
# Don't use upstream's broken resources
|
||||
for _f in co.anysphere.cursor.png usr/bin usr/share/{appdata,applications,bash-completion,mime,zsh}
|
||||
do ./${_appimage} --appimage-extract $_f > /dev/null
|
||||
done
|
||||
./${_appimage} --appimage-extract usr/share/cursor/resources/app > /dev/null
|
||||
cd squashfs-root
|
||||
mv usr/share/zsh/{vendor-completions,site-functions}
|
||||
install -Dm644 co.anysphere.cursor.png -t usr/share/pixmaps
|
||||
ln -svf /usr/bin/rg ${_app}/node_modules/@vscode/ripgrep/bin/rg
|
||||
ln -svf /usr/bin/xdg-open ${_app}/node_modules/open/xdg-open
|
||||
|
||||
# Install files with proper permissions
|
||||
install -m644 "${srcdir}/cursor-cursor.desktop" "${pkgdir}/usr/share/applications/cursor-cursor.desktop"
|
||||
install -m644 "${srcdir}/cursor.png" "${pkgdir}/usr/share/icons/cursor.png"
|
||||
install -m755 "${srcdir}/${_appimage}" "${pkgdir}/opt/${pkgname}/${pkgname}.AppImage"
|
||||
|
||||
# Install executable to be called 'cursor', that can load user flags from $XDG_CONFIG_HOME/cursor-flags.conf
|
||||
install -m755 "${srcdir}/${pkgname}.sh" "${pkgdir}/usr/bin/cursor"
|
||||
}
|
||||
|
||||
post_install() {
|
||||
update-desktop-database -q
|
||||
xdg-icon-resource forceupdate
|
||||
_vscode=$(grep -oP '"vscodeVersion": "\K[^"]+' ${_app}/product.json)
|
||||
# Insecure! Should be part of GitHub WF
|
||||
# Allow packaging with other electron by sed'ding PKGBUILD
|
||||
_electron=electron$(curl -Ls https://raw.githubusercontent.com/microsoft/vscode/refs/tags/${_vscode}/package-lock.json | grep -oP '"electron": *"[^\d]*\K\d+')
|
||||
#curl -Ls https://github.com/microsoft/vscode/archive/refs/tags/${_vscode}.tar.gz | bsdtar -xf - vscode-${_vscode}/package-lock.json
|
||||
#_electron=electron$(grep -oP '"electron": *"[^\d]*\K\d+' vscode-${_vscode}/package-lock.json)
|
||||
echo $_electron
|
||||
depends+=($_electron)
|
||||
mv usr "${pkgdir}"/usr
|
||||
sed -e "s|code-flags|cursor-flags|" -e "s|/usr/lib/code|/${_app}|" -e "s|/usr/lib/code/code.mjs|--app=/${_app}|" \
|
||||
-e "s|name=electron|name=${_electron}|" "${srcdir}"/code.sh | install -Dm755 /dev/stdin "${pkgdir}"/usr/share/cursor/cursor
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue