commit:     ed70a243ffcf119987038edbc13ccf12fd32908e
Author:     Leonardo Hernandez Hernandez <leohdz172 <AT> outlook <DOT> com>
AuthorDate: Sat Sep 25 04:48:16 2021 +0000
Commit:     Arthur Zamarin <arthurzam <AT> gentoo <DOT> org>
CommitDate: Sat Sep 25 04:54:47 2021 +0000
URL:        https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=ed70a243

www-apps/code-server-bin: bump to 3.12.0

Closes: https://bugs.gentoo.org/807196

Package-Manager: Portage-3.0.20, Repoman-3.0.3
Signed-off-by: Leonardo Hernandez Hernandez <leohdz172 <AT> outlook.com>

 www-apps/code-server-bin/Manifest                  |  2 +
 .../code-server-bin/code-server-bin-3.12.0.ebuild  | 87 ++++++++++++++++++++++
 2 files changed, 89 insertions(+)

diff --git a/www-apps/code-server-bin/Manifest 
b/www-apps/code-server-bin/Manifest
index 41ec266f2..40ea4ae7e 100644
--- a/www-apps/code-server-bin/Manifest
+++ b/www-apps/code-server-bin/Manifest
@@ -1,2 +1,4 @@
 DIST code-server-3.10.0-linux-amd64.tar.gz 79827037 BLAKE2B 
238980bd822322dab956ce1dca8b8d7fa91eca6db8eb9808a68db28b9e9a8caa5432582cfa765ff0ac1ce948866a7f91a45df42045a83b75c13ac793ed1a78ee
 SHA512 
bd0410e0310a027ff1ed3f7c8b0d07a4a28baf8df924192d8a240f8011765b6a1daaae94bc7f37d1904dc9c2813d951eeb0c289aadd0192a15daa9cb6461c25d
 DIST code-server-3.10.0-linux-arm64.tar.gz 77802222 BLAKE2B 
f13ff2e1d83d7c7d3be0033196911aef81324aa0f450c8973919a128fafbbf9d255aba59b2bfc6432c2fa0dadb4cf179d57772f86ad2c87213d43eb60244d024
 SHA512 
bc149c0716dc4df560a87d149bfceb712b864bdfbfc99e43ee476a574d76d52acd02c3c87a9b09a47c73c0789c85f3794c350be4b222a930d8dc3d7eec49017e
+DIST code-server-3.12.0-linux-amd64.tar.gz 98959884 BLAKE2B 
7be2195b1d2e325244620bf59608fb21390846657249e182b43224ede950aafbd837b09100af67925a92054923239e079063e6dff23cc6c9e4c0dbe010684069
 SHA512 
f14fce86d4a837cdfe867beb7256d7d57035edac258c7ac5be8de8fb778771ad0ff5549920a41ef80504e738727c0159c1dbff70c7b48cfe37415dd4c9ad40c6
+DIST code-server-3.12.0-linux-arm64.tar.gz 97388956 BLAKE2B 
b73d41ce320e3af7e980972a64d7d47d11c9bf1d1d69ca7c7cb16e1963d5b1fada4558a8630c317cf82093f1aa4126c33246a3aec7581f2723d1497cedb504c8
 SHA512 
f23def255bc6bfcf0e796d7cabb104bb1c7a8576783150ff8b8f040a8792d3df8f97f7c5a8e7963eab2ff7f6f4a203543d4b127f27a7b2885ceb52ae62c8b5c6

diff --git a/www-apps/code-server-bin/code-server-bin-3.12.0.ebuild 
b/www-apps/code-server-bin/code-server-bin-3.12.0.ebuild
new file mode 100644
index 000000000..ed42aaf28
--- /dev/null
+++ b/www-apps/code-server-bin/code-server-bin-3.12.0.ebuild
@@ -0,0 +1,87 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+MY_PN="${PN/-bin/}"
+MY_P="${MY_PN}-${PV}"
+BASE_URI="https://github.com/cdr/${MY_PN}/releases/download/v${PV}/${MY_P}-linux";
+
+inherit systemd
+
+DESCRIPTION="VS Code in the browser (binary version with unbundled node and 
ripgrep)"
+HOMEPAGE="https://coder.com/";
+SRC_URI="
+       amd64? ( ${BASE_URI}-amd64.tar.gz )
+       arm64? ( ${BASE_URI}-arm64.tar.gz )
+"
+
+RESTRICT="test"
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="-* ~amd64 ~arm64"
+IUSE="gnome-keyring"
+
+RDEPEND="
+       ${DEPEND}
+       >=net-libs/nodejs-14.17.5:0/14[ssl]
+       sys-apps/ripgrep
+       gnome-keyring? (
+               app-crypt/libsecret
+       )
+"
+
+S="${WORKDIR}/${MY_P}-linux-${ARCH}"
+
+PATCHES=( "${FILESDIR}/${PN}-node.patch" )
+
+DOCS=( "README.md" "ThirdPartyNotices.txt" )
+
+QA_PREBUILT="
+       /usr/lib64/code-server/lib/coder-cloud-agent
+       /usr/lib64/code-server/vendor/modules/code-oss-dev/node_modules/*
+"
+QA_PRESTRIPPED="
+       /usr/lib64/code-server/lib/coder-cloud-agent
+"
+
+src_prepare() {
+       default
+
+       # We remove as much precompiled code as we can,
+       # node modules not written in JS cannot be removed
+       # thus "-bin".
+
+       # use system node
+       rm ./node ./lib/node \
+               || die "failed to remove bundled nodejs"
+
+       # remove bundled ripgrep binary
+       rm ./vendor/modules/code-oss-dev/node_modules/vscode-ripgrep/bin/rg \
+               || die "failed to remove bundled ripgrep"
+
+       # not needed
+       rm ./code-server || die
+       rm ./postinstall.sh || die
+
+       # already in /usr/portage/licenses/MIT
+       rm ./LICENSE.txt || die
+}
+
+src_install() {
+       einstalldocs
+
+       insinto "/usr/$(get_libdir)/${MY_PN}"
+       doins -r .
+       fperms +x "/usr/$(get_libdir)/${MY_PN}/bin/${MY_PN}"
+       dosym -r "/usr/$(get_libdir)/${MY_PN}/bin/${MY_PN}" 
"${EPREFIX}/usr/bin/${MY_PN}"
+
+       dosym -r "/usr/bin/rg" 
"${EPREFIX}/usr/$(get_libdir)/${MY_PN}/vendor/modules/code-oss-dev/node_modules/vscode-ripgrep/bin/rg"
+
+       systemd_dounit "${FILESDIR}/${MY_PN}.service"
+}
+
+pkg_postinst() {
+       elog "When using code-server systemd service run it as a user"
+       elog "For example: 'systemctl --user enable --now code-server'"
+}

Reply via email to