Jekyll 'new' command fixes #856

Merged
merged 4 commits into from Mar 13, 2013

2 participants

@cazrin
  • Fixes the issue with FileUtils.cp_r and a glob of files
  • Now raises an ArgumentError if no args are provided (there was a failing test for this in the new implementation)
@cazrin cazrin referenced this pull request Mar 13, 2013
Merged

`jekyll new`: scaffold site generator #764

3 of 3 tasks complete
Daniel Grieve update safe_yaml 5bcc2fd
@parkr parkr commented on the diff Mar 13, 2013
lib/jekyll/commands/new.rb
def self.process(args)
+ raise ArgumentError.new('You must specify a path.') if args.empty?
@parkr
Jekyll member
parkr added a line comment Mar 13, 2013

Great catch!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
@parkr parkr commented on the diff Mar 13, 2013
lib/jekyll/commands/new.rb
@@ -28,23 +29,18 @@ def self.initialized_post_name
end
private
+ def self.create_sample_files(path)
+ FileUtils.cp_r site_template + '/.', path
@parkr
Jekyll member
parkr added a line comment Mar 13, 2013

Why concatenation and not interpolation here?

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

Bravo! I had one question above, but it doesn't have any effect on the effectiveness of this refactoring. Thanks, man!

@parkr parkr merged commit 5bde4a3 into jekyll:jekyll-new Mar 13, 2013

1 check passed

Details default The Travis build passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment