diff options
author | Pootle Translation <pootle@dev.laptop.org> | 2008-09-11 21:05:43 (GMT) |
---|---|---|
committer | Pootle Translation <pootle@dev.laptop.org> | 2008-09-11 21:05:43 (GMT) |
commit | b283d1c14ee84f9ec67338511933d344f7e240f4 (patch) | |
tree | 91a85cf7df80f50943730644ffe85c13bfc31641 | |
parent | 656dfa3d265103fd61bed7e2d58df4fdf3c84427 (diff) |
Undo last commits
-rw-r--r-- | Makefile.am | 13 | ||||
-rw-r--r-- | autogen.sh | 6 | ||||
-rw-r--r-- | configure.ac | 37 | ||||
-rw-r--r-- | maint-helper.py | 227 | ||||
-rw-r--r-- | po/af.po | 37 | ||||
-rw-r--r-- | po/en.po | 37 | ||||
-rw-r--r-- | po/pt_BR.po | 37 | ||||
-rw-r--r-- | po/ro.po | 37 | ||||
-rw-r--r-- | po/sd.po | 37 | ||||
-rw-r--r-- | po/sugar-base.pot | 37 | ||||
-rw-r--r-- | po/yo.po | 37 |
11 files changed, 542 insertions, 0 deletions
diff --git a/Makefile.am b/Makefile.am new file mode 100644 index 0000000..b62b8cc --- /dev/null +++ b/Makefile.am @@ -0,0 +1,13 @@ +ACLOCAL_AMFLAGS = -I m4 + +DISTCLEANFILES = \ + intltool-extract \ + intltool-merge \ + intltool-update + +EXTRA_DIST = \ + intltool-merge.in \ + intltool-update.in \ + intltool-extract.in + +SUBDIRS = src po diff --git a/autogen.sh b/autogen.sh new file mode 100644 index 0000000..3d12f8f --- /dev/null +++ b/autogen.sh @@ -0,0 +1,6 @@ +#!/bin/sh +export ACLOCAL="aclocal -I m4" + +intltoolize +autoreconf -i +./configure "$@" diff --git a/configure.ac b/configure.ac new file mode 100644 index 0000000..24323c6 --- /dev/null +++ b/configure.ac @@ -0,0 +1,37 @@ +AC_INIT([sugar-base],[0.82.1],[],[sugar-base]) + +AC_PREREQ([2.59]) + +AC_CONFIG_MACRO_DIR([m4]) +AC_CONFIG_SRCDIR([configure.ac]) + +AM_INIT_AUTOMAKE([1.9 foreign dist-bzip2 no-dist-gzip]) + +AC_DISABLE_STATIC +AC_PROG_LIBTOOL + +GNOME_COMPILE_WARNINGS(maximum) + +AM_PATH_PYTHON +AM_CHECK_PYTHON_HEADERS(,[AC_MSG_ERROR(could not find Python headers)]) + +AC_PATH_PROG(PYGTK_CODEGEN, pygtk-codegen-2.0, no) + +PKG_CHECK_MODULES(EXTENSION, pygobject-2.0) + +# Setup GETTEXT +# +ALL_LINGUAS="af am ar ay bg bn bn_IN ca de dz el en es fa fa_AF ff fr gu ha hi ht ig is it ja km ko mk ml mn mr mvo nb ne nl pa pap pis pl ps pt pt_BR qu ro ru rw sd si sl te th tpi tr ur vi yo zh_CN zh_TW" + +GETTEXT_PACKAGE=sugar-base +AC_PROG_INTLTOOL([0.33]) +AC_SUBST(GETTEXT_PACKAGE) +AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", [Gettext package]) +AM_GLIB_GNU_GETTEXT + +AC_OUTPUT([ +Makefile +src/Makefile +src/sugar/Makefile +po/Makefile.in +]) diff --git a/maint-helper.py b/maint-helper.py new file mode 100644 index 0000000..50f7d07 --- /dev/null +++ b/maint-helper.py @@ -0,0 +1,227 @@ +#!/usr/bin/env python + +# Copyright (C) 2007, Red Hat, Inc. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + +# Latest source available at git://dev.laptop.org/sugar + +import os +import sys +import re +import datetime +import subprocess + +source_exts = [ '.py', '.c', '.h', '.cpp' ] + +def is_source(path): + for ext in source_exts: + if path.endswith(ext): + return True + +def get_name_and_version(): + f = open('configure.ac', 'r') + config = f.read() + f.close() + + exp = 'AC_INIT\(\[[^\]]+\],\[([^\]]+)\],\[\],\[([^\]]+)\]' + match = re.search(exp, config) + if not match: + print 'Cannot find the package name and version.' + sys.exit(0) + + return [ match.group(2), match.group(1) ] + +def cmd_help(): + print 'Usage: \n\ +maint-helper.py build-snapshot - build a source snapshot \n\ +maint-helper.py fix-copyright [path] - fix the copyright year \n\ +maint-helper.py check-licenses - check licenses in the source' + +def cmd_build_snapshot(): + [ name, version ] = get_name_and_version() + + print 'Update git...' + + retcode = subprocess.call(['git', 'pull']) + if retcode: + print 'ERROR - cannot pull from git' + + cmd = 'git-show-ref --hash=10 refs/heads/master' + alphatag = os.popen(cmd).readline().strip() + + tarball = '%s-%s-git%s.tar.bz2' % (name, version, alphatag) + + print 'Build %s...' % tarball + + retcode = subprocess.call(['make', 'distcheck']) + if retcode: + sys.exit(0) + + if 'JOYBUILD_PATH' in os.environ: + tarball = os.path.join(os.environ['JOYBUILD_PATH'], 'source', tarball) + os.rename('%s-%s.tar.bz2' % (name, version), tarball) + + print 'Update NEWS.sugar...' + + if os.environ.has_key('SUGAR_NEWS'): + sugar_news_path = os.environ['SUGAR_NEWS'] + if os.path.isfile(sugar_news_path): + f = open(sugar_news_path, 'r') + sugar_news = f.read() + f.close() + else: + sugar_news = '' + + [ name, version ] = get_name_and_version() + sugar_news += '%s - %s - %s\n\n' % (name, version, alphatag) + + f = open('NEWS', 'r') + for line in f.readlines(): + if len(line.strip()) > 0: + sugar_news += line + else: + break + f.close() + + f = open(sugar_news_path, 'w') + f.write(sugar_news) + f.close() + + print 'Update NEWS...' + + f = open('NEWS', 'r') + news = f.read() + f.close() + + news = 'Snapshot %s\n\n' % alphatag + news + + f = open('NEWS', 'w') + f.write(news) + f.close() + + print 'Committing to git...' + + changelog = 'Snapshot %s.' % alphatag + retcode = subprocess.call(['git', 'commit', '-a', '-m % s' % changelog]) + if retcode: + print 'ERROR - cannot commit to git' + + retcode = subprocess.call(['git', 'push']) + if retcode: + print 'ERROR - cannot push to git' + + print 'Done.' + +def check_licenses(path, license, missing): + matchers = { 'LGPL' : 'GNU Lesser General Public', + 'GPL' : 'GNU General Public License' } + + license_file = os.path.join(path, '.license') + if os.path.isfile(license_file): + f = open(license_file, 'r') + license = f.readline().strip() + f.close() + + for item in os.listdir(path): + full_path = os.path.join(path, item) + + if os.path.isdir(full_path): + check_licenses(full_path, license, missing) + else: + check_source = is_source(item) + + # Special cases. + if item.find('marshal') > 0 or \ + item.startswith('egg') > 0: + check_source = False + + if check_source: + f = open(full_path, 'r') + source = f.read() + f.close() + + miss_license = True + if source.find(matchers[license]) > 0: + miss_license = False + + # Special cases. + if source.find('THIS FILE IS GENERATED') > 0: + miss_license = False + + if miss_license: + if not missing.has_key(license): + missing[license] = [] + missing[license].append(full_path) + +def cmd_check_licenses(): + missing = {} + check_licenses(os.getcwd(), 'LGPL', missing) + + for item in missing.keys(): + print '%s:\n' % item + for path in missing[item]: + print path + print '\n' + +COPYRIGHT = 'Copyright (C) ' + +def fix_copyright(path): + for item in os.listdir(path): + full_path = os.path.join(path, item) + + if os.path.isdir(full_path): + fix_copyright(full_path) + elif is_source(item): + f = open(full_path, 'r') + source = f.read() + f.close() + + year_start = -1 + year_end = -1 + + i1 = source.find(COPYRIGHT) + if i1 != -1: + i1 += len(COPYRIGHT) + i2 = i1 + source[i1:].find(' ') + if i1 > 0: + try: + year_start = int(source[i1:i1 + 4]) + year_end = int(source[i1 + 6: i1 + 10]) + except ValueError: + pass + + if year_start > 0 and year_end < 0: + year_end = year_start + + year = datetime.date.today().year + if year_end < year: + result = '%s%d-%d%s' % (source[:i1], year_start, + year, source[i2:]) + f = open(full_path, 'w') + f.write(result) + f.close() + +def cmd_fix_copyright(path): + fix_copyright(path) + +if len(sys.argv) < 2: + cmd_help() +elif sys.argv[1] == 'build-snapshot': + cmd_build_snapshot() +elif sys.argv[1] == 'check-licenses': + cmd_check_licenses() +elif sys.argv[1] == 'fix-copyright' and len(sys.argv) > 2: + cmd_fix_copyright(sys.argv[2]) diff --git a/po/af.po b/po/af.po new file mode 100644 index 0000000..c3145a6 --- /dev/null +++ b/po/af.po @@ -0,0 +1,37 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2008-06-24 00:21+0530\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" +"Language-Team: LANGUAGE <LL@li.org>\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: Translate Toolkit 1.1.1rc4\n" + +#: ../src/sugar/mime.py:29 +msgid "Text" +msgstr "" + +#: ../src/sugar/mime.py:37 +msgid "Image" +msgstr "" + +#: ../src/sugar/mime.py:42 +msgid "Audio" +msgstr "" + +#: ../src/sugar/mime.py:47 +msgid "Video" +msgstr "" + +#: ../src/sugar/mime.py:52 +msgid "Link" +msgstr "" diff --git a/po/en.po b/po/en.po new file mode 100644 index 0000000..c3145a6 --- /dev/null +++ b/po/en.po @@ -0,0 +1,37 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2008-06-24 00:21+0530\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" +"Language-Team: LANGUAGE <LL@li.org>\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: Translate Toolkit 1.1.1rc4\n" + +#: ../src/sugar/mime.py:29 +msgid "Text" +msgstr "" + +#: ../src/sugar/mime.py:37 +msgid "Image" +msgstr "" + +#: ../src/sugar/mime.py:42 +msgid "Audio" +msgstr "" + +#: ../src/sugar/mime.py:47 +msgid "Video" +msgstr "" + +#: ../src/sugar/mime.py:52 +msgid "Link" +msgstr "" diff --git a/po/pt_BR.po b/po/pt_BR.po new file mode 100644 index 0000000..c3145a6 --- /dev/null +++ b/po/pt_BR.po @@ -0,0 +1,37 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2008-06-24 00:21+0530\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" +"Language-Team: LANGUAGE <LL@li.org>\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: Translate Toolkit 1.1.1rc4\n" + +#: ../src/sugar/mime.py:29 +msgid "Text" +msgstr "" + +#: ../src/sugar/mime.py:37 +msgid "Image" +msgstr "" + +#: ../src/sugar/mime.py:42 +msgid "Audio" +msgstr "" + +#: ../src/sugar/mime.py:47 +msgid "Video" +msgstr "" + +#: ../src/sugar/mime.py:52 +msgid "Link" +msgstr "" diff --git a/po/ro.po b/po/ro.po new file mode 100644 index 0000000..c3145a6 --- /dev/null +++ b/po/ro.po @@ -0,0 +1,37 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2008-06-24 00:21+0530\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" +"Language-Team: LANGUAGE <LL@li.org>\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: Translate Toolkit 1.1.1rc4\n" + +#: ../src/sugar/mime.py:29 +msgid "Text" +msgstr "" + +#: ../src/sugar/mime.py:37 +msgid "Image" +msgstr "" + +#: ../src/sugar/mime.py:42 +msgid "Audio" +msgstr "" + +#: ../src/sugar/mime.py:47 +msgid "Video" +msgstr "" + +#: ../src/sugar/mime.py:52 +msgid "Link" +msgstr "" diff --git a/po/sd.po b/po/sd.po new file mode 100644 index 0000000..c3145a6 --- /dev/null +++ b/po/sd.po @@ -0,0 +1,37 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2008-06-24 00:21+0530\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" +"Language-Team: LANGUAGE <LL@li.org>\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: Translate Toolkit 1.1.1rc4\n" + +#: ../src/sugar/mime.py:29 +msgid "Text" +msgstr "" + +#: ../src/sugar/mime.py:37 +msgid "Image" +msgstr "" + +#: ../src/sugar/mime.py:42 +msgid "Audio" +msgstr "" + +#: ../src/sugar/mime.py:47 +msgid "Video" +msgstr "" + +#: ../src/sugar/mime.py:52 +msgid "Link" +msgstr "" diff --git a/po/sugar-base.pot b/po/sugar-base.pot new file mode 100644 index 0000000..21c2ab1 --- /dev/null +++ b/po/sugar-base.pot @@ -0,0 +1,37 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. +# +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2008-06-24 00:21+0530\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" +"Language-Team: LANGUAGE <LL@li.org>\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=CHARSET\n" +"Content-Transfer-Encoding: 8bit\n" + +#: ../src/sugar/mime.py:29 +msgid "Text" +msgstr "" + +#: ../src/sugar/mime.py:37 +msgid "Image" +msgstr "" + +#: ../src/sugar/mime.py:42 +msgid "Audio" +msgstr "" + +#: ../src/sugar/mime.py:47 +msgid "Video" +msgstr "" + +#: ../src/sugar/mime.py:52 +msgid "Link" +msgstr "" diff --git a/po/yo.po b/po/yo.po new file mode 100644 index 0000000..c3145a6 --- /dev/null +++ b/po/yo.po @@ -0,0 +1,37 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2008-06-24 00:21+0530\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" +"Language-Team: LANGUAGE <LL@li.org>\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: Translate Toolkit 1.1.1rc4\n" + +#: ../src/sugar/mime.py:29 +msgid "Text" +msgstr "" + +#: ../src/sugar/mime.py:37 +msgid "Image" +msgstr "" + +#: ../src/sugar/mime.py:42 +msgid "Audio" +msgstr "" + +#: ../src/sugar/mime.py:47 +msgid "Video" +msgstr "" + +#: ../src/sugar/mime.py:52 +msgid "Link" +msgstr "" |