File: aspell-no.postinst

package info (click to toggle)
norwegian 2.2-4
  • links: PTS
  • area: main
  • in suites: bookworm, bullseye, buster, forky, sid, trixie
  • size: 26,448 kB
  • sloc: perl: 2,695; makefile: 1,678; sh: 209
file content (32 lines) | stat: -rw-r--r-- 798 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#!/bin/sh -e 

. /usr/share/debconf/confmodule

# Ask user about which aspell-dictionary it wants to use.
# (This should probably be replaced by debconf, eventually)
if [ "$1" = "configure" ]; then

  db_get aspell-no/whichvariant || true
  if [ "$RET" ]; then
    cd /usr/lib/aspell
    rm -f no.dat no.multi no_phonet.dat no norsk
    ln -f -s "${RET}_phonet.dat" no_phonet.dat
    if [ "$RET" = bokmaal ]; then
        ln -sf nb.multi no.multi
	ln -sf nb.dat no.dat
	ln -sf nb_phonet.dat no_phonet.dat
    elif [ "$RET" = nynorsk ]; then
        ln -sf nn.multi no.multi
	ln -sf nn.dat no.dat
	ln -sf nn_phonet.dat no_phonet.dat
    fi
  fi
fi

D=/usr/lib/aspell-0.60
if [ -d  "$D" ]; then
    rm -f $D/no.dat $D/no.multi $D/no_phonet.dat
    rmdir --ignore-fail-on-non-empty $D
fi

#DEBHELPER#