italian-ruby 0.8.10 → 0.8.15

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 433611007aff5c0a90a6e32dbfae70af80100cedd0887b22623b1df579182755
4
- data.tar.gz: b05901a1bac4e364a4fb96abd048d704b158f3455b1d454e7497c64cd1c57c42
3
+ metadata.gz: 0ad92503f1fb450fdc95f6f509e465c1003759a5362d7e9eba7dc5aecfa576bb
4
+ data.tar.gz: e3094c20a2ad852105050fce643b598481f48ed45d2f8ba57d90f3957c6cdef7
5
5
  SHA512:
6
- metadata.gz: d37589cdfe5bf89369f0e9daf920bdd49efd229de69188db63337e05b8bc3ebe5c2cb6b46e498c628729030746a856d88b58e0dc32ae18a63ce5c9f1bf5d50fe
7
- data.tar.gz: 24a250da1292a6f1e2826b6fbb8c0bf2af08bcb667ceeeeb64d43280951bc5377fcff746385212f33b8b44634b64e4d3646630b85d43c24ba724bc8f3386814c
6
+ metadata.gz: 47b1cc938632dfa56366e3d5c6aaa00d0ddf48a1d26787ba2bea2e33e19646f8d04116e9adad5e7a3dfb1f29c35f1eb168eaa4e1445f408190ea1977367c04b7
7
+ data.tar.gz: 3909669eb9a6b8c397ffba7908365f812f81827d957efd33f14d4628a77b0876dac7c6e911b0d88491d8605f42d4b430b018d55025a1257d902f5e871d9eaed1
@@ -70,6 +70,8 @@ class Array
70
70
  alias :inverti :reverse
71
71
  alias :lista :entries
72
72
  alias :affetta :slice
73
+ alias :salta_i_primi :drop
74
+ alias :salta_le_prime :drop
73
75
 
74
76
  def esiste?
75
77
  !nil? && !empty?
@@ -138,4 +140,4 @@ class Array
138
140
  alias :seconda :secondo
139
141
  end
140
142
 
141
- Lista = Array
143
+ Lista = Array
@@ -10,6 +10,7 @@ class Float
10
10
  alias :arrotonda :round
11
11
  alias :arrotonda_per_eccesso :ceil
12
12
  alias :arrotonda_per_difetto :floor
13
+ alias :valore_assoluto :abs
13
14
  end
14
15
 
15
- Decimale = Float
16
+ Decimale = Float
@@ -63,4 +63,4 @@ module Hanami
63
63
 
64
64
  end
65
65
  end
66
- end
66
+ end
@@ -4,30 +4,31 @@
4
4
  # Alias di metodi della classe Integer.
5
5
 
6
6
  class Integer
7
- alias :volte :times
8
- alias :in_decimale :to_f
9
- alias :in_stringa :to_s
10
- alias :in_numero :to_i
7
+ alias :volte :times
8
+ alias :in_decimale :to_f
9
+ alias :in_stringa :to_s
10
+ alias :in_numero :to_i
11
+ alias :valore_assoluto :abs
11
12
 
12
13
  def secondi
13
14
  self
14
15
  end
15
- alias :secondo :secondi
16
+ alias :secondo :secondi
16
17
 
17
18
  def minuti
18
19
  self.secondi * 60
19
20
  end
20
- alias :minuto :minuti
21
+ alias :minuto :minuti
21
22
 
22
23
  def ore
23
24
  self.minuti * 60
24
25
  end
25
- alias :ora :ore
26
+ alias :ora :ore
26
27
 
27
28
  def giorni
28
29
  self.ore * 24
29
30
  end
30
- alias :giorno :giorni
31
+ alias :giorno :giorni
31
32
 
32
33
  def fa
33
34
  Time.now - self
@@ -38,4 +39,4 @@ class Integer
38
39
  end
39
40
  end
40
41
 
41
- Intero = Integer
42
+ Intero = Integer
@@ -1,3 +1,5 @@
1
+ require "fileutils"
2
+
1
3
  ##
2
4
  # CoreExt - Kernel
3
5
  #
@@ -58,7 +60,7 @@ module Kernel
58
60
  end
59
61
  raise LoadError.new("cannot load such directory -- #{dir}") unless Dir.exist? caller_location_dir
60
62
 
61
- Dir["#{caller_location_dir}/**/*.ir"].each do |file|
63
+ Dir["#{caller_location_dir}/**/*.ir"].sort_by { |file| file.count("/") }.each do |file|
62
64
  richiedi_assoluto file
63
65
  end
64
66
  end
@@ -106,4 +108,4 @@ module Kernel
106
108
  end
107
109
  end
108
110
 
109
- end
111
+ end
@@ -4,6 +4,7 @@
4
4
  # Alias di metodi del namespace principale.
5
5
 
6
6
  alias :stampa :puts
7
+ alias :scrivi :print
7
8
  alias :cicla :loop
8
9
  alias :definisci_metodo_singolo :define_singleton_method
9
10
  alias :blocco_dato? :block_given?
@@ -26,4 +27,4 @@ def alza(*args)
26
27
  end
27
28
  def fallisci(*args)
28
29
  fail *args
29
- end
30
+ end
@@ -9,10 +9,12 @@ class Range
9
9
  alias :per_ognuna :each
10
10
  alias :mappa :map
11
11
  alias :in_lista :to_a
12
+ alias :conteggio :count
13
+ alias :lunghezza :count
12
14
 
13
15
  def non_include?(*args)
14
16
  !include? *args
15
17
  end
16
18
  end
17
19
 
18
- Intervallo = Range
20
+ Intervallo = Range
@@ -9,6 +9,8 @@ class String
9
9
  alias :in_simbolo :to_sym
10
10
  alias :in_stringa :to_s
11
11
  alias :in_numero :to_i
12
+ alias :in_intero :to_i
13
+ alias :in_decimale :to_f
12
14
  alias :dividi :split
13
15
  alias :maiuscola :upcase
14
16
  alias :maiuscolo :upcase
@@ -55,4 +57,4 @@ class String
55
57
  end
56
58
  end
57
59
 
58
- Stringa = String
60
+ Stringa = String
@@ -1,5 +1,5 @@
1
1
  module Italian
2
2
  module Ruby
3
- VERSION = "0.8.10"
3
+ VERSION = "0.8.15"
4
4
  end
5
5
  end
@@ -0,0 +1 @@
1
+ au BufRead,BufNewFile *.ir set filetype=ir
@@ -0,0 +1,51 @@
1
+ " Vim syntax file
2
+ " Language: Italian Ruby
3
+ " Maintainer: Francesco Ballardin
4
+ " Latest Revision: 01 July 2020
5
+
6
+ if exists("b:current_syntax")
7
+ finish
8
+ endif
9
+
10
+ syn match italianRubyKeyword /\v(\s|^)(classe|modulo|esegui)\s/me=e-1
11
+ syn match italianRubyKeyword /\v(\s|^)(se|allora|altrimenti_se|a_meno_che|considera|quando|finché|in|definito\?)\s/me=e-1
12
+ syn match italianRubyKeyword /\v(\s|^)(prossimo|prossima|esci|ritorna|rilascia|recupera)\s/me=e-1
13
+ syn match italianRubyKeyword /\v(\s|^)(se|allora|altrimenti|a_meno_che|considera|esci|ritorna|rilascia|blocco_dato\?)$/
14
+ syn match italianRubyKeyword /\v(\s|^)(inizia|recupera|assicura|riprova|esegui|fine)$/
15
+
16
+ syn region italianRubyDefinition start=/definisci/ end=/[$\n\(]/ contains=italianRubySymbol,italianRubyConstant,italianRubyNumeric,italianRubySpecial,italianRubySplatOperator
17
+ syn match italianRubyMethodName /\v([a-z0-9_=\?\!àèéìòù]+)/ contained containedin=italianRubyDefinition
18
+ syn match italianRubyDefinitionKeyword /\vdefinisci/ contained containedin=italianRubyDefinition
19
+ syn match italianRubyClassMethodPrefix /\v(se_stesso|se_stessa)\./he=e-1 contained containedin=italianRubyDefinition
20
+ syn match italianRubySplatOperator /\v(\*{1,2}[a-zA-Z0-9_])/he=e-1
21
+
22
+ syn match italianRubySymbol /\v(\s|^)([a-zè_][a-zA-Z0-9àèéìòù_"]+:)/
23
+ syn match italianRubySymbol /\v(\s|^)("[a-zA-Z0-9àèéìòù_]+":)/
24
+ syn match italianRubySymbol /\v(\s|^)(:[a-zè_"][a-zA-Z0-9àèéìòù_"]+)/
25
+ syn match italianRubySymbol /\v(\(|\[)([a-zè_][a-zA-Z0-9àèéìòù_"]+:)/hs=s+1
26
+ syn match italianRubySymbol /\v(\(|\[)("[a-zA-Z0-9àèéìòù_]+":)/hs=s+1
27
+ syn match italianRubySymbol /\v(\(|\[|\&)(:[a-zè_"][a-zA-Z0-9àèéìòù_"]+)/hs=s+1
28
+
29
+ syn match italianRubyInstanceVar /\v\@[a-zè_][a-zA-Z0-9àèéìòù_"]*/
30
+ syn match italianRubyConstant /\v[A-Z][a-zA-Z0-9àèéìòùÀÈÌÒÙ_]+/
31
+ syn match italianRubyComment /\v#.*$/
32
+
33
+ syn match italianRubyNumeric /\v(\s)+([0-9\.]+)/
34
+ syn match italianRubyInterpolationStart /\v#\{/ contained containedin=italianRubyInterpolation
35
+ syn match italianRubyInterpolationStop /\v\}/ contained containedin=italianRubyInterpolation
36
+ syn region italianRubyInterpolation start=/\v#\{/ end=/\v\}/ contains=TOP,italianRubyComment contained keepend
37
+ syn region italianRubyString start=/"/ end=/"/ skip=/\\"/ contains=italianRubyInterpolation
38
+
39
+ syn match italianRubySpecial /\v(\s|^)(includi|estendi|preponi)(\s|$)/
40
+ syn match italianRubySpecial /\v(\s|^)(pubblici|protetti|privati)(\s|$)/
41
+ syn match italianRubySpecial /\v(\s|^)(richiedi|richiedi_relativo|richiedi_tutti)(\s|$)/
42
+ syn match italianRubySpecial /\v(\s|^)(cicla|alza)(\s|$)/
43
+ syn match italianRubySpecial /\v(\s|^)(cattura|lancia)/
44
+ syn match italianRubySpecial /\v\.(nuovo|nuova)(\s|\,|\()/hs=s+1,he=e-1,me=e-1
45
+ syn match italianRubySpecial /\v\.(nuovo|nuova)\)/hs=s+1,he=e-1
46
+ syn match italianRubySpecial /\v\.(nuovo|nuova)$/hs=s+1
47
+ syn match italianRubySpecial /\v(se_stesso|se_stessa)/
48
+ syn match italianRubySpecial /\v(\s)+(si|no|nullo|nulla)(\s|$)/
49
+ syn match italianRubySpecial /\v(\s)+(si|no|nullo|nulla)(\W)/he=e-1
50
+
51
+ let b:current_syntax = "ir"
@@ -0,0 +1,47 @@
1
+ ""
2
+ " Imposta dimensione tabulazione
3
+ set tabstop=2
4
+ set shiftwidth=2
5
+ set expandtab
6
+ set nu
7
+
8
+ ""
9
+ " Comando per aprire nuovo tab
10
+ command! -complete=file -nargs=1 T tabedit <args>
11
+
12
+ ""
13
+ " Muoversi fra tab con H (sinistra) e L (destra)
14
+ nnoremap H gT
15
+ nnoremap L gt
16
+
17
+ ""
18
+ " Aggiunge automaticamente indentazione su nuova riga
19
+ set autoindent
20
+
21
+ ""
22
+ " Evidenzia risultati ricerca
23
+ set hlsearch
24
+
25
+ ""
26
+ " Mostra opzioni sopra la linea di comando
27
+ set wildmenu
28
+
29
+ ""
30
+ " Evidenziazione sintassi ItalianRuby
31
+ syntax on
32
+
33
+ highlight italianRubyKeyword ctermfg=171
34
+ highlight italianRubyDefinitionKeyword ctermfg=171
35
+ highlight italianRubySpecial ctermfg=33
36
+ highlight italianRubyClassMethodPrefix ctermfg=33
37
+ highlight italianRubyMethod ctermfg=220
38
+ highlight italianRubyMethodName ctermfg=220
39
+ highlight italianRubySymbol ctermfg=33
40
+ highlight italianRubyNumeric ctermfg=148
41
+ highlight italianRubySplatOperator ctermfg=117
42
+ highlight italianRubyInstanceVar ctermfg=117
43
+ highlight italianRubyInterpolationStart ctermfg=117
44
+ highlight italianRubyInterpolationStop ctermfg=117
45
+ highlight italianRubyConstant ctermfg=43
46
+ highlight italianRubyComment ctermfg=28
47
+ highlight italianRubyString ctermfg=208
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: italian-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.10
4
+ version: 0.8.15
5
5
  platform: ruby
6
6
  authors:
7
7
  - Francesco Ballardin
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-06-30 00:00:00.000000000 Z
11
+ date: 2020-07-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -106,6 +106,9 @@ files:
106
106
  - lib/italian/ruby/traduttore.rb
107
107
  - lib/italian/ruby/utils/debug.rb
108
108
  - lib/italian/ruby/version.rb
109
+ - vim/ftdetect/ir.vim
110
+ - vim/syntax/ir.vim
111
+ - vim/vimrc
109
112
  - vscode/italianruby.tmGrammar.json
110
113
  homepage: https://github.com/Pluvie/italian-ruby
111
114
  licenses: