~m-alaa8/ubuntu/raring/im-switch/fix-for-621204

« back to all changes in this revision

Viewing changes to debian/postinst

  • Committer: Bazaar Package Importer
  • Author(s): Osamu Aoki
  • Date: 2007-01-01 01:15:50 UTC
  • mfrom: (1.1.4 feisty)
  • Revision ID: james.westby@ubuntu.com-20070101011550-8uhfqb7jitnucy22
Tags: 1.14
Add pointer to wiki page. 

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
#!/bin/sh
2
2
set -e
3
3
 
 
4
ua_inst () {
 
5
        update-alternatives \
 
6
        --install /etc/X11/xinit/xinput.d/$1 xinput-$1 \
 
7
        /etc/X11/xinit/xinput.d/$2 $3 ;
 
8
}
 
9
 
 
10
# fix for 90im-switch -> 80im-switch transition. (After 1.13)
 
11
# If old version exists, clean it up. 
 
12
 
 
13
if [ -f /etc/X11/Xsession.d/90im-switch ]; then
 
14
    case `md5sum /etc/X11/Xsession.d/90im-switch|sed 's/ .*$//'` in
 
15
        # md5sum for version 1.5-1.11
 
16
        58e24e5a127a953e05a0bed82b943700 |\
 
17
        cb724d4db7f531b50c218007a2b9d7f2 |\
 
18
        fac350767f9316f0ceb65b7da9638f5f |\
 
19
        9711c96cdaf57a74f36793c30e964537 |\
 
20
        012637550e0bfbdf83f703474acccea2 |\
 
21
        acb685ae9264be3fc1800f98a70b12bb )
 
22
    rm -f /etc/X11/Xsession.d/90im-switch
 
23
    ;;
 
24
    * )
 
25
    echo You have customized /etc/X11/Xsession.d/90im-switch file
 
26
    echo with its md5sum = `md5sum /etc/X11/Xsession.d/90im-switch|sed 's/ .*$//'`.
 
27
    echo Please remove it or move it up to 80im-switch.
 
28
    ;;
 
29
    esac
 
30
fi
 
31
 
 
32
 
4
33
case "$1" in
5
34
    configure)
6
 
        update-alternatives \
7
 
        --install /etc/X11/xinit/xinput.d/ja_JP xinput-ja_JP \
8
 
        /etc/X11/xinit/xinput.d/none 10
 
35
        # Set up default
 
36
        ua_inst all_ALL default  10
 
37
        ua_inst all_ALL none  0
 
38
        # Set up *-xim
 
39
        ua_inst th_TH th-xim  20
9
40
    ;;
10
41
 
11
42
    abort-upgrade|abort-remove|abort-deconfigure)