az 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +2 -0
- data/.travis.yml +24 -0
- data/CHANGELOG.md +10 -0
- data/CODE_OF_CONDUCT.md +74 -0
- data/Gemfile +6 -0
- data/MIT-LICENSE.txt +20 -0
- data/README.md +65 -0
- data/Rakefile +37 -0
- data/az.gemspec +24 -0
- data/bin/az +64 -0
- data/lib/az.rb +17 -0
- data/lib/az/constants.rb +41 -0
- data/lib/az/kernel_method.rb +11 -0
- data/lib/az/string_ext.rb +10 -0
- data/spec/az_spec.rb +55 -0
- metadata +95 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 7314edb32ef662484e8eb081eeb853b0e35dacc03d40944dc87f5454ec3d8da4
|
4
|
+
data.tar.gz: 97bf39df9af6ff018acc8008fad269a5596d6676f3500903ce1c72cda27d9933
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: a1a9b57eaf28a72fc87022d92dc91d4613c8a2f961c5c88998d2b7af106452643b8a440d7e5d8f265eb5489a50e85c4f3b1a612df0319d8952623890ab6e53bb
|
7
|
+
data.tar.gz: 8bba1a0ae019e57930c0631403afaef88046fabef16adfa4f02b5ed80558142649bce444faa9271611570a2bf821ee7841915a5ea2a4e773e1af31b143a36769
|
data/.gitignore
ADDED
data/.travis.yml
ADDED
@@ -0,0 +1,24 @@
|
|
1
|
+
sudo: false
|
2
|
+
language: ruby
|
3
|
+
|
4
|
+
script: bundle exec ruby spec/az_spec.rb
|
5
|
+
|
6
|
+
rvm:
|
7
|
+
- ruby-head
|
8
|
+
- 2.6.1
|
9
|
+
- 2.5.3
|
10
|
+
- 2.4.5
|
11
|
+
- 2.3.8
|
12
|
+
- 2.2
|
13
|
+
- 2.1
|
14
|
+
- 2.0
|
15
|
+
- jruby-head
|
16
|
+
- jruby-9.2.6.0
|
17
|
+
|
18
|
+
matrix:
|
19
|
+
allow_failures:
|
20
|
+
- rvm: jruby-head
|
21
|
+
- rvm: 2.3.8
|
22
|
+
- rvm: 2.2
|
23
|
+
- rvm: 2.1
|
24
|
+
- rvm: 2.0
|
data/CHANGELOG.md
ADDED
data/CODE_OF_CONDUCT.md
ADDED
@@ -0,0 +1,74 @@
|
|
1
|
+
# Contributor Covenant Code of Conduct
|
2
|
+
|
3
|
+
## Our Pledge
|
4
|
+
|
5
|
+
In the interest of fostering an open and welcoming environment, we as
|
6
|
+
contributors and maintainers pledge to making participation in our project and
|
7
|
+
our community a harassment-free experience for everyone, regardless of age, body
|
8
|
+
size, disability, ethnicity, gender identity and expression, level of experience,
|
9
|
+
nationality, personal appearance, race, religion, or sexual identity and
|
10
|
+
orientation.
|
11
|
+
|
12
|
+
## Our Standards
|
13
|
+
|
14
|
+
Examples of behavior that contributes to creating a positive environment
|
15
|
+
include:
|
16
|
+
|
17
|
+
* Using welcoming and inclusive language
|
18
|
+
* Being respectful of differing viewpoints and experiences
|
19
|
+
* Gracefully accepting constructive criticism
|
20
|
+
* Focusing on what is best for the community
|
21
|
+
* Showing empathy towards other community members
|
22
|
+
|
23
|
+
Examples of unacceptable behavior by participants include:
|
24
|
+
|
25
|
+
* The use of sexualized language or imagery and unwelcome sexual attention or
|
26
|
+
advances
|
27
|
+
* Trolling, insulting/derogatory comments, and personal or political attacks
|
28
|
+
* Public or private harassment
|
29
|
+
* Publishing others' private information, such as a physical or electronic
|
30
|
+
address, without explicit permission
|
31
|
+
* Other conduct which could reasonably be considered inappropriate in a
|
32
|
+
professional setting
|
33
|
+
|
34
|
+
## Our Responsibilities
|
35
|
+
|
36
|
+
Project maintainers are responsible for clarifying the standards of acceptable
|
37
|
+
behavior and are expected to take appropriate and fair corrective action in
|
38
|
+
response to any instances of unacceptable behavior.
|
39
|
+
|
40
|
+
Project maintainers have the right and responsibility to remove, edit, or
|
41
|
+
reject comments, commits, code, wiki edits, issues, and other contributions
|
42
|
+
that are not aligned to this Code of Conduct, or to ban temporarily or
|
43
|
+
permanently any contributor for other behaviors that they deem inappropriate,
|
44
|
+
threatening, offensive, or harmful.
|
45
|
+
|
46
|
+
## Scope
|
47
|
+
|
48
|
+
This Code of Conduct applies both within project spaces and in public spaces
|
49
|
+
when an individual is representing the project or its community. Examples of
|
50
|
+
representing a project or community include using an official project e-mail
|
51
|
+
address, posting via an official social media account, or acting as an appointed
|
52
|
+
representative at an online or offline event. Representation of a project may be
|
53
|
+
further defined and clarified by project maintainers.
|
54
|
+
|
55
|
+
## Enforcement
|
56
|
+
|
57
|
+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
58
|
+
reported by contacting the project team at opensource@janlelis.com. All
|
59
|
+
complaints will be reviewed and investigated and will result in a response that
|
60
|
+
is deemed necessary and appropriate to the circumstances. The project team is
|
61
|
+
obligated to maintain confidentiality with regard to the reporter of an incident.
|
62
|
+
Further details of specific enforcement policies may be posted separately.
|
63
|
+
|
64
|
+
Project maintainers who do not follow or enforce the Code of Conduct in good
|
65
|
+
faith may face temporary or permanent repercussions as determined by other
|
66
|
+
members of the project's leadership.
|
67
|
+
|
68
|
+
## Attribution
|
69
|
+
|
70
|
+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
|
71
|
+
available at [http://contributor-covenant.org/version/1/4][version]
|
72
|
+
|
73
|
+
[homepage]: http://contributor-covenant.org
|
74
|
+
[version]: http://contributor-covenant.org/version/1/4/
|
data/Gemfile
ADDED
data/MIT-LICENSE.txt
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
Copyright (c) 2019 Jan Lelis, mail@janlelis.de
|
2
|
+
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
+
a copy of this software and associated documentation files (the
|
5
|
+
"Software"), to deal in the Software without restriction, including
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
9
|
+
the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be
|
12
|
+
included in all copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
17
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
18
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
19
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
20
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,65 @@
|
|
1
|
+
# az [![[version]](https://badge.fury.io/rb/az.svg)](https://badge.fury.io/rb/az) [![[travis]](https://travis-ci.org/janlelis/az.png)](https://travis-ci.org/janlelis/az)
|
2
|
+
|
3
|
+
Going from A to Z in different ways. It will translate Latin ASCII characters to funky Unicode ones.
|
4
|
+
|
5
|
+
## Setup
|
6
|
+
|
7
|
+
Make sure you have Ruby installed and installing gems works properly. Then do:
|
8
|
+
|
9
|
+
```
|
10
|
+
$ gem install az
|
11
|
+
```
|
12
|
+
|
13
|
+
## Usage
|
14
|
+
|
15
|
+
Pass the string to convert to `az`:
|
16
|
+
|
17
|
+
### From CLI
|
18
|
+
|
19
|
+
```
|
20
|
+
$ az "character.construction" --to bold
|
21
|
+
# ๐๐ก๐๐ซ๐๐๐ญ๐๐ซ.๐๐จ๐ง๐ฌ๐ญ๐ซ๐ฎ๐๐ญ๐ข๐จ๐ง
|
22
|
+
```
|
23
|
+
|
24
|
+
### From Ruby
|
25
|
+
|
26
|
+
```ruby
|
27
|
+
require "az/kernel_method"
|
28
|
+
az "character.construction", :fraktur
|
29
|
+
# => "๐๐๐๐๐๐๐๐๐.๐๐๐๐๐๐๐๐๐๐๐๐"
|
30
|
+
```
|
31
|
+
|
32
|
+
## Included Fonts
|
33
|
+
|
34
|
+
**Please note:** Be sure to understand that the output from az does not change the real font, but displays these special "font" codepoints within the actual font.
|
35
|
+
|
36
|
+
Font | Output
|
37
|
+
------------------------------------|------------
|
38
|
+
ascii | From A to Z
|
39
|
+
bold | ๐
๐ซ๐จ๐ฆ ๐ ๐ญ๐จ ๐
|
40
|
+
italic | ๐น๐๐๐ ๐ด ๐ก๐ ๐
|
41
|
+
bold_italic / italic_bold | ๐ญ๐๐๐ ๐จ ๐๐ ๐
|
42
|
+
monospace | ๐ต๐๐๐ ๐ฐ ๐๐ ๐
|
43
|
+
double | ๏ผฆ๏ฝ๏ฝ๏ฝ ๏ผก ๏ฝ๏ฝ ๏ผบ
|
44
|
+
sans | ๐ฅ๐๐๐ ๐ ๐๐ ๐น
|
45
|
+
sans_bold | ๐๐ฟ๐ผ๐บ ๐ ๐๐ผ ๐ญ
|
46
|
+
sans_italic | ๐๐ณ๐ฐ๐ฎ ๐ ๐ต๐ฐ ๐ก
|
47
|
+
sans_bold_italic / sans_italic_bold | ๐๐ง๐ค๐ข ๐ผ ๐ฉ๐ค ๐
|
48
|
+
script | ๐๐ป๐ธ๐ถ ๐ ๐ฝ๐ธ ๐ฉ
|
49
|
+
fraktur | ๐ฑ๐๐๐ ๐ฌ ๐๐ ๐
|
50
|
+
small_caps | Fสแดแด A แดแด Z
|
51
|
+
parentheses | ๐โญโชโจ ๐ โฏโช ๐ฉ
|
52
|
+
circled | โปโกโโ โถ โฃโ โ
|
53
|
+
circled_upper / upper_circled | โปโโโ โถ โโ โ
|
54
|
+
circled_negative / negative_circled | ๐
๐
ก๐
๐
๐
๐
ฃ๐
๐
ฉ
|
55
|
+
squared_upper / upper_squared | ๐ต๐
๐พ๐ผ ๐ฐ ๐
๐พ ๐
|
56
|
+
squared_negative / negative_squared | ๐
ต๐๐
พ๐
ผ ๐
ฐ ๐๐
พ ๐
|
57
|
+
region | ๐ซ๐ท๐ด๐ฒ ๐ฆ ๐น๐ด ๐ฟ
|
58
|
+
tag | `๓ ๓ ฒ๓ ฏ๓ ญ ๓ ๓ ด๓ ฏ ๓ `
|
59
|
+
|
60
|
+
## Also see
|
61
|
+
|
62
|
+
- [character.construction/az](https://character.construction/az)
|
63
|
+
- CLI: [uniscribe](https://github.com/janlelis/uniscribe)
|
64
|
+
|
65
|
+
Copyright (C) 2019 Jan Lelis <http://janlelis.com>. Released under the MIT license.
|
data/Rakefile
ADDED
@@ -0,0 +1,37 @@
|
|
1
|
+
# # #
|
2
|
+
# Get gemspec info
|
3
|
+
|
4
|
+
gemspec_file = Dir['*.gemspec'].first
|
5
|
+
gemspec = eval File.read(gemspec_file), binding, gemspec_file
|
6
|
+
info = "#{gemspec.name} | #{gemspec.version} | " \
|
7
|
+
"#{gemspec.runtime_dependencies.size} dependencies | " \
|
8
|
+
"#{gemspec.files.size} files"
|
9
|
+
|
10
|
+
# # #
|
11
|
+
# Gem build and install task
|
12
|
+
|
13
|
+
desc info
|
14
|
+
task :gem do
|
15
|
+
puts info + "\n\n"
|
16
|
+
print " "; sh "gem build #{gemspec_file}"
|
17
|
+
FileUtils.mkdir_p 'pkg'
|
18
|
+
FileUtils.mv "#{gemspec.name}-#{gemspec.version}.gem", 'pkg'
|
19
|
+
puts; sh %{gem install --no-document pkg/#{gemspec.name}-#{gemspec.version}.gem}
|
20
|
+
end
|
21
|
+
|
22
|
+
# # #
|
23
|
+
# Start an IRB session with the gem loaded
|
24
|
+
|
25
|
+
desc "#{gemspec.name} | IRB"
|
26
|
+
task :irb do
|
27
|
+
sh "irb -I ./lib -r #{gemspec.name.gsub '-','/'}"
|
28
|
+
end
|
29
|
+
|
30
|
+
# # #
|
31
|
+
# Run Specs
|
32
|
+
|
33
|
+
desc "#{gemspec.name} | Spec"
|
34
|
+
task :spec do
|
35
|
+
sh "for file in spec/*.rb; do ruby $file; done"
|
36
|
+
end
|
37
|
+
task default: :spec
|
data/az.gemspec
ADDED
@@ -0,0 +1,24 @@
|
|
1
|
+
# -*- encoding: utf-8 -*-
|
2
|
+
|
3
|
+
require File.dirname(__FILE__) + "/lib/az/constants"
|
4
|
+
|
5
|
+
Gem::Specification.new do |gem|
|
6
|
+
gem.name = "az"
|
7
|
+
gem.version = Az::VERSION
|
8
|
+
gem.summary = "Collects different ways of A-Z"
|
9
|
+
gem.description = "Going from A to Z in different ways"
|
10
|
+
gem.authors = ["Jan Lelis"]
|
11
|
+
gem.email = ["mail@janlelis.de"]
|
12
|
+
gem.homepage = "https://github.com/janlelis/az"
|
13
|
+
gem.license = "MIT"
|
14
|
+
|
15
|
+
gem.files = Dir["{**/}{.*,*}"].select{ |path| File.file?(path) && path !~ /^pkg/ }
|
16
|
+
gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
|
17
|
+
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
|
18
|
+
gem.require_paths = ["lib"]
|
19
|
+
|
20
|
+
gem.required_ruby_version = "~> 2.0"
|
21
|
+
|
22
|
+
gem.add_dependency "paint", ">= 0.9", "< 3.0"
|
23
|
+
gem.add_dependency "rationalist", "~> 2.0"
|
24
|
+
end
|
data/bin/az
ADDED
@@ -0,0 +1,64 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
# frozen_string_literal: true
|
3
|
+
|
4
|
+
require "rationalist"
|
5
|
+
require "paint"
|
6
|
+
require "az"
|
7
|
+
|
8
|
+
argv = Rationalist.parse(
|
9
|
+
ARGV,
|
10
|
+
string: '_',
|
11
|
+
alias: {
|
12
|
+
t: 'to',
|
13
|
+
v: 'version',
|
14
|
+
},
|
15
|
+
boolean: [
|
16
|
+
'fonts',
|
17
|
+
'help',
|
18
|
+
'version',
|
19
|
+
]
|
20
|
+
)
|
21
|
+
|
22
|
+
if argv[:version]
|
23
|
+
puts "az #{Az::VERSION} by #{Paint["J-_-L", :bold]} <https://github.com/janlelis/az>"
|
24
|
+
puts "Unicode version is #{Az::UNICODE_VERSION}"
|
25
|
+
exit(0)
|
26
|
+
end
|
27
|
+
|
28
|
+
if argv[:help]
|
29
|
+
puts <<-HELP
|
30
|
+
|
31
|
+
#{Paint["DESCRIPTION", :underline]}
|
32
|
+
|
33
|
+
Translates Latin ASCII characters to funky Unicode ones.
|
34
|
+
|
35
|
+
#{Paint["USAGE", :underline]}
|
36
|
+
|
37
|
+
#{Paint["az", :bold]} data --to font
|
38
|
+
|
39
|
+
--fonts | | displays list of fonts
|
40
|
+
--help | | this help page
|
41
|
+
--version | -v | displays version of az
|
42
|
+
|
43
|
+
#{Paint["MORE INFO", :underline]}
|
44
|
+
|
45
|
+
https://github.com/janlelis/az
|
46
|
+
|
47
|
+
HELP
|
48
|
+
exit(0)
|
49
|
+
end
|
50
|
+
|
51
|
+
if argv[:_] && argv[:_][0]
|
52
|
+
data = argv[:_][0]
|
53
|
+
elsif !$stdin.tty?
|
54
|
+
data = $stdin.read
|
55
|
+
else
|
56
|
+
data = nil
|
57
|
+
end
|
58
|
+
|
59
|
+
begin
|
60
|
+
puts Az.az(data, argv[:to])
|
61
|
+
rescue ArgumentError
|
62
|
+
$stderr.puts Paint[$!.message, :red]
|
63
|
+
exit(1)
|
64
|
+
end
|
data/lib/az.rb
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "az/constants"
|
4
|
+
|
5
|
+
module Az
|
6
|
+
def self.az(input, font = :ascii)
|
7
|
+
input.tr(
|
8
|
+
FONTS[:ascii],
|
9
|
+
(FONTS[(font || "").to_sym] or raise ArgumentError, "unknown az font: #{font}")
|
10
|
+
)
|
11
|
+
end
|
12
|
+
class << self; alias of az; end
|
13
|
+
|
14
|
+
def self.fonts
|
15
|
+
FONTS.keys
|
16
|
+
end
|
17
|
+
end
|
data/lib/az/constants.rb
ADDED
@@ -0,0 +1,41 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Az
|
4
|
+
VERSION = "1.0.1"
|
5
|
+
UNICODE_VERSION = "12.0.0"
|
6
|
+
|
7
|
+
FONTS = {
|
8
|
+
ascii: "A-Za-z",
|
9
|
+
bold: "๐-๐๐-๐ณ",
|
10
|
+
italic: "๐ด-๐๐-๐ง",
|
11
|
+
bold_italic: "๐จ-๐๐-๐",
|
12
|
+
italic_bold: "๐จ-๐๐-๐",
|
13
|
+
monospace: "๐ฐ-๐๐-๐ฃ",
|
14
|
+
double: "๏ผก-๏ผบ๏ฝ-๏ฝ",
|
15
|
+
|
16
|
+
sans: "๐ -๐น๐บ-๐",
|
17
|
+
sans_bold: "๐-๐ญ๐ฎ-๐",
|
18
|
+
sans_italic: "๐-๐ก๐ข-๐ป",
|
19
|
+
sans_bold_italic: "๐ผ-๐๐-๐ฏ",
|
20
|
+
sans_italic_bold: "๐ผ-๐๐-๐ฏ",
|
21
|
+
|
22
|
+
script: "๐-๐ฉ๐ช-๐",
|
23
|
+
fraktur: "๐ฌ-๐
๐-๐",
|
24
|
+
small_caps: "A-Zแดสแดแด
แด๊ฐษขสษชแดแดสแดษดแดแดฉqส๊ฑแดแดแด แดกxyแดข", # upper remains ascii
|
25
|
+
parentheses: "๐-๐ฉโ-โต",
|
26
|
+
|
27
|
+
circled: "โถ-โโ-โฉ",
|
28
|
+
circled_upper: "โถ-โโถ-โ",
|
29
|
+
upper_circled: "โถ-โโถ-โ",
|
30
|
+
circled_negative: "๐
-๐
ฉ๐
-๐
ฉ", # no lower
|
31
|
+
negative_circled: "๐
-๐
ฉ๐
-๐
ฉ", # no lower
|
32
|
+
squared_upper: "๐ฐ-๐
๐ฐ-๐
", # no lower
|
33
|
+
upper_squared: "๐ฐ-๐
๐ฐ-๐
", # no lower
|
34
|
+
squared_negative: "๐
ฐ-๐๐
ฐ-๐", # no lower
|
35
|
+
negative_squared: "๐
ฐ-๐๐
ฐ-๐", # no lower
|
36
|
+
|
37
|
+
region: "๐ฆ-๐ฟ๐ฆ-๐ฟ",
|
38
|
+
tag: "\u{E0041}-\u{E005A}\u{E0061}-\u{E007A}",
|
39
|
+
}
|
40
|
+
end
|
41
|
+
|
data/spec/az_spec.rb
ADDED
@@ -0,0 +1,55 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "../lib/az/kernel_method"
|
4
|
+
require "minitest/autorun"
|
5
|
+
|
6
|
+
describe "az" do
|
7
|
+
it "will always return an String" do
|
8
|
+
assert_kind_of String, az("")
|
9
|
+
end
|
10
|
+
|
11
|
+
it "will replace A-Z with Unicode characters which represent latin letters but in a different way" do
|
12
|
+
assert_equal "๐๐ก๐๐ซ๐๐๐ญ๐๐ซ.๐๐จ๐ง๐ฌ๐ญ๐ซ๐ฎ๐๐ญ๐ข๐จ๐ง", az("character.construction", :bold)
|
13
|
+
end
|
14
|
+
|
15
|
+
it "does nothing if no font (2nd parameter) is passed in" do
|
16
|
+
assert_equal "character.construction", az("character.construction")
|
17
|
+
end
|
18
|
+
|
19
|
+
it "works with every included font" do
|
20
|
+
assert_equal "๐
๐ซ๐จ๐ฆ ๐ ๐ญ๐จ ๐", az("From A to Z", :bold)
|
21
|
+
assert_equal "๐น๐๐๐ ๐ด ๐ก๐ ๐", az("From A to Z", :italic)
|
22
|
+
assert_equal "๐ญ๐๐๐ ๐จ ๐๐ ๐", az("From A to Z", :bold_italic)
|
23
|
+
assert_equal "๐ญ๐๐๐ ๐จ ๐๐ ๐", az("From A to Z", :italic_bold)
|
24
|
+
assert_equal "๐ต๐๐๐ ๐ฐ ๐๐ ๐", az("From A to Z", :monospace)
|
25
|
+
assert_equal "๏ผฆ๏ฝ๏ฝ๏ฝ ๏ผก ๏ฝ๏ฝ ๏ผบ", az("From A to Z", :double)
|
26
|
+
assert_equal "๐ฅ๐๐๐ ๐ ๐๐ ๐น", az("From A to Z", :sans)
|
27
|
+
assert_equal "๐๐ฟ๐ผ๐บ ๐ ๐๐ผ ๐ญ", az("From A to Z", :sans_bold)
|
28
|
+
assert_equal "๐๐ณ๐ฐ๐ฎ ๐ ๐ต๐ฐ ๐ก", az("From A to Z", :sans_italic)
|
29
|
+
assert_equal "๐๐ง๐ค๐ข ๐ผ ๐ฉ๐ค ๐", az("From A to Z", :sans_bold_italic)
|
30
|
+
assert_equal "๐๐ง๐ค๐ข ๐ผ ๐ฉ๐ค ๐", az("From A to Z", :sans_italic_bold)
|
31
|
+
assert_equal "๐๐ป๐ธ๐ถ ๐ ๐ฝ๐ธ ๐ฉ", az("From A to Z", :script)
|
32
|
+
assert_equal "๐ฑ๐๐๐ ๐ฌ ๐๐ ๐
", az("From A to Z", :fraktur)
|
33
|
+
assert_equal "Fสแดแด A แดแด Z", az("From A to Z", :small_caps)
|
34
|
+
assert_equal "๐โญโชโจ ๐ โฏโช ๐ฉ", az("From A to Z", :parentheses)
|
35
|
+
assert_equal "โปโกโโ โถ โฃโ โ", az("From A to Z", :circled)
|
36
|
+
assert_equal "โปโโโ โถ โโ โ", az("From A to Z", :circled_upper)
|
37
|
+
assert_equal "โปโโโ โถ โโ โ", az("From A to Z", :upper_circled)
|
38
|
+
assert_equal "๐
๐
ก๐
๐
๐
๐
ฃ๐
๐
ฉ", az("From A to Z", :circled_negative)
|
39
|
+
assert_equal "๐
๐
ก๐
๐
๐
๐
ฃ๐
๐
ฉ", az("From A to Z", :negative_circled)
|
40
|
+
assert_equal "๐ต๐
๐พ๐ผ ๐ฐ ๐
๐พ ๐
", az("From A to Z", :squared_upper)
|
41
|
+
assert_equal "๐ต๐
๐พ๐ผ ๐ฐ ๐
๐พ ๐
", az("From A to Z", :upper_squared)
|
42
|
+
assert_equal "๐
ต๐๐
พ๐
ผ ๐
ฐ ๐๐
พ ๐", az("From A to Z", :squared_negative)
|
43
|
+
assert_equal "๐
ต๐๐
พ๐
ผ ๐
ฐ ๐๐
พ ๐", az("From A to Z", :negative_squared)
|
44
|
+
assert_equal "๐ซ๐ท๐ด๐ฒ ๐ฆ ๐น๐ด ๐ฟ", az("From A to Z", :region)
|
45
|
+
assert_equal "๓ ๓ ฒ๓ ฏ๓ ญ ๓ ๓ ด๓ ฏ ๓ ", az("From A to Z", :tag)
|
46
|
+
end
|
47
|
+
end
|
48
|
+
|
49
|
+
|
50
|
+
describe "Az.fonts" do
|
51
|
+
it "will return a list of all available 'fonts'" do
|
52
|
+
assert_kind_of Array, Az.fonts
|
53
|
+
assert_includes Az.fonts, :italic
|
54
|
+
end
|
55
|
+
end
|
metadata
ADDED
@@ -0,0 +1,95 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: az
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 1.0.1
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Jan Lelis
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2019-03-05 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: paint
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '0.9'
|
20
|
+
- - "<"
|
21
|
+
- !ruby/object:Gem::Version
|
22
|
+
version: '3.0'
|
23
|
+
type: :runtime
|
24
|
+
prerelease: false
|
25
|
+
version_requirements: !ruby/object:Gem::Requirement
|
26
|
+
requirements:
|
27
|
+
- - ">="
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: '0.9'
|
30
|
+
- - "<"
|
31
|
+
- !ruby/object:Gem::Version
|
32
|
+
version: '3.0'
|
33
|
+
- !ruby/object:Gem::Dependency
|
34
|
+
name: rationalist
|
35
|
+
requirement: !ruby/object:Gem::Requirement
|
36
|
+
requirements:
|
37
|
+
- - "~>"
|
38
|
+
- !ruby/object:Gem::Version
|
39
|
+
version: '2.0'
|
40
|
+
type: :runtime
|
41
|
+
prerelease: false
|
42
|
+
version_requirements: !ruby/object:Gem::Requirement
|
43
|
+
requirements:
|
44
|
+
- - "~>"
|
45
|
+
- !ruby/object:Gem::Version
|
46
|
+
version: '2.0'
|
47
|
+
description: Going from A to Z in different ways
|
48
|
+
email:
|
49
|
+
- mail@janlelis.de
|
50
|
+
executables:
|
51
|
+
- az
|
52
|
+
extensions: []
|
53
|
+
extra_rdoc_files: []
|
54
|
+
files:
|
55
|
+
- ".gitignore"
|
56
|
+
- ".travis.yml"
|
57
|
+
- CHANGELOG.md
|
58
|
+
- CODE_OF_CONDUCT.md
|
59
|
+
- Gemfile
|
60
|
+
- Gemfile.lock
|
61
|
+
- MIT-LICENSE.txt
|
62
|
+
- README.md
|
63
|
+
- Rakefile
|
64
|
+
- az.gemspec
|
65
|
+
- bin/az
|
66
|
+
- lib/az.rb
|
67
|
+
- lib/az/constants.rb
|
68
|
+
- lib/az/kernel_method.rb
|
69
|
+
- lib/az/string_ext.rb
|
70
|
+
- spec/az_spec.rb
|
71
|
+
homepage: https://github.com/janlelis/az
|
72
|
+
licenses:
|
73
|
+
- MIT
|
74
|
+
metadata: {}
|
75
|
+
post_install_message:
|
76
|
+
rdoc_options: []
|
77
|
+
require_paths:
|
78
|
+
- lib
|
79
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
80
|
+
requirements:
|
81
|
+
- - "~>"
|
82
|
+
- !ruby/object:Gem::Version
|
83
|
+
version: '2.0'
|
84
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
85
|
+
requirements:
|
86
|
+
- - ">="
|
87
|
+
- !ruby/object:Gem::Version
|
88
|
+
version: '0'
|
89
|
+
requirements: []
|
90
|
+
rubygems_version: 3.0.1
|
91
|
+
signing_key:
|
92
|
+
specification_version: 4
|
93
|
+
summary: Collects different ways of A-Z
|
94
|
+
test_files:
|
95
|
+
- spec/az_spec.rb
|