greeklish 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 1ab370892f9c7e570ab8f9407d58534cdb3be66a
4
- data.tar.gz: 36cfd3be6b235801e733adbccf7935917a12d929
3
+ metadata.gz: 5c681820e7d12fece0bbb676b00f26f94d97056d
4
+ data.tar.gz: 81114c6830efc85968350b4b0269465680bc2d70
5
5
  SHA512:
6
- metadata.gz: c5298e282e8a5b831086eda8a6156224a8c92a0ebb456a7b2980f7998ffac4b1faf53dc4736d5eb0f20e687bcd8b0b778d99f299ed4a6e5388940e55c332f74e
7
- data.tar.gz: 83762172ec19a073afd9545dd097d81d5dece088ad0c5df28482fdf9c6be96237c9359dbf0808415a8f60178650433082f88246d609c86b2af5b8c88320f4c7c
6
+ metadata.gz: 4b8944768c1daad732b7799b2f2a04b49ea15d6a585f5aebc0bb990b4a48a72c82894211bd2baa7fb5c11ab2733259984415239334b70fc6f78060594858f9bb
7
+ data.tar.gz: 2516d33a8be6ca4d10349006d3fc17dbc5a87a4fa472b9b243e015085cf80279e184cc23e4921447ad260d0413d1d5681f6756e7f25ca9aec1e494aa5a212790
@@ -44,6 +44,10 @@ module Greeklish
44
44
  # @param token_length the length of the input token
45
45
  # @return A list of the generated strings
46
46
  def convert(input_token)
47
+ if (input_token[-1, 1] == "ς")
48
+ input_token[-1, 1] = "σ"
49
+ end
50
+
47
51
  # Is this a Greek word?
48
52
  if (!identify_greek_word(input_token))
49
53
  return nil
@@ -1,3 +1,3 @@
1
1
  module Greeklish
2
- VERSION = "0.0.1"
2
+ VERSION = "0.0.2"
3
3
  end
@@ -7,7 +7,7 @@ describe 'GreeklishConverter' do
7
7
 
8
8
  # a sample of greek words to generate their greeklish
9
9
  # counterparts.
10
- greek_words = ["αυτοκινητο", "ομπρελα", "ξεσκεπαστοσ"]
10
+ greek_words = ["αυτοκινητο", "ομπρελα", "ξεσκεπαστοσ", "ομορφος"]
11
11
 
12
12
  # the greeklish counterparts that should be generated from the greek words.
13
13
  generated_greeklish_words = [
@@ -15,11 +15,16 @@ describe 'GreeklishConverter' do
15
15
  "autokinito", "aftokinito", "avtokinito", "aytokinito",
16
16
  "autokinhtwn", "aftokinhta", "avtokinhta", "aytokinhtwn"],
17
17
  ["omprela", "obrela", "ompreles", "obrelwn", "obreles", "omprelas"],
18
- ["kseskepastos", "xeskepastos", "kseskepastou", "xeskepastwn", "kseskepastoi"]
18
+ ["kseskepastos", "xeskepastos", "kseskepastou", "xeskepastwn", "kseskepastoi"],
19
+ ["omorfos", "omorphos", "omorfh", "omorphh", "omorfi", "omorphi", "omorfous",
20
+ "omorphous", "omorfoys", "omorphoys", "omorfus", "omorphus", "omorfou",
21
+ "omorphou", "omorfoy", "omorphoy", "omorfu", "omorphu", "omorfoi", "omorphoi",
22
+ "omorfi", "omorphi", "omorfwn", "omorphwn", "omorfon", "omorphon", "omorfvn",
23
+ "omorphvn"]
19
24
  ]
20
25
 
21
26
  # these words should not be processed by the converter.
22
- invalid_words = ["mobile", "αυριο64", "καλάθι", "ΣΠιτι", "ομορφος" ]
27
+ invalid_words = ["mobile", "αυριο64", "καλάθι", "ΣΠιτι"]
23
28
 
24
29
  before(:each) do
25
30
  @greeklish_words = []
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: greeklish
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Petros Markou
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-04-02 00:00:00.000000000 Z
11
+ date: 2016-08-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -96,7 +96,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
96
96
  version: '0'
97
97
  requirements: []
98
98
  rubyforge_project:
99
- rubygems_version: 2.4.6
99
+ rubygems_version: 2.4.7
100
100
  signing_key:
101
101
  specification_version: 4
102
102
  summary: Generates greeklish forms
@@ -106,4 +106,3 @@ test_files:
106
106
  - spec/greeklish_reverse_stemmer_spec.rb
107
107
  - spec/greeklish_spec.rb
108
108
  - spec/spec_helper.rb
109
- has_rdoc: