• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#!/bin/sh
2. "${srcdir=.}/init.sh"; path_prepend_ . ../src
3
4# Test Tcl support: --add-comments option.
5
6cat <<\EOF > xg-t-3.tcl
7# a
8set string [_ "hello world" # b
9] # c
10EOF
11
12: ${XGETTEXT=xgettext}
13${XGETTEXT} --add-comments --omit-header --no-location --keyword=_ \
14  -d xg-t-3.tmp xg-t-3.tcl || Exit 1
15LC_ALL=C tr -d '\r' < xg-t-3.tmp.po > xg-t-3.po || Exit 1
16
17cat <<EOF > xg-t-3.ok
18#. a
19msgid "hello world"
20msgstr ""
21EOF
22
23: ${DIFF=diff}
24${DIFF} xg-t-3.ok xg-t-3.po
25result=$?
26
27exit $result
28