unicode-categories 1.3.0 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.travis.yml +6 -6
- data/CHANGELOG.md +4 -0
- data/MIT-LICENSE.txt +1 -1
- data/README.md +8 -6
- data/data/categories.marshal.gz +0 -0
- data/lib/unicode/categories/constants.rb +6 -4
- metadata +4 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4ffc0f1ebc92ff6e301fdbf2867bd2ebce9e94d31602978b58b7de57d6bc36ec
|
4
|
+
data.tar.gz: 6d10fa6fe530fe1906a03763da16b9b00377abbe3eb44378a608713600019338
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 48ae066326e4ac30cb4dd00856263c4924c6207ec7953d708aa4383b6fd6c7542e3ae66bca84b797ce94af5d81f9da75aa536f9fd6bca857d231f814d53cdf79
|
7
|
+
data.tar.gz: 8bfd735596b3d3ce65378b6ee292f5a82aec2c659c19b17b8e0a2895c2f44ddf6cbd28a80f37d25dffb9d7f3101e34d7acf8b6bbc7cb093240dda17c0b664376
|
data/.travis.yml
CHANGED
@@ -3,20 +3,20 @@ language: ruby
|
|
3
3
|
|
4
4
|
rvm:
|
5
5
|
- ruby-head
|
6
|
-
- 2.
|
7
|
-
- 2.
|
8
|
-
- 2.
|
6
|
+
- 2.6.1
|
7
|
+
- 2.5.3
|
8
|
+
- 2.4.5
|
9
|
+
- 2.3.8
|
9
10
|
- 2.2
|
10
11
|
- 2.1
|
11
12
|
- 2.0
|
12
13
|
- jruby-head
|
13
|
-
- jruby-9.
|
14
|
+
- jruby-9.2.6.0
|
14
15
|
|
15
16
|
matrix:
|
16
17
|
allow_failures:
|
17
18
|
- rvm: jruby-head
|
18
|
-
- rvm:
|
19
|
+
- rvm: 2.3
|
19
20
|
- rvm: 2.2
|
20
21
|
- rvm: 2.1
|
21
22
|
- rvm: 2.0
|
22
|
-
# fast_finish: true
|
data/CHANGELOG.md
CHANGED
data/MIT-LICENSE.txt
CHANGED
data/README.md
CHANGED
@@ -1,12 +1,12 @@
|
|
1
|
-
# Unicode::Categories [![[version]](https://badge.fury.io/rb/unicode-categories.svg)](
|
1
|
+
# Unicode::Categories [![[version]](https://badge.fury.io/rb/unicode-categories.svg)](https://badge.fury.io/rb/unicode-categories) [![[travis]](https://travis-ci.org/janlelis/unicode-categories.png)](https://travis-ci.org/janlelis/unicode-categories)
|
2
2
|
|
3
3
|
Returns which [General Categories](https://en.wikipedia.org/wiki/Unicode_character_property#General_Category) a Unicode string contains.
|
4
4
|
|
5
|
-
Unicode version: **
|
5
|
+
Unicode version: **12.0.0**
|
6
6
|
|
7
|
-
Supported Rubies: **2.
|
7
|
+
Supported Rubies: **2.6**, **2.5**, **2.4**
|
8
8
|
|
9
|
-
Old Rubies that might still work: **2.2**, **2.1**, **2.0**
|
9
|
+
Old Rubies that might still work: **2.3**, **2.2**, **2.1**, **2.0**
|
10
10
|
|
11
11
|
## Gemfile
|
12
12
|
|
@@ -37,12 +37,14 @@ The list of categories is always sorted alphabetically.
|
|
37
37
|
|
38
38
|
### Regex Matching
|
39
39
|
|
40
|
-
If you have a string and want to match a substring/character from a specific Unicode block, you actually won't need this gem. Instead, you can use the [Regexp Unicode Property Syntax `\p{}`](http://ruby-doc.org/core
|
40
|
+
If you have a string and want to match a substring/character from a specific Unicode block, you actually won't need this gem. Instead, you can use the [Regexp Unicode Property Syntax `\p{}`](http://ruby-doc.org/core/Regexp.html#class-Regexp-label-Character+Properties):
|
41
41
|
|
42
42
|
```ruby
|
43
43
|
"Find decimal numbers (like 2 or 3) within a string".scan(/\p{Nd}+/) # => ["2", "3"]
|
44
44
|
```
|
45
45
|
|
46
|
+
See [Idiosyncratic Ruby: Proper Unicoding](https://idiosyncratic-ruby.com/41-proper-unicoding.html) for more info.
|
47
|
+
|
46
48
|
### List of General Categories
|
47
49
|
|
48
50
|
You can retrieve a list of all General Categories like this:
|
@@ -93,6 +95,6 @@ See [unicode-x](https://github.com/janlelis/unicode-x) for more Unicode related
|
|
93
95
|
|
94
96
|
## MIT License
|
95
97
|
|
96
|
-
- Copyright (C) 2016-
|
98
|
+
- Copyright (C) 2016-2019 Jan Lelis <http://janlelis.com>. Released under the MIT license.
|
97
99
|
- Unicode data: http://www.unicode.org/copyright.html#Exhibit1
|
98
100
|
|
data/data/categories.marshal.gz
CHANGED
Binary file
|
@@ -1,9 +1,11 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module Unicode
|
2
4
|
module Categories
|
3
|
-
VERSION = "1.
|
4
|
-
UNICODE_VERSION = "
|
5
|
-
DATA_DIRECTORY = File.expand_path(File.dirname(__FILE__) +
|
6
|
-
INDEX_FILENAME = (DATA_DIRECTORY +
|
5
|
+
VERSION = "1.4.0"
|
6
|
+
UNICODE_VERSION = "12.0.0"
|
7
|
+
DATA_DIRECTORY = File.expand_path(File.dirname(__FILE__) + "/../../../data/").freeze
|
8
|
+
INDEX_FILENAME = (DATA_DIRECTORY + "/categories.marshal.gz").freeze
|
7
9
|
end
|
8
10
|
end
|
9
11
|
|
metadata
CHANGED
@@ -1,16 +1,16 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: unicode-categories
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jan Lelis
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2019-03-05 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
|
-
description: "[Unicode
|
13
|
+
description: "[Unicode 12.0.0] Determine which Unicode General Categories a string
|
14
14
|
belongs to."
|
15
15
|
email:
|
16
16
|
- mail@janlelis.de
|
@@ -53,8 +53,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '0'
|
55
55
|
requirements: []
|
56
|
-
|
57
|
-
rubygems_version: 2.7.6
|
56
|
+
rubygems_version: 3.0.1
|
58
57
|
signing_key:
|
59
58
|
specification_version: 4
|
60
59
|
summary: Determine the Unicode General Categories of a string.
|