# Template file for 'vscodium'
pkgname=vscodium
version=1.99.32562
revision=1
only_for_archs="x86_64"
hostmakedepends="tar xz"
makedepends=""
depends=""
short_desc="Free/Libre Open Source Software Binaries of VSCode"
maintainer="Naz <ndpm13@ch-naeseem.com>"
license="MIT"
homepage="https://vscodium.com/"
distfiles="https://github.com/VSCodium/vscodium/releases/download/${version}/codium_${version}_amd64.deb"
checksum=e96e692d00deb57d4c7426d4cd3a7d313964081d720bca0ad34c63d5a001c159

do_extract() {
  mkdir -p ${DESTDIR}
  ar x ${XBPS_SRCDISTDIR}/${pkgname}-${version}/codium_${version}_amd64.deb
  tar xf data.tar.xz -C ${DESTDIR}
}

do_install() {
	vcopy ${DESTDIR}/usr/share/codium /usr/lib/

	vmkdir usr/bin
	ln -sf /usr/lib/codium/codium ${DESTDIR}/usr/bin/codium

  # Cleanup up
  rm -rf ${DESTDIR}/etc
  rm -rf ${DESTDIR}/usr/share/codium
}
