commit:     707a97113f456eb912cc3dd0d7ae6b0ca3583b7d
Author:     Arthur Zamarin <arthurzam <AT> gentoo <DOT> org>
AuthorDate: Sat Sep  7 15:00:22 2024 +0000
Commit:     Arthur Zamarin <arthurzam <AT> gentoo <DOT> org>
CommitDate: Sat Sep  7 15:00:48 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=707a9711

app-editors/vscode: add 1.93.0

Signed-off-by: Arthur Zamarin <arthurzam <AT> gentoo.org>

 app-editors/vscode/Manifest             |   3 +
 app-editors/vscode/vscode-1.93.0.ebuild | 131 ++++++++++++++++++++++++++++++++
 2 files changed, 134 insertions(+)

diff --git a/app-editors/vscode/Manifest b/app-editors/vscode/Manifest
index 1a5b619b092f..a0d25c0c81db 100644
--- a/app-editors/vscode/Manifest
+++ b/app-editors/vscode/Manifest
@@ -1,3 +1,6 @@
 DIST vscode-1.92.2-amd64.tar.gz 144730709 BLAKE2B 
acde98f31d5469ffc271c84e12ab8232af8c523a439f89d247e9f68d472650f8ee6425ad1be014632cb9d8622647cbe6c1c15ee6cfc58fac52f5eada716a9c88
 SHA512 
59e63815c260a412b757e692ea081e2029439120e877b0a436e692617ee57bb5aa3aea488c4a2363ae2a98bc76485fdfe477ac8314ac974a0f215ed594649694
 DIST vscode-1.92.2-arm.tar.gz 129669472 BLAKE2B 
34050c923c45b0b5b25d579a36f449895df640fbcfb16b759e1c209e82b42805640b85adb1d736f89835a487fbfbc2ac905fc0c17969ec7c6cd8c9838c02e6fd
 SHA512 
746a87f744fb51f679f3efd2385c6a3f6107632cc640967d4465e84e68e29dc12e6c42223c457bb2ab8d0e10a83bf42fd132f91466d40795971ad6348b5d04d8
 DIST vscode-1.92.2-arm64.tar.gz 141604400 BLAKE2B 
fa117d2e3dff1fd81c917347a060b4e276b26303ca8b6e93c035f4b4e9d7b72bad354e99ce3c482ad3fcb98cc83df12065b366ee33b934f3af0e9733648e88b3
 SHA512 
b0defdf1c0f368819538177070d8134bfabb3ef013845632c2a464f60bfae2bde34b237aa2ea97520bd3b841560e98c2f29a3627e962af8b288dbf4144ce4de6
+DIST vscode-1.93.0-amd64.tar.gz 145343718 BLAKE2B 
27bbb1e3d8a0007e5e207c082af1ae78acdfc322735d3cd99c61ab4865a8d24b059d0a60c13a4320bd6587a4217d39812356707b471f320ca87e2b15d96f0ea8
 SHA512 
57735dcacbafeaa2362382ea078056a2f451bd38bab4ac321b8fad81a07bbe6bfa1e1bdd1d8daceee57abf43711138f32f7ca8d67918ce0007f0ac2ac5fd7aa0
+DIST vscode-1.93.0-arm.tar.gz 130284214 BLAKE2B 
e3b109765a8c8d89de9f2b676f321b66765e622b37358d64380697d80668718ebcb7cdcf0d616becd5e31bc2db6e032ebdf4bd6a873cd4e0980b6b8e9f390730
 SHA512 
ec5f09023592eaf00b1597e9638eb248378c0fb2fca0dfb688cab2546a8296baffc49ac25aa0509550289ca5c3e56dc5d6ae03a6e92e4a760b6ce57876d22bdc
+DIST vscode-1.93.0-arm64.tar.gz 142237085 BLAKE2B 
517d4cc79cab13e6feed478c65b0feabf43e6b871c820e923c9124d3e9a2fe91db795d133e01a896bc635e7b47a0f6f1dabb9b63552d01801ec24c1e9f6d5eb8
 SHA512 
bdd8aa2e359e4ba17ab0e162d79b1da40d21ca488d123b08698e182631139d23168d5160ea4b128d17860cf32f76ae403267daabcced5c6c7a5d68e84681caa9

diff --git a/app-editors/vscode/vscode-1.93.0.ebuild 
b/app-editors/vscode/vscode-1.93.0.ebuild
new file mode 100644
index 000000000000..c06246461b83
--- /dev/null
+++ b/app-editors/vscode/vscode-1.93.0.ebuild
@@ -0,0 +1,131 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit desktop pax-utils xdg optfeature
+
+DESCRIPTION="Multiplatform Visual Studio Code from Microsoft"
+HOMEPAGE="https://code.visualstudio.com";
+SRC_URI="
+       amd64? ( https://update.code.visualstudio.com/${PV}/linux-x64/stable -> 
${P}-amd64.tar.gz )
+       arm? ( https://update.code.visualstudio.com/${PV}/linux-armhf/stable -> 
${P}-arm.tar.gz )
+       arm64? ( https://update.code.visualstudio.com/${PV}/linux-arm64/stable 
-> ${P}-arm64.tar.gz )
+"
+S="${WORKDIR}"
+
+LICENSE="
+       Apache-2.0
+       BSD
+       BSD-1
+       BSD-2
+       BSD-4
+       CC-BY-4.0
+       ISC
+       LGPL-2.1+
+       Microsoft-vscode
+       MIT
+       MPL-2.0
+       openssl
+       PYTHON
+       TextMate-bundle
+       Unlicense
+       UoI-NCSA
+       W3C
+"
+SLOT="0"
+KEYWORDS="-* amd64 ~arm ~arm64"
+IUSE="egl kerberos wayland"
+RESTRICT="mirror strip bindist"
+
+RDEPEND="
+       >=app-accessibility/at-spi2-core-2.46.0:2
+       app-crypt/libsecret[crypt]
+       app-misc/ca-certificates
+       dev-libs/expat
+       dev-libs/glib:2
+       dev-libs/nspr
+       dev-libs/nss
+       media-libs/alsa-lib
+       media-libs/libglvnd
+       media-libs/mesa
+       net-misc/curl
+       sys-apps/dbus
+       sys-libs/zlib
+       sys-process/lsof
+       x11-libs/cairo
+       x11-libs/gtk+:3
+       x11-libs/libdrm
+       x11-libs/libX11
+       x11-libs/libxcb
+       x11-libs/libXcomposite
+       x11-libs/libXdamage
+       x11-libs/libXext
+       x11-libs/libXfixes
+       x11-libs/libxkbcommon
+       x11-libs/libxkbfile
+       x11-libs/libXrandr
+       x11-libs/libXScrnSaver
+       x11-libs/pango
+       x11-misc/xdg-utils
+       kerberos? ( app-crypt/mit-krb5 )
+"
+
+QA_PREBUILT="*"
+
+src_install() {
+       if use amd64; then
+               cd "${WORKDIR}/VSCode-linux-x64" || die
+       elif use arm; then
+               cd "${WORKDIR}/VSCode-linux-armhf" || die
+       elif use arm64; then
+               cd "${WORKDIR}/VSCode-linux-arm64" || die
+       else
+               die "Visual Studio Code only supports amd64, arm and arm64"
+       fi
+
+       # Cleanup
+       rm -r ./resources/app/ThirdPartyNotices.txt || die
+
+       # Disable update server
+       sed -e "/updateUrl/d" -i ./resources/app/product.json || die
+
+       if ! use kerberos; then
+               rm -r ./resources/app/node_modules.asar.unpacked/kerberos || die
+       fi
+
+       # Install
+       pax-mark m code
+       mkdir -p "${ED}/opt/${PN}" || die
+       cp -r . "${ED}/opt/${PN}" || die
+       fperms 4711 /opt/${PN}/chrome-sandbox
+
+       dosym -r "/opt/${PN}/bin/code" "usr/bin/vscode"
+       dosym -r "/opt/${PN}/bin/code" "usr/bin/code"
+
+       local EXEC_EXTRA_FLAGS=()
+       if use wayland; then
+               EXEC_EXTRA_FLAGS+=( "--ozone-platform-hint=auto" 
"--enable-wayland-ime" )
+       fi
+       if use egl; then
+               EXEC_EXTRA_FLAGS+=( "--use-gl=egl" )
+       fi
+
+       sed "s|@exec_extra_flags@|${EXEC_EXTRA_FLAGS[*]}|g" \
+               "${FILESDIR}/code-url-handler.desktop" \
+               > "${T}/code-url-handler.desktop" || die
+
+       sed "s|@exec_extra_flags@|${EXEC_EXTRA_FLAGS[*]}|g" \
+               "${FILESDIR}/code.desktop" \
+               > "${T}/code.desktop" || die
+
+       domenu "${T}/code.desktop"
+       domenu "${T}/code-url-handler.desktop"
+       newicon "resources/app/resources/linux/code.png" "vscode.png"
+}
+
+pkg_postinst() {
+       xdg_pkg_postinst
+       optfeature "desktop notifications" x11-libs/libnotify
+       optfeature "keyring support inside vscode" "virtual/secret-service"
+}

Reply via email to