-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
103 additions
and
57 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,3 +8,4 @@ dist | |
*.tar.* | ||
_trial_temp | ||
deluge/i18n/* | ||
*.desktop |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
#!/bin/sh | ||
|
||
# Fixes glade files which may have set gtk stock labels set to translatable | ||
for x in `find . -name '*.glade' |grep -v '.git\|build'` ; do \ | ||
for y in gtk-add gtk-apply gtk-bold gtk-cancel gtk-cdrom gtk-clear \ | ||
gtk-close gtk-color-picker gtk-connect gtk-convert gtk-copy gtk-cut \ | ||
gtk-delete gtk-dialog-error gtk-dialog-info gtk-dialog-question \ | ||
gtk-dialog-warning gtk-dnd gtk-dnd-multiple gtk-edit gtk-execute gtk-find \ | ||
gtk-find-and-replace gtk-floppy gtk-goto-bottom gtk-goto-first \ | ||
gtk-goto-last gtk-goto-top gtk-go-back gtk-go-down gtk-go-forward \ | ||
gtk-go-up gtk-help gtk-home gtk-index gtk-italic gtk-jump-to \ | ||
gtk-justify-center gtk-justify-fill gtk-justify-left gtk-missing-image \ | ||
gtk-new gtk-no gtk-ok gtk-open gtk-paste gtk-preferences gtk-print \ | ||
gtk-print-preview gtk-properties gtk-quit gtk-redo gtk-refresh \ | ||
gtk-remove gtk-revert-to-saved gtk-save gtk-save-as gtk-select-color \ | ||
gtk-select-font gtk-sort-descending gtk-spell-check gtk-stop \ | ||
gtk-strikethrough gtk-undelete gtk-underline gtk-undo gtk-yes \ | ||
gtk-zoom-100 gtk-zoom-fit gtk-zoom-in gtk-zoom-out; do \ | ||
sed -i "s/<property\ name\=\"label\"\ translatable\=\"yes\">$y<\/property>/<property\ name\=\"label\"\ translatable\=\"no\">$y<\/property>/g" $x; \ | ||
done;\ | ||
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 4 additions & 4 deletions
8
...ge/data/share/applications/deluge.desktop → ...data/share/applications/deluge.desktop.in
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,26 @@ | ||
#!/bin/sh | ||
for x in `find . -name '*.glade' |grep -v '.git\|build'` ; do \ | ||
for y in gtk-add gtk-apply gtk-bold gtk-cancel gtk-cdrom gtk-clear \ | ||
gtk-close gtk-color-picker gtk-connect gtk-convert gtk-copy gtk-cut \ | ||
gtk-delete gtk-dialog-error gtk-dialog-info gtk-dialog-question \ | ||
gtk-dialog-warning gtk-dnd gtk-dnd-multiple gtk-edit gtk-execute gtk-find \ | ||
gtk-find-and-replace gtk-floppy gtk-goto-bottom gtk-goto-first \ | ||
gtk-goto-last gtk-goto-top gtk-go-back gtk-go-down gtk-go-forward \ | ||
gtk-go-up gtk-help gtk-home gtk-index gtk-italic gtk-jump-to \ | ||
gtk-justify-center gtk-justify-fill gtk-justify-left gtk-missing-image \ | ||
gtk-new gtk-no gtk-ok gtk-open gtk-paste gtk-preferences gtk-print \ | ||
gtk-print-preview gtk-properties gtk-quit gtk-redo gtk-refresh \ | ||
gtk-remove gtk-revert-to-saved gtk-save gtk-save-as gtk-select-color \ | ||
gtk-select-font gtk-sort-descending gtk-spell-check gtk-stop \ | ||
gtk-strikethrough gtk-undelete gtk-underline gtk-undo gtk-yes \ | ||
gtk-zoom-100 gtk-zoom-fit gtk-zoom-in gtk-zoom-out; do \ | ||
sed -i "s/<property\ name\=\"label\"\ translatable\=\"yes\">$y<\/property>/<property\ name\=\"label\"\ translatable\=\"no\">$y<\/property>/g" $x; \ | ||
done;\ | ||
done | ||
xgettext --from-code ISO-8859-1 -f deluge/i18n/POTFILES.in -o deluge/i18n/deluge.pot | ||
PACKAGE="Deluge" | ||
PKG_VERSION=`grep "version\ =\ \"" setup.py | cut -d '"' -f2` | ||
PO_DIR="deluge/i18n" | ||
POTFILES_IN="infiles.list" | ||
POT_FILE=deluge.pot | ||
|
||
cp $PO_DIR/POTFILES.in $POTFILES_IN | ||
DESKTOP_FILE=`grep ".*desktop.in$" $POTFILES_IN` | ||
|
||
if [ $DESKTOP_FILE ]; then | ||
sed -i "\:$DESKTOP_FILE:d" $POTFILES_IN | ||
intltool-extract --quiet --type=gettext/ini $DESKTOP_FILE | ||
echo "$DESKTOP_FILE.h" >> $POTFILES_IN | ||
fi | ||
|
||
xgettext --from-code=UTF-8 -kN_:1 -f $POTFILES_IN -o $PO_DIR/$POT_FILE --package-name=$PACKAGE \ | ||
--copyright-holder='Deluge Team' --package-version=$PKG_VERSION \ | ||
--msgid-bugs-address=http://deluge-torrent.org | ||
|
||
# sub the YEAR in the copyright message | ||
sed -i -e '2s/YEAR/'`date +%Y`'/' "$PO_DIR/$POT_FILE" | ||
|
||
rm -f $POTFILES_IN | ||
rm -f "$DESKTOP_FILE.h" | ||
echo "Created $PO_DIR/$POT_FILE" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters