Skip to content

Linux recipes

Piotr Grabowski edited this page Nov 3, 2022 · 13 revisions

For more, see also Mining recipes and OCR recipes.

Cleanly launch/close a VN + Textractor + Kamite in a single terminal window

A template of a bash script to launch multiple programs that does not leave behind background processes when terminated with Ctrl + C.

#!/usr/bin/env bash

trap "kill 0" EXIT

export WINEPREFIX=/path/to/wineprefix
export WINEARCH=win32
export LANG="ja_JP.UTF-8"

TZ="JAPAN" \
  wine start /exec "/path/to/vn/VN.lnk" &
kamite --profile=vn --controlWindow=false &
wine "/path/to/textractor/Textractor.exe" &

wait

Credit: https://spin.atomicobject.com/2017/08/24/start-stop-bash-background-process/.

Clone this wiki locally