Created
November 14, 2011 15:46
-
-
Save uiur/1364222 to your computer and use it in GitHub Desktop.
tex->pdfして表示するのにコマンドを叩くのめんどくさいから自分専用にRubyスクリプト書いた
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/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` |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
shell scriptでよさそう