Skip to content

Instantly share code, notes, and snippets.

@kostia
Last active August 29, 2015 14:04
Show Gist options
  • Save kostia/a5e837fe81d292f5b70f to your computer and use it in GitHub Desktop.
Save kostia/a5e837fe81d292f5b70f to your computer and use it in GitHub Desktop.
#!/usr/bin/env ruby
if %x{which termit}.empty?
puts 'Missing the "termit" command.'\
' Please install the corresponding gem.'\
' See https://github.com/pawurb/termit for details.'
exit 1
end
if ARGV.empty?
puts 'Usage: en <sentence>'
exit 1
end
puts %x{termit de en '#{ARGV.join(' ')}'}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment