i18n-inflector 1.0.0 → 1.0.10

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,32 @@
1
+ # encoding: utf-8
2
+
3
+ lib = File.expand_path('../../lib/', __FILE__)
4
+ $:.unshift lib unless $:.include?(lib)
5
+ require 'i18n-inflector/version'
6
+
7
+ Gem::Specification.new do |s|
8
+ s.name = I18n::Inflector::NAME
9
+ s.version = I18n::Inflector::VERSION
10
+ s.authors = [I18n::Inflector::DEVELOPER]
11
+ s.email = I18n::Inflector::EMAIL
12
+ s.homepage = I18n::Inflector::URL
13
+ s.summary = I18n::Inflector::SUMMARY
14
+ s.description = I18n::Inflector::DESCRIPTION
15
+
16
+ s.files = Dir.glob("{ci,lib,spec,docs}/**/**") + %w(Gemfile .rspec .yardopts README.rdoc LGPL-LICENSE ChangeLog Manifest.txt)
17
+ s.extra_rdoc_files = ["README.rdoc", "docs/TODO", "docs/HISTORY", "docs/LGPL-LICENSE", "docs/COPYING"]
18
+ s.rdoc_options = ["--main", "README.rdoc"]
19
+ s.platform = Gem::Platform::RUBY
20
+ s.require_path = 'lib'
21
+ s.rubyforge_project = '[none]'
22
+ s.required_rubygems_version = '>= 1.3.5'
23
+ s.specification_version = 3
24
+
25
+ s.add_dependency 'i18n', '>= 0.5.0'
26
+ s.add_development_dependency 'test_declarative', '>= 0.0.4'
27
+ s.add_development_dependency 'rspec', '>= 2.3.0'
28
+ s.add_development_dependency 'yard', '>= 1.0.7'
29
+ s.add_development_dependency 'hoe-yard', '>= 0.1.2'
30
+ s.add_development_dependency 'hoe-bundler', '>= 1.0.0'
31
+
32
+ end
data/docs/COPYING CHANGED
@@ -1,61 +1,57 @@
1
- i18n-inflector is copyrighted free software owned by Paweł Wilk
2
- (pw@gnu.org). The Owner of this software permits you to
3
- redistribute and/or modify the software under either the terms of the LGPL
4
- version 3 (see the file {LGPL-LICENSE}[link:docs/LGPL-LICENSE.html]),
5
- or the conditions below ("Ruby License"):
1
+ i18n-inflector is copyrighted free software owned by Paweł Wilk (pw@gnu.org). The Owner of this software permits you to redistribute and/or modify the software under either the terms of the LGPL version 3 (see the file {file:LGPL-LICENSE LGPL-LICENSE}), or the conditions below ("Ruby License").
6
2
 
7
- 1. You may make and give away verbatim copies of the source form of this
8
- software without restriction, provided that you retain ALL of the
9
- original copyright notices and associated disclaimers.
3
+ == 1.
10
4
 
11
- 2. You may modify your copy of the software in any way, provided that
12
- you do at least ONE of the following:
5
+ You may make and give away verbatim copies of the source form of this software without restriction, provided that you retain ALL of the
6
+ original copyright notices and associated disclaimers.
13
7
 
14
- a) place your modifications in the Public Domain or otherwise
15
- make them Freely Available, such as by posting said
16
- modifications to Usenet or an equivalent medium, or by allowing
17
- the author to include your modifications in the software.
8
+ == 2.
18
9
 
19
- b) use the modified software only within your corporation or
20
- organization.
10
+ You may modify your copy of the software in any way, provided that you do at least ONE of the following:
21
11
 
22
- c) give non-standard binaries non-standard names, with
23
- instructions on where to get the original software distribution.
12
+ a) place your modifications in the Public Domain or otherwise make them Freely Available, such as by posting said
13
+ modifications to Usenet or an equivalent medium, or by allowing
14
+ the author to include your modifications in the software.
24
15
 
25
- d) make other distribution arrangements with the Owner.
16
+ b) use the modified software only within your corporation or
17
+ organization.
26
18
 
27
- 3. You may distribute the software in object code or binary form,
28
- provided that you do at least ONE of the following:
19
+ c) give non-standard binaries non-standard names, with
20
+ instructions on where to get the original software distribution.
29
21
 
30
- a) distribute the binaries and library files of the software,
31
- together with instructions (in a manual page or equivalent)
32
- on where to get the original distribution.
22
+ d) make other distribution arrangements with the Owner.
33
23
 
34
- b) accompany the distribution with the machine-readable source of
35
- the software.
24
+ == 3.
36
25
 
37
- c) give non-standard binaries non-standard names, with
38
- instructions on where to get the original software distribution.
26
+ You may distribute the software in object code or binary form, provided that you do at least ONE of the following:
39
27
 
40
- d) make other distribution arrangements with the Owner.
28
+ a) distribute the binaries and library files of the software,
29
+ together with instructions (in a manual page or equivalent)
30
+ on where to get the original distribution.
41
31
 
42
- 4. You may modify and include parts of the software into any other
43
- software (possibly commercial), provided you comply with the terms in
44
- Sections 1, 2, and 3 above. But some files in the distribution
45
- are not written by the Owner, so they may be made available to you
46
- under different terms.
32
+ b) accompany the distribution with the machine-readable source of
33
+ the software.
47
34
 
48
- For the list of those files and their copying conditions, see the
49
- file LEGAL.
35
+ c) give non-standard binaries non-standard names, with
36
+ instructions on where to get the original software distribution.
50
37
 
51
- 5. The scripts and library files supplied as input to or produced as
52
- output from the software do not automatically fall under the
53
- copyright of the software, but belong to whoever generated them,
54
- and may be sold commercially, and may be aggregated with this
55
- software.
38
+ d) make other distribution arrangements with the Owner.
56
39
 
57
- 6. THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR
58
- IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
59
- WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
60
- PURPOSE.
40
+ == 4.
41
+
42
+ You may modify and include parts of the software into any other software (possibly commercial), provided you comply with the terms in
43
+ Sections 1, 2, and 3 above. But some files in the distribution are not written by the Owner, so they may be made available to you
44
+ under different terms.
45
+
46
+ For the list of those files and their copying conditions, see the
47
+ file LEGAL.
48
+
49
+ == 5.
50
+
51
+ The scripts and library files supplied as input to or produced as output from the software do not automatically fall under the
52
+ copyright of the software, but belong to whoever generated them, and may be sold commercially, and may be aggregated with this software.
53
+
54
+ == 6.
55
+
56
+ THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
61
57
 
data/docs/HISTORY CHANGED
@@ -1,3 +1,65 @@
1
+ === 1.0.10 / 2011-01-10
2
+
3
+ * major bugfixes
4
+
5
+ * Removed cause of infinite loops while initializing translations
6
+ * Disabled lookup from being used before translations are initialized
7
+ * Fixed initialization routine (dangerous typo when setting booleans)
8
+
9
+ * minor enhancements
10
+
11
+ * Switched to lazy loading of inflection data for certain locales
12
+
13
+ === 1.0.8 / 2011-01-08
14
+
15
+ * major enhancements
16
+
17
+ * Enabled escaping of patterns using @@{pattern} or \@{pattern}
18
+
19
+ === 1.0.7 / 2011-01-07
20
+
21
+ * major bugfixes
22
+
23
+ * Fixed interpolation when a translated string begins with a pattern
24
+
25
+ === 1.0.6 / 2010-12-30
26
+
27
+ * minor enhancements
28
+
29
+ * Added API method inflection_kind(token)
30
+ * Added API method inflection_true_token(token)
31
+ * Added API method inflected_locale(locale)
32
+
33
+ === 1.0.5 / 2010-12-29
34
+
35
+ * major enhancements
36
+
37
+ * Compatible with i18n >= 0.4.1
38
+
39
+ === 1.0.4 / 2010-12-27
40
+
41
+ * minor enhancements
42
+
43
+ * Documentation updated
44
+
45
+ === 1.0.3 / 2010-12-25
46
+
47
+ * major enhancements
48
+
49
+ * YARD documentation updated with metatags
50
+
51
+ * minor enhancements
52
+
53
+ * Some changes in accessors for interpolation switches
54
+
55
+ === 1.0.2 / 2010-12-22
56
+
57
+ * minor enhancements
58
+
59
+ * Switched to YARD documentation
60
+ * Tests simplified
61
+ * Depandencies simplified
62
+
1
63
  === 1.0.0 / 2010-12-22
2
64
 
3
65
  * 1 major enhancement
data/docs/LEGAL CHANGED
@@ -1,11 +1,11 @@
1
1
  LEGAL NOTICE INFORMATION
2
2
  ------------------------
3
3
 
4
- i18n-inflector is Copyright (C) 2010 by Paweł Wilk.
4
+ i18n-inflector is Copyright (C) 2011 by Paweł Wilk.
5
5
 
6
6
  i18n-inflector is copyrighted software owned by Paweł Wilk
7
7
  (pw@gnu.org). You may redistribute and/or modify this
8
8
  software as long as you comply with either the terms of the LGPL
9
- (see the file {LGPL-LICENSE}[link:docs/LGPL-LICENSE.html]),
10
- or Ruby's license (see the file {COPYING}[link:docs/COPYING.html]).
9
+ (see the file {file:LGPL-LICENSE}),
10
+ or Ruby's license (see the file {file:COPYING}).
11
11
 
data/docs/LGPL-LICENSE CHANGED
@@ -1,169 +1,166 @@
1
- <tt>
2
-
3
- GNU LESSER GENERAL PUBLIC LICENSE
4
- Version 3, 29 June 2007
5
-
6
- Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
7
- Everyone is permitted to copy and distribute verbatim copies
8
- of this license document, but changing it is not allowed.
9
-
10
-
11
- This version of the GNU Lesser General Public License incorporates
12
- the terms and conditions of version 3 of the GNU General Public
13
- License, supplemented by the additional permissions listed below.
14
-
15
- 0. Additional Definitions.
16
-
17
- As used herein, "this License" refers to version 3 of the GNU Lesser
18
- General Public License, and the "GNU GPL" refers to version 3 of the GNU
19
- General Public License.
20
-
21
- "The Library" refers to a covered work governed by this License,
22
- other than an Application or a Combined Work as defined below.
23
-
24
- An "Application" is any work that makes use of an interface provided
25
- by the Library, but which is not otherwise based on the Library.
26
- Defining a subclass of a class defined by the Library is deemed a mode
27
- of using an interface provided by the Library.
28
-
29
- A "Combined Work" is a work produced by combining or linking an
30
- Application with the Library. The particular version of the Library
31
- with which the Combined Work was made is also called the "Linked
32
- Version".
33
-
34
- The "Minimal Corresponding Source" for a Combined Work means the
35
- Corresponding Source for the Combined Work, excluding any source code
36
- for portions of the Combined Work that, considered in isolation, are
37
- based on the Application, and not on the Linked Version.
38
-
39
- The "Corresponding Application Code" for a Combined Work means the
40
- object code and/or source code for the Application, including any data
41
- and utility programs needed for reproducing the Combined Work from the
42
- Application, but excluding the System Libraries of the Combined Work.
43
-
44
- 1. Exception to Section 3 of the GNU GPL.
45
-
46
- You may convey a covered work under sections 3 and 4 of this License
47
- without being bound by section 3 of the GNU GPL.
48
-
49
- 2. Conveying Modified Versions.
50
-
51
- If you modify a copy of the Library, and, in your modifications, a
52
- facility refers to a function or data to be supplied by an Application
53
- that uses the facility (other than as an argument passed when the
54
- facility is invoked), then you may convey a copy of the modified
55
- version:
56
-
57
- a) under this License, provided that you make a good faith effort to
58
- ensure that, in the event an Application does not supply the
59
- function or data, the facility still operates, and performs
60
- whatever part of its purpose remains meaningful, or
61
-
62
- b) under the GNU GPL, with none of the additional permissions of
63
- this License applicable to that copy.
64
-
65
- 3. Object Code Incorporating Material from Library Header Files.
66
-
67
- The object code form of an Application may incorporate material from
68
- a header file that is part of the Library. You may convey such object
69
- code under terms of your choice, provided that, if the incorporated
70
- material is not limited to numerical parameters, data structure
71
- layouts and accessors, or small macros, inline functions and templates
72
- (ten or fewer lines in length), you do both of the following:
73
-
74
- a) Give prominent notice with each copy of the object code that the
75
- Library is used in it and that the Library and its use are
76
- covered by this License.
77
-
78
- b) Accompany the object code with a copy of the GNU GPL and this license
79
- document.
80
-
81
- 4. Combined Works.
82
-
83
- You may convey a Combined Work under terms of your choice that,
84
- taken together, effectively do not restrict modification of the
85
- portions of the Library contained in the Combined Work and reverse
86
- engineering for debugging such modifications, if you also do each of
87
- the following:
88
-
89
- a) Give prominent notice with each copy of the Combined Work that
90
- the Library is used in it and that the Library and its use are
91
- covered by this License.
92
-
93
- b) Accompany the Combined Work with a copy of the GNU GPL and this license
94
- document.
95
-
96
- c) For a Combined Work that displays copyright notices during
97
- execution, include the copyright notice for the Library among
98
- these notices, as well as a reference directing the user to the
99
- copies of the GNU GPL and this license document.
100
-
101
- d) Do one of the following:
102
-
103
- 0) Convey the Minimal Corresponding Source under the terms of this
104
- License, and the Corresponding Application Code in a form
105
- suitable for, and under terms that permit, the user to
106
- recombine or relink the Application with a modified version of
107
- the Linked Version to produce a modified Combined Work, in the
108
- manner specified by section 6 of the GNU GPL for conveying
109
- Corresponding Source.
110
-
111
- 1) Use a suitable shared library mechanism for linking with the
112
- Library. A suitable mechanism is one that (a) uses at run time
113
- a copy of the Library already present on the user's computer
114
- system, and (b) will operate properly with a modified version
115
- of the Library that is interface-compatible with the Linked
116
- Version.
117
-
118
- e) Provide Installation Information, but only if you would otherwise
119
- be required to provide such information under section 6 of the
120
- GNU GPL, and only to the extent that such information is
121
- necessary to install and execute a modified version of the
122
- Combined Work produced by recombining or relinking the
123
- Application with a modified version of the Linked Version. (If
124
- you use option 4d0, the Installation Information must accompany
125
- the Minimal Corresponding Source and Corresponding Application
126
- Code. If you use option 4d1, you must provide the Installation
127
- Information in the manner specified by section 6 of the GNU GPL
128
- for conveying Corresponding Source.)
129
-
130
- 5. Combined Libraries.
131
-
132
- You may place library facilities that are a work based on the
133
- Library side by side in a single library together with other library
134
- facilities that are not Applications and are not covered by this
135
- License, and convey such a combined library under terms of your
136
- choice, if you do both of the following:
137
-
138
- a) Accompany the combined library with a copy of the same work based
139
- on the Library, uncombined with any other library facilities,
140
- conveyed under the terms of this License.
141
-
142
- b) Give prominent notice with the combined library that part of it
143
- is a work based on the Library, and explaining where to find the
144
- accompanying uncombined form of the same work.
145
-
146
- 6. Revised Versions of the GNU Lesser General Public License.
147
-
148
- The Free Software Foundation may publish revised and/or new versions
149
- of the GNU Lesser General Public License from time to time. Such new
150
- versions will be similar in spirit to the present version, but may
151
- differ in detail to address new problems or concerns.
152
-
153
- Each version is given a distinguishing version number. If the
154
- Library as you received it specifies that a certain numbered version
155
- of the GNU Lesser General Public License "or any later version"
156
- applies to it, you have the option of following the terms and
157
- conditions either of that published version or of any later version
158
- published by the Free Software Foundation. If the Library as you
159
- received it does not specify a version number of the GNU Lesser
160
- General Public License, you may choose any version of the GNU Lesser
161
- General Public License ever published by the Free Software Foundation.
162
-
163
- If the Library as you received it specifies that a proxy can decide
164
- whether future versions of the GNU Lesser General Public License shall
165
- apply, that proxy's public statement of acceptance of any version is
166
- permanent authorization for you to choose that version for the
167
- Library.
168
-
169
- </tt>
1
+
2
+ = GNU LESSER GENERAL PUBLIC LICENSE
3
+ Version 3, 29 June 2007
4
+
5
+ Copyright (C) 2007 Free Software Foundation, Inc. < http://fsf.org/ >
6
+ Everyone is permitted to copy and distribute verbatim copies
7
+ of this license document, but changing it is not allowed.
8
+
9
+ This version of the GNU Lesser General Public License incorporates
10
+ the terms and conditions of version 3 of the GNU General Public
11
+ License, supplemented by the additional permissions listed below.
12
+
13
+ === 0. Additional Definitions.
14
+
15
+ As used herein, "this License" refers to version 3 of the GNU Lesser
16
+ General Public License, and the "GNU GPL" refers to version 3 of the GNU
17
+ General Public License.
18
+
19
+ The Library" refers to a covered work governed by this License,
20
+ other than an Application or a Combined Work as defined below.
21
+
22
+ An "Application" is any work that makes use of an interface provided
23
+ by the Library, but which is not otherwise based on the Library.
24
+ Defining a subclass of a class defined by the Library is deemed a mode
25
+ of using an interface provided by the Library.
26
+
27
+ A "Combined Work" is a work produced by combining or linking an
28
+ Application with the Library. The particular version of the Library
29
+ with which the Combined Work was made is also called the "Linked
30
+ Version".
31
+
32
+ The "Minimal Corresponding Source" for a Combined Work means the
33
+ Corresponding Source for the Combined Work, excluding any source code
34
+ for portions of the Combined Work that, considered in isolation, are
35
+ based on the Application, and not on the Linked Version.
36
+
37
+ The "Corresponding Application Code" for a Combined Work means the
38
+ object code and/or source code for the Application, including any data
39
+ and utility programs needed for reproducing the Combined Work from the
40
+ Application, but excluding the System Libraries of the Combined Work.
41
+
42
+ === 1. Exception to Section 3 of the GNU GPL.
43
+
44
+ You may convey a covered work under sections 3 and 4 of this License
45
+ without being bound by section 3 of the GNU GPL.
46
+
47
+ === 2. Conveying Modified Versions.
48
+
49
+ If you modify a copy of the Library, and, in your modifications, a
50
+ facility refers to a function or data to be supplied by an Application
51
+ that uses the facility (other than as an argument passed when the
52
+ facility is invoked), then you may convey a copy of the modified
53
+ version:
54
+
55
+ a) under this License, provided that you make a good faith effort to
56
+ ensure that, in the event an Application does not supply the
57
+ function or data, the facility still operates, and performs
58
+ whatever part of its purpose remains meaningful, or
59
+
60
+ b) under the GNU GPL, with none of the additional permissions of
61
+ this License applicable to that copy.
62
+
63
+ === 3. Object Code Incorporating Material from Library Header Files.
64
+
65
+ The object code form of an Application may incorporate material from
66
+ a header file that is part of the Library. You may convey such object
67
+ code under terms of your choice, provided that, if the incorporated
68
+ material is not limited to numerical parameters, data structure
69
+ layouts and accessors, or small macros, inline functions and templates
70
+ (ten or fewer lines in length), you do both of the following:
71
+
72
+ a) Give prominent notice with each copy of the object code that the
73
+ Library is used in it and that the Library and its use are
74
+ covered by this License.
75
+
76
+ b) Accompany the object code with a copy of the GNU GPL and this license
77
+ document.
78
+
79
+ === 4. Combined Works.
80
+
81
+ You may convey a Combined Work under terms of your choice that,
82
+ taken together, effectively do not restrict modification of the
83
+ portions of the Library contained in the Combined Work and reverse
84
+ engineering for debugging such modifications, if you also do each of
85
+ the following:
86
+
87
+ a) Give prominent notice with each copy of the Combined Work that
88
+ the Library is used in it and that the Library and its use are
89
+ covered by this License.
90
+
91
+ b) Accompany the Combined Work with a copy of the GNU GPL and this license
92
+ document.
93
+
94
+ c) For a Combined Work that displays copyright notices during
95
+ execution, include the copyright notice for the Library among
96
+ these notices, as well as a reference directing the user to the
97
+ copies of the GNU GPL and this license document.
98
+
99
+ d) Do one of the following:
100
+
101
+ 0) Convey the Minimal Corresponding Source under the terms of this
102
+ License, and the Corresponding Application Code in a form
103
+ suitable for, and under terms that permit, the user to
104
+ recombine or relink the Application with a modified version of
105
+ the Linked Version to produce a modified Combined Work, in the
106
+ manner specified by section 6 of the GNU GPL for conveying
107
+ Corresponding Source.
108
+
109
+ 1) Use a suitable shared library mechanism for linking with the
110
+ Library. A suitable mechanism is one that (a) uses at run time
111
+ a copy of the Library already present on the user's computer
112
+ system, and (b) will operate properly with a modified version
113
+ of the Library that is interface-compatible with the Linked
114
+ Version.
115
+
116
+ e) Provide Installation Information, but only if you would otherwise
117
+ be required to provide such information under section 6 of the
118
+ GNU GPL, and only to the extent that such information is
119
+ necessary to install and execute a modified version of the
120
+ Combined Work produced by recombining or relinking the
121
+ Application with a modified version of the Linked Version. (If
122
+ you use option 4d0, the Installation Information must accompany
123
+ the Minimal Corresponding Source and Corresponding Application
124
+ Code. If you use option 4d1, you must provide the Installation
125
+ Information in the manner specified by section 6 of the GNU GPL
126
+ for conveying Corresponding Source.)
127
+
128
+ === 5. Combined Libraries.
129
+
130
+ You may place library facilities that are a work based on the
131
+ Library side by side in a single library together with other library
132
+ facilities that are not Applications and are not covered by this
133
+ License, and convey such a combined library under terms of your
134
+ choice, if you do both of the following:
135
+
136
+ a) Accompany the combined library with a copy of the same work based
137
+ on the Library, uncombined with any other library facilities,
138
+ conveyed under the terms of this License.
139
+
140
+ b) Give prominent notice with the combined library that part of it
141
+ is a work based on the Library, and explaining where to find the
142
+ accompanying uncombined form of the same work.
143
+
144
+ === 6. Revised Versions of the GNU Lesser General Public License.
145
+
146
+ The Free Software Foundation may publish revised and/or new versions
147
+ of the GNU Lesser General Public License from time to time. Such new
148
+ versions will be similar in spirit to the present version, but may
149
+ differ in detail to address new problems or concerns.
150
+
151
+ Each version is given a distinguishing version number. If the
152
+ Library as you received it specifies that a certain numbered version
153
+ of the GNU Lesser General Public License "or any later version"
154
+ applies to it, you have the option of following the terms and
155
+ conditions either of that published version or of any later version
156
+ published by the Free Software Foundation. If the Library as you
157
+ received it does not specify a version number of the GNU Lesser
158
+ General Public License, you may choose any version of the GNU Lesser
159
+ General Public License ever published by the Free Software Foundation.
160
+
161
+ If the Library as you received it specifies that a proxy can decide
162
+ whether future versions of the GNU Lesser General Public License shall
163
+ apply, that proxy's public statement of acceptance of any version is
164
+ permanent authorization for you to choose that version for the
165
+ Library.
166
+