Skip to content

Instantly share code, notes, and snippets.

@asonas
Created February 16, 2012 04:01
Show Gist options
  • Save asonas/1841858 to your computer and use it in GitHub Desktop.
Save asonas/1841858 to your computer and use it in GitHub Desktop.
watchrもうそう
watchr watchr.rb
watchr.rbでファイルを取得してrake spec hogehoge.rbとする
いめーじこんなかんじ。
watch('(.*).rb') { |f| run("echo #{f[0]}") }
@asonas
Copy link
Author

asonas commented Feb 16, 2012

if File.exist?(file_path)
  run file_path
end

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