无论何时宝石,系统都找不到指定的路径

时间:2015-04-28 22:34:20

标签: ruby

我想每当gem每隔一分钟就运行一次方法。问题是,当我尝试更新它(每当-i)我得到这个错误

The system cannot find the path specified. C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/whenever-0.9.4/lib/whenever/command_line.rb:72:
in 'popen': No such file or directory - crontab - (Errno::ENOENT)   
    from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/whenever-0.9.4/lib/whenever/command_line.rb:72:in 'write_crontab'   
    from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/whenever-0.9.4/lib/whenever/command_line.rb:35:in 'run'   
    from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/whenever-0.9.4/lib/whenever/command_line.rb:6:in 'execute'   
    from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/whenever-0.9.4/bin/whenever:41:in '<top (required)>'   
    from C:/Ruby21-x64/bin/whenever:23:in 'load'
    from C:/Ruby21-x64/bin/whenever:23:in '<main>'

有人能告诉我这是什么问题吗?

1 个答案:

答案 0 :(得分:3)

鉴于错误输出中显示的目录路径,您似乎正在Windows上运行。问题是,每当gem是unix / linux命令'cron'的包装器时,它在Windows上不存在。有关详细信息,请参阅this answer