Skip to content

Commit

Permalink
documentation etc. fix
Browse files Browse the repository at this point in the history
Signed-off-by: Kwpolska <kwpolska@gmail.com>
  • Loading branch information
Kwpolska committed Sep 29, 2012
1 parent 31a171e commit 97b0da1
Show file tree
Hide file tree
Showing 11 changed files with 49 additions and 20 deletions.
6 changes: 4 additions & 2 deletions docs/CHANGELOG.rst
@@ -1,15 +1,17 @@
======================
CHANGELOG for Trashman
======================
:Author: Kwpolska
:Copyright: See Appendix B.
:Author: Kwpolska <kwpolska@kwpolska.tk>
:Copyright: © 2011-2012, Kwpolska.
:License: BSD (see /LICENSE or :doc:`Appendix B <LICENSE>`.)
:Date: 2012-09-09
:Version: 1.0.3

.. index:: CHANGELOG

1.0.0
=====
:1.0.3: I do not like the word “exit”.
:1.0.2: Fixes #2, creating config dirs properly. (the app crashed if there was no ~/.config/kwpolska/ dir. This bug wasn’t found due to having PKGBUILDer installed, which was creating that directory.)
:1.0.1: Bugfix release.
:1.0.0: A complete modification of the approach, now using a concept of “backends”, allowing multiple trash systems to be used.
Expand Down
7 changes: 6 additions & 1 deletion docs/CONTRIBUTING.rst
Expand Up @@ -2,7 +2,8 @@
Appendix D. Contribution rules
==============================
:Author: Kwpolska <kwpolska@kwpolska.tk>
:Copyright: See Appendix B.
:Copyright: © 2011-2012, Kwpolska.
:License: BSD (see /LICENSE or :doc:`Appendix B <LICENSE>`.)
:Date: 2012-09-09
:Version: 1.0.3

Expand All @@ -15,6 +16,10 @@ Issue reporting
GitHub Issues are the best way to report an issue. If you do not have an
account there, get one or mail me.

When pasting console sessions, please paste them fully, *prompt-to-prompt*, to
see all the messages and your input. Trim only stuff that you are 1000% sure
that is not related to the project in question.

Code contributions
==================

Expand Down
5 changes: 3 additions & 2 deletions docs/TODO.rst
@@ -1,8 +1,9 @@
=============================
Appendix E. TODO for Trashman
=============================
:Author: Kwpolska
:Copyright: See Appendix B.
:Author: Kwpolska <kwpolska@kwpolska.tk>
:Copyright: © 2011-2012, Kwpolska.
:License: BSD (see /LICENSE or :doc:`Appendix B <LICENSE>`.)
:Date: 2012-09-09
:Version: 1.0.3

Expand Down
5 changes: 3 additions & 2 deletions docs/backends/backends.rst
@@ -1,8 +1,9 @@
========
Backends
========
:Author: Kwpolska
:Copyright: See Appendix B.
:Author: Kwpolska <kwpolska@kwpolska.tk>
:Copyright: © 2011-2012, Kwpolska.
:License: BSD (see /LICENSE or :doc:`Appendix B <LICENSE>`.)
:Date: 2012-08-25
:Version: 0.2.4

Expand Down
5 changes: 3 additions & 2 deletions docs/backends/dummytrash.rst
Expand Up @@ -3,11 +3,12 @@ DummyTrash
==========
:Name: DummyTrash
:Module: dummytrash
:Author: Kwpolska
:Author: Kwpolska <kwpolska@kwpolska.tk>
:Specification: n/a
:OS: any
:Description: A dummy backend, printing all the requests it gets.
:Copyright: See Appendix B.
:Copyright: © 2011-2012, Kwpolska.
:License: BSD (see /LICENSE or :doc:`Appendix B <LICENSE>`.)
:Date: 2012-08-25
:Version: 0.2.4

Expand Down
5 changes: 3 additions & 2 deletions docs/backends/xdgtrash.rst
Expand Up @@ -3,11 +3,12 @@ XDGTrash
=========
:Name: XDGTrash
:Module: xdgtrash
:Author: Kwpolska
:Author: Kwpolska <kwpolska@kwpolska.tk>
:Specification: XDG/freedesktop <http://freedesktop.org/wiki/Specifications/trash-spec>
:OS: Linux (KDE, GNOME, Xfce and others conforming to this spec)
:Description: An XDG trash implementation.
:Copyright: See Appendix B.
:Copyright: © 2011-2012, Kwpolska.
:License: BSD (see /LICENSE or :doc:`Appendix B <LICENSE>`.)
:Date: 2012-08-25
:Version: 0.2.4

Expand Down
5 changes: 3 additions & 2 deletions docs/functions.rst
@@ -1,8 +1,9 @@
=================================
Global Functions and Modules List
=================================
:Author: Kwpolska
:Copyright: See Appendix B.
:Author: Kwpolska <kwpolska@kwpolska.tk>
:Copyright: © 2011-2012, Kwpolska.
:License: BSD (see /LICENSE or :doc:`Appendix B <LICENSE>`.)
:Date: 2012-09-09
:Version: 1.0.3

Expand Down
5 changes: 3 additions & 2 deletions docs/localization.rst
@@ -1,8 +1,9 @@
==============================
Appendix A. Localization Guide
==============================
:Author: Kwpolska
:Copyright: See Appendix B.
:Author: Kwpolska <kwpolska@kwpolska.tk>
:Copyright: © 2011-2012, Kwpolska.
:License: BSD (see /LICENSE or :doc:`Appendix B <LICENSE>`.)
:Date: 2012-09-09
:Version: 1.0.3

Expand Down
3 changes: 2 additions & 1 deletion docs/trashman.rst
Expand Up @@ -3,7 +3,8 @@ Trashman
========

:Author: Kwpolska <kwpolska@kwpolska.tk>
:Copyright: See Appendix B.
:Copyright: © 2011-2012, Kwpolska.
:License: BSD (see /LICENSE or :doc:`Appendix B <LICENSE>`.)
:Date: 2012-09-09
:Version: 1.0.3
:Manual section: 1
Expand Down
15 changes: 15 additions & 0 deletions localegen
@@ -0,0 +1,15 @@
#!/bin/bash
project="trashman"
language=$1

xgettext -c ./$project/*.py ./$project/backends/*.py ./localeprovider.py -o ./messages.pot

podir="./locale/$language/LC_MESSAGES"
popath="./locale/$language/LC_MESSAGES/$project.po"
msgmerge $popath messages.pot -o $popath
fuzzy=$(cat $popath | grep -c '#, fuzzy')
empty=$(cat $popath | pcregrep -cM 'msgstr ""\n$')
echo "$fuzzy fuzzy strings"
echo "$empty empty strings"

msgfmt -o $podir/$project.mo $popath
8 changes: 4 additions & 4 deletions release
Expand Up @@ -74,13 +74,13 @@ for i in ./locale/*; do
msgmerge $popath messages.pot -o $popath
fuzzy=$(cat $popath | grep '#, fuzzy')
empty=$(cat $popath | pcregrep -M 'msgstr ""\n$')
countf=$(echo $fuzzy | wc -l)
counte=$(echo $empty | wc -l)
if [ countf != 0 ]; then
countf=$(echo -n $fuzzy | wc -l)
counte=$(echo -n $empty | wc -l)
if [ $countf != '0' ]; then
echo "WARNING: $countf fuzzy strings in language $language."
fi

if [ counte != 0 ]; then
if [ $counte != '0' ]; then
echo "WARNING: $counte empty strings in language $language."
fi

Expand Down

0 comments on commit 97b0da1

Please sign in to comment.