Skip to content

Commit a389dcd

Browse files
committed
More Rubocop
1 parent 062e294 commit a389dcd

File tree

2 files changed

+28
-67
lines changed

2 files changed

+28
-67
lines changed

.rubocop_todo.yml

Lines changed: 0 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -6,47 +6,6 @@
66
# Note that changes in the inspected code, or installation of new
77
# versions of RuboCop, may require this file to be generated again.
88

9-
# Offense count: 1
10-
# Cop supports --auto-correct.
11-
# Configuration parameters: TreatCommentsAsGroupSeparators, ConsiderPunctuation, Include.
12-
# Include: **/*.gemspec
13-
Gemspec/OrderedDependencies:
14-
Exclude:
15-
- 'babosa.gemspec'
16-
17-
# Offense count: 1
18-
# Configuration parameters: Include.
19-
# Include: **/*.gemspec
20-
Gemspec/RequiredRubyVersion:
21-
Exclude:
22-
- 'babosa.gemspec'
23-
24-
# Offense count: 1
25-
# Cop supports --auto-correct.
26-
# Configuration parameters: EnforcedStyle, IndentationWidth.
27-
# SupportedStyles: with_first_argument, with_fixed_indentation
28-
Layout/ArgumentAlignment:
29-
Exclude:
30-
- 'babosa.gemspec'
31-
32-
# Offense count: 9
33-
# Cop supports --auto-correct.
34-
# Configuration parameters: EnforcedStyle, IndentationWidth.
35-
# SupportedStyles: with_first_element, with_fixed_indentation
36-
Layout/ArrayAlignment:
37-
Exclude:
38-
- 'lib/babosa/identifier.rb'
39-
40-
# Offense count: 3
41-
# Cop supports --auto-correct.
42-
# Configuration parameters: EnforcedStyle, IndentationWidth.
43-
# SupportedStyles: special_inside_parentheses, consistent, align_braces
44-
Layout/FirstHashElementIndentation:
45-
Exclude:
46-
- 'lib/babosa/transliterator/serbian.rb'
47-
- 'spec/transliterators/vietnamese_spec.rb'
48-
49-
# Offense count: 38
509
# Cop supports --auto-correct.
5110
# Configuration parameters: AllowMultipleStyles, EnforcedHashRocketStyle, EnforcedColonStyle, EnforcedLastArgumentHashStyle.
5211
# SupportedHashRocketStyles: key, separator, table
Lines changed: 28 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,34 @@
11
module Babosa
22
module Transliterator
33
class Serbian < Latin
4-
APPROXIMATIONS = Cyrillic.const_get(:APPROXIMATIONS).merge({
5-
"Ð" => "Dj",
6-
"Č" => "Ch",
7-
"Š" => "Sh",
8-
"č" => "ch",
9-
"đ" => "dj",
10-
"š" => "sh",
11-
"Ћ" => "C",
12-
"Ц" => "C",
13-
"Ч" => "Ch",
14-
"Ђ" => "Dj",
15-
"Џ" => "Dz",
16-
"Х" => "H",
17-
"Ј" => "J",
18-
"Љ" => "Lj",
19-
"Њ" => "Nj",
20-
"ц" => "c",
21-
"ћ" => "c",
22-
"ч" => "ch",
23-
"ђ" => "dj",
24-
"џ" => "dz",
25-
"х" => "h",
26-
"ј" => "j",
27-
"љ" => "lj",
28-
"њ" => "nj"
29-
})
4+
APPROXIMATIONS = Cyrillic.const_get(:APPROXIMATIONS).merge(
5+
{
6+
"Ð" => "Dj",
7+
"Č" => "Ch",
8+
"Š" => "Sh",
9+
"č" => "ch",
10+
"đ" => "dj",
11+
"š" => "sh",
12+
"Ћ" => "C",
13+
"Ц" => "C",
14+
"Ч" => "Ch",
15+
"Ђ" => "Dj",
16+
"Џ" => "Dz",
17+
"Х" => "H",
18+
"Ј" => "J",
19+
"Љ" => "Lj",
20+
"Њ" => "Nj",
21+
"ц" => "c",
22+
"ћ" => "c",
23+
"ч" => "ch",
24+
"ђ" => "dj",
25+
"џ" => "dz",
26+
"х" => "h",
27+
"ј" => "j",
28+
"љ" => "lj",
29+
"њ" => "nj"
30+
}
31+
)
3032
end
3133
end
3234
end

0 commit comments

Comments
 (0)