From: Armin Ronacher Date: Wed, 24 Jul 2013 13:09:42 +0000 (+0200) Subject: License clarification and cleanup X-Git-Tag: 1.0~46 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=59f02c9ecda9fabe5b96f9ec994d7cc7e45f56ad;p=thirdparty%2Fbabel.git License clarification and cleanup --- diff --git a/AUTHORS b/AUTHORS index 36639776..09d0bc03 100644 --- a/AUTHORS +++ b/AUTHORS @@ -17,7 +17,12 @@ Contributors: - Daniel Neuhäuser - Nick Retallack - Thomas Waldmann +- Lennart Regebro Babel was previously developed under the Copyright of Edgewall Software. The following copyright notice holds true for releases before 2013: "Copyright (c) 2007 - 2011 by Edgewall Software" + +In addition to the regular contributions Babel includes a fork of Lennart +Regebro's tzlocal that originally was licensed under the CC0 license. The +original copyright of that project is "Copyright 2013 by Lennart Regebro". diff --git a/babel/__init__.py b/babel/__init__.py index ae7d6ca9..fa5d59af 100644 --- a/babel/__init__.py +++ b/babel/__init__.py @@ -1,29 +1,20 @@ # -*- coding: utf-8 -*- -# -# Copyright (C) 2007-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. +""" + babel + ~~~~~ -"""Integrated collection of utilities that assist in internationalizing and -localizing applications. + Integrated collection of utilities that assist in internationalizing and + localizing applications. -This package is basically composed of two major parts: + This package is basically composed of two major parts: - * tools to build and work with ``gettext`` message catalogs - * a Python interface to the CLDR (Common Locale Data Repository), providing - access to various locale display names, localized number and date - formatting, etc. + * tools to build and work with ``gettext`` message catalogs + * a Python interface to the CLDR (Common Locale Data Repository), providing + access to various locale display names, localized number and date + formatting, etc. -:see: http://www.gnu.org/software/gettext/ -:see: http://docs.python.org/lib/module-gettext.html -:see: http://www.unicode.org/cldr/ + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. """ from babel.core import UnknownLocaleError, Locale, default_locale, \ diff --git a/babel/_compat.py b/babel/_compat.py index 1f7f91bc..86096daa 100644 --- a/babel/_compat.py +++ b/babel/_compat.py @@ -1,17 +1,3 @@ -# -*- coding: utf-8 -*- -# -# Copyright (C) 2007-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. - - import sys PY2 = sys.version_info[0] == 2 diff --git a/babel/core.py b/babel/core.py index 034c35b1..d22ccaa1 100644 --- a/babel/core.py +++ b/babel/core.py @@ -1,17 +1,13 @@ # -*- coding: utf-8 -*- -# -# Copyright (C) 2007-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. - -"""Core locale representation and locale data access.""" +""" + babel.core + ~~~~~~~~~~ + + Core locale representation and locale data access. + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. +""" import os diff --git a/babel/dates.py b/babel/dates.py index 996fecd1..c15015af 100644 --- a/babel/dates.py +++ b/babel/dates.py @@ -1,24 +1,19 @@ # -*- coding: utf-8 -*- -# -# Copyright (C) 2007-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. - -"""Locale dependent formatting and parsing of dates and times. - -The default locale for the functions in this module is determined by the -following environment variables, in that order: - - * ``LC_TIME``, - * ``LC_ALL``, and - * ``LANG`` +""" + babel.dates + ~~~~~~~~~~~ + + Locale dependent formatting and parsing of dates and times. + + The default locale for the functions in this module is determined by the + following environment variables, in that order: + + * ``LC_TIME``, + * ``LC_ALL``, and + * ``LANG`` + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. """ from __future__ import division diff --git a/babel/localedata.py b/babel/localedata.py index d6e47039..e05b6a94 100644 --- a/babel/localedata.py +++ b/babel/localedata.py @@ -1,20 +1,15 @@ # -*- coding: utf-8 -*- -# -# Copyright (C) 2007-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. - -"""Low-level locale data access. - -:note: The `Locale` class, which uses this module under the hood, provides a - more convenient interface for accessing the locale data. +""" + babel.localedata + ~~~~~~~~~~~~~~~~ + + Low-level locale data access. + + :note: The `Locale` class, which uses this module under the hood, provides a + more convenient interface for accessing the locale data. + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. """ import os diff --git a/babel/localtime/__init__.py b/babel/localtime/__init__.py index 842a03ef..cdb3e9b5 100644 --- a/babel/localtime/__init__.py +++ b/babel/localtime/__init__.py @@ -1,3 +1,15 @@ +# -*- coding: utf-8 -*- +""" + babel.localtime + ~~~~~~~~~~~~~~~ + + Babel specific fork of tzlocal to determine the local timezone + of the system. + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. +""" + import sys import pytz import time diff --git a/babel/messages/__init__.py b/babel/messages/__init__.py index 8110724c..1b63bae2 100644 --- a/babel/messages/__init__.py +++ b/babel/messages/__init__.py @@ -1,16 +1,12 @@ # -*- coding: utf-8 -*- -# -# Copyright (C) 2007-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. +""" + babel.messages + ~~~~~~~~~~~~~~ -"""Support for ``gettext`` message catalogs.""" + Support for ``gettext`` message catalogs. + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. +""" from babel.messages.catalog import * diff --git a/babel/messages/catalog.py b/babel/messages/catalog.py index 4f3afcb0..e187acbd 100644 --- a/babel/messages/catalog.py +++ b/babel/messages/catalog.py @@ -1,17 +1,13 @@ # -*- coding: utf-8 -*- -# -# Copyright (C) 2007-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. - -"""Data structures for message catalogs.""" +""" + babel.messages.catalog + ~~~~~~~~~~~~~~~~~~~~~~ + + Data structures for message catalogs. + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. +""" from cgi import parse_header from datetime import datetime, time as time_ diff --git a/babel/messages/checkers.py b/babel/messages/checkers.py index fe8ab3a5..de46e995 100644 --- a/babel/messages/checkers.py +++ b/babel/messages/checkers.py @@ -1,19 +1,14 @@ # -*- coding: utf-8 -*- -# -# Copyright (C) 2007-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. - -"""Various routines that help with validation of translations. - -:since: version 0.9 +""" + babel.messages.checkers + ~~~~~~~~~~~~~~~~~~~~~~~ + + Various routines that help with validation of translations. + + :since: version 0.9 + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. """ from babel.messages.catalog import TranslationError, PYTHON_FORMAT diff --git a/babel/messages/extract.py b/babel/messages/extract.py index 1e99ce26..201ebd2a 100644 --- a/babel/messages/extract.py +++ b/babel/messages/extract.py @@ -1,24 +1,20 @@ # -*- coding: utf-8 -*- -# -# Copyright (C) 2007-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. - -"""Basic infrastructure for extracting localizable messages from source files. - -This module defines an extensible system for collecting localizable message -strings from a variety of sources. A native extractor for Python source files -is builtin, extractors for other sources can be added using very simple plugins. - -The main entry points into the extraction functionality are the functions -`extract_from_dir` and `extract_from_file`. +""" + babel.messages.extract + ~~~~~~~~~~~~~~~~~~~~~~ + + Basic infrastructure for extracting localizable messages from source files. + + This module defines an extensible system for collecting localizable message + strings from a variety of sources. A native extractor for Python source + files is builtin, extractors for other sources can be added using very + simple plugins. + + The main entry points into the extraction functionality are the functions + `extract_from_dir` and `extract_from_file`. + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. """ import os diff --git a/babel/messages/frontend.py b/babel/messages/frontend.py index 8bd636b9..a15b5aab 100755 --- a/babel/messages/frontend.py +++ b/babel/messages/frontend.py @@ -1,18 +1,13 @@ -#!/usr/bin/env python # -*- coding: utf-8 -*- -# -# Copyright (C) 2007-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. - -"""Frontends for the message extraction functionality.""" +""" + babel.messages.frontend + ~~~~~~~~~~~~~~~~~~~~~~~ + + Frontends for the message extraction functionality. + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. +""" try: from ConfigParser import RawConfigParser diff --git a/babel/messages/jslexer.py b/babel/messages/jslexer.py index 08493d31..d49687be 100644 --- a/babel/messages/jslexer.py +++ b/babel/messages/jslexer.py @@ -1,18 +1,13 @@ # -*- coding: utf-8 -*- -# -# Copyright (C) 2008-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. - -"""A simple JavaScript 1.5 lexer which is used for the JavaScript -extractor. +""" + babel.messages.jslexer + ~~~~~~~~~~~~~~~~~~~~~~ + + A simple JavaScript 1.5 lexer which is used for the JavaScript + extractor. + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. """ from operator import itemgetter diff --git a/babel/messages/mofile.py b/babel/messages/mofile.py index f355c732..c92cbad9 100644 --- a/babel/messages/mofile.py +++ b/babel/messages/mofile.py @@ -1,21 +1,12 @@ # -*- coding: utf-8 -*- -# -# Copyright (C) 2007-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. - -"""Writing of files in the ``gettext`` MO (machine object) format. - -:since: version 0.9 -:see: `The Format of MO Files - `_ +""" + babel.messages.mofile + ~~~~~~~~~~~~~~~~~~~~~ + + Writing of files in the ``gettext`` MO (machine object) format. + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. """ import array diff --git a/babel/messages/plurals.py b/babel/messages/plurals.py index 172339e6..9b4b4ac2 100644 --- a/babel/messages/plurals.py +++ b/babel/messages/plurals.py @@ -1,17 +1,13 @@ # -*- coding: utf-8 -*- -# -# Copyright (C) 2007-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. - -"""Plural form definitions.""" +""" + babel.messages.plurals + ~~~~~~~~~~~~~~~~~~~~~~ + + Plural form definitions. + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. +""" from babel.core import default_locale, Locale from operator import itemgetter diff --git a/babel/messages/pofile.py b/babel/messages/pofile.py index 5d0d96cd..6c9c6f9f 100644 --- a/babel/messages/pofile.py +++ b/babel/messages/pofile.py @@ -1,21 +1,13 @@ # -*- coding: utf-8 -*- -# -# Copyright (C) 2007-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. - -"""Reading and writing of files in the ``gettext`` PO (portable object) -format. - -:see: `The Format of PO Files - `_ +""" + babel.messages.pofile + ~~~~~~~~~~~~~~~~~~~~~ + + Reading and writing of files in the ``gettext`` PO (portable object) + format. + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. """ import os diff --git a/babel/numbers.py b/babel/numbers.py index f792e7e5..8d159784 100644 --- a/babel/numbers.py +++ b/babel/numbers.py @@ -1,24 +1,19 @@ # -*- coding: utf-8 -*- -# -# Copyright (C) 2007-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. - -"""Locale dependent formatting and parsing of numeric data. - -The default locale for the functions in this module is determined by the -following environment variables, in that order: - - * ``LC_NUMERIC``, - * ``LC_ALL``, and - * ``LANG`` +""" + babel.numbers + ~~~~~~~~~~~~~ + + Locale dependent formatting and parsing of numeric data. + + The default locale for the functions in this module is determined by the + following environment variables, in that order: + + * ``LC_NUMERIC``, + * ``LC_ALL``, and + * ``LANG`` + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. """ # TODO: # Padding and rounding increments in pattern: diff --git a/babel/plural.py b/babel/plural.py index afc6d1e1..6f160538 100644 --- a/babel/plural.py +++ b/babel/plural.py @@ -1,17 +1,13 @@ # -*- coding: utf-8 -*- -# -# Copyright (C) 2008-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. - -"""CLDR Plural support. See UTS #35. EXPERIMENTAL""" +""" + babel.numbers + ~~~~~~~~~~~~~ + + CLDR Plural support. See UTS #35. + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. +""" import re @@ -19,7 +15,6 @@ __all__ = ['PluralRule', 'RuleError', 'to_gettext', 'to_javascript', 'to_python'] - _plural_tags = ('zero', 'one', 'two', 'few', 'many', 'other') _fallback_tag = 'other' diff --git a/babel/support.py b/babel/support.py index 8e4f40fd..27f0897c 100644 --- a/babel/support.py +++ b/babel/support.py @@ -1,20 +1,15 @@ # -*- coding: utf-8 -*- -# -# Copyright (C) 2007-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. - -"""Several classes and functions that help with integrating and using Babel -in applications. - -.. note: the code in this module is not used by Babel itself +""" + babel.support + ~~~~~~~~~~~~~ + + Several classes and functions that help with integrating and using Babel + in applications. + + .. note: the code in this module is not used by Babel itself + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. """ import gettext @@ -30,7 +25,6 @@ from babel._compat import PY2, text_type, text_to_native __all__ = ['Format', 'LazyProxy', 'NullTranslations', 'Translations'] - class Format(object): """Wrapper class providing the various date and number formatting functions bound to a specific locale and time-zone. diff --git a/babel/util.py b/babel/util.py index e5e7e7b6..230c261d 100644 --- a/babel/util.py +++ b/babel/util.py @@ -1,17 +1,13 @@ # -*- coding: utf-8 -*- -# -# Copyright (C) 2007-2011 Edgewall Software -# All rights reserved. -# -# This software is licensed as described in the file COPYING, which -# you should have received as part of this distribution. The terms -# are also available at http://babel.edgewall.org/wiki/License. -# -# This software consists of voluntary contributions made by many -# individuals. For the exact contribution history, see the revision -# history and logs, available at http://babel.edgewall.org/log/. - -"""Various utility classes and functions.""" +""" + babel.util + ~~~~~~~~~~ + + Various utility classes and functions. + + :copyright: (c) 2013 by the Babel Team. + :license: BSD, see LICENSE for more details. +""" import codecs from datetime import timedelta, tzinfo @@ -26,7 +22,6 @@ __all__ = ['distinct', 'pathmatch', 'relpath', 'wraptext', 'odict', 'UTC', 'LOCALTZ'] - def distinct(iterable): """Yield all items in an iterable collection that are distinct.