Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add dotfiles support #498

merged 8 commits into from Dec 13, 2014

use concat instead of +=

  • Loading branch information...
mpapis committed Dec 6, 2014
commit 1782d70b0c76adcaf0e354c2d759eb91e3a1bb54
@@ -104,7 +104,7 @@ def all_files_and_dirs_in(dir_name, extra_files)
when String
patterns << "#{dir_name}/#{extra_files}"
when Array
patterns += { |extra_file| "#{dir_name}/#{extra_file}" }
patterns.concat( { |extra_file| "#{dir_name}/#{extra_file}" })

This comment has been minimized.

Copy link

mpapis Dec 6, 2014

Author Member

now, is << and concat ok, or should I change << to concat([...])?

This comment has been minimized.

Copy link

ddfreyne Dec 13, 2014


Yup, that’s OK. It doesn’t make sense to use #concat when appending only a single element.

raise Nanoc::Errors::GenericTrivial,
"Do not know how to handle extra_files: #{extra_files.inspect}"
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.