logo

overlay

My own overlay for experimentations, use with caution, no support is provided git clone https://anongit.hacktivis.me/git/overlay.git/

kuroshiro-1.2.0-r0.ebuild (797B)


  1. # Copyright 2023 Haelwenn (lanodan) Monnier <contact@hacktivis.me>
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=8
  4. inherit nodejs
  5. DESCRIPTION="Convert Japanese to Hiragana, Katakana or Romaji with furigana and okurigana modes"
  6. HOMEPAGE="https://kuroshiro.org/"
  7. SRC_URI="https://github.com/hexenq/kuroshiro/archive/refs/tags/${PV}.tar.gz -> ${P}.tar.gz"
  8. LICENSE="MIT"
  9. SLOT="0"
  10. KEYWORDS="~amd64"
  11. IUSE=""
  12. BDEPEND="dev-util/esbuild"
  13. RESTRICT="test" # Uses jest
  14. src_prepare() {
  15. default
  16. # Needed for CommonJS
  17. sed -i 's;export default ;module.exports = ;' src/index.js || die
  18. }
  19. src_compile() {
  20. # Uses babel by default, let's use esbuild for now instead to create a similar result
  21. esbuild --bundle src/index.js --outdir=lib --minify --sourcemap --format=cjs || die
  22. }