FileUtils:ArgumentError:参数个数错误(2个为1)

时间:2015-06-22 16:02:16

标签: ruby

我定义了:

srcen = 'docs/tmp/en-US/html'
targeten = "#{home}/RubymineProjects/saigkill.github.com/docs/make_test_release/en-US/html"

我正在使用:

FileUtils.cp_r(Dir["#{srcen}/*"], "#{targeten}")

但是,如果我正在运行这个,我会得到一个" ArgumentError",但我不知道为什么。 FileUtils.cp_r有两个论点。

完整错误是:

sascha@sascha-desktop:~/RubymineProjects/make_test_release$ rake publish_doc
Copying source html files to target git repository
rake aborted! ArgumentError: wrong number of arguments (2 for 1)
/home/sascha/.rvm/gems/ruby-2.2.1/gems/dir-0.1.2/lib/dir.rb:7:in `entries'
/home/sascha/RubymineProjects/make_test_release/Rakefile:150:in `block in <top (required)>'
/home/sascha/.rvm/gems/ruby-2.2.1/bin/ruby_executable_hooks:15:in `eval'
/home/sascha/.rvm/gems/ruby-2.2.1/bin/ruby_executable_hooks:15:in `<main>'
Tasks: TOP => publish_doc (See full trace by running task with --trace)

0 个答案:

没有答案