All methods are static.
'~'
10 11 12 13 14 15 16
# File 'lib/renamr/utils.rb', line 10 def trim(src, lim) return src if src.length <= lim beg = fin = (lim - SEP.length) / 2 beg -= 1 if lim.odd? src[0..beg] + SEP + src[-fin..-1] end