Sha256: 9c8a4e73839a2a34cb710f8d9c790b928e82071240679b4a51c4302054f6172f

Contents?: true

Size: 314 Bytes

Versions: 2

Compression:

Stored size: 314 Bytes

Contents

require 'space2underscore/version'

module Space2underscore
  class << self
    def convert(argv)
      argv.length == 1 ? argv[0].strip.gsub(/\s/,  '_') : argv.join('_')
    end

    def generate_command(space_include_sentence)
      "echo #{space_include_sentence} | ruby -pe 'chomp' | pbcopy"
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
space2underscore-0.1.6 lib/space2underscore.rb
space2underscore-0.1.5 lib/space2underscore.rb