]> git.lyx.org Git - lyx.git/blob - development/cygwin/lyxprofile
81ef67f8c419d47940de7d1eff79a0f4845ce41c
[lyx.git] / development / cygwin / lyxprofile
1 # Set up the home directory if not already set in the system environment.
2 if [ -z "${HOME}" ]; then
3   USER=`id -un`
4   HOME=`grep "^${USER}:" /etc/passwd | cut -d: -f6`
5   if [ -z "${HOME}" -o ! -d "${HOME}" ]; then
6     DOCSFOLDER=`regtool -q get '\HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders\Personal'`
7     test -n "${DOCSFOLDER}" && HOME=`cygpath -u "${DOCSFOLDER}"` || HOME=/tmp
8   fi
9 fi
10 export HOME
11
12 # Set up your Language (if you do not want English) by
13 # replacing C (for C locale) with your country code in
14 # the following line.
15 export LANG=C
16
17 # Set up the output charset for your locale.
18 # You may need to experiment with this if you get garbage
19 # in menus ("`a" instead of "à", for example).
20 export OUTPUT_CHARSET=iso-8859-1
21
22 # Set up Hostname/IP address where LyX can find an X-server.
23 export DISPLAY=localhost:0.0
24
25 # ========================================================
26 # Below this line you should not change anything if you're
27 # not familiar with configuration of an unix application!
28 # ========================================================
29 export PATH="/usr/local/bin:/usr/bin:/usr/X11R6/bin:$PATH"
30 export USER="`id -un`"
31 export MAKE_MODE=unix
32 export OSTYPE=cygwin
33
34 unset DOSDRIVE
35 unset DOSDIR
36 unset TMPDIR
37 unset TMP
38
39 for f in /etc/profile.d/*.sh ; do
40   if [ -f "${f}" ]; then
41     . "${f}"
42   fi
43 done
44
45 if [ ! -z "${CDPATH}" ]; then
46   cd "${CDPATH}"
47   unset CDPATH
48 else
49   cd "${HOME}"
50 fi
51
52 test -f "${HOME}/.bashrc" && . "${HOME}/.bashrc"