Skip to content

Instantly share code, notes, and snippets.

@uiur
Created November 14, 2011 15:46
Show Gist options
  • Select an option

  • Save uiur/1364222 to your computer and use it in GitHub Desktop.

Select an option

Save uiur/1364222 to your computer and use it in GitHub Desktop.
tex->pdfして表示するのにコマンドを叩くのめんどくさいから自分専用にRubyスクリプト書いた
#!/usr/local/bin/ruby
# encoding: UTF-8
unless ARGV[0] =~ /\.tex/
puts 'texちゃうやん'
return
end
file_name = ARGV[0].gsub(/(.*)\.tex/, '\1')
`platex #{file_name}.tex && dvipdfmx #{file_name}.dvi && open #{file_name}.pdf`
@uiur

uiur commented Nov 12, 2012

Copy link
Copy Markdown
Author

shell scriptでよさそう

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment