From dcca8968c8905185bc295dbac444e5e689c345fe Mon Sep 17 00:00:00 2001 From: justin blecher Date: Wed, 12 Nov 2014 19:12:52 -0500 Subject: [PATCH] exclude .git folder when init'ing a local template freshly init'd middleman projects from a local template should not include the git files from that template because that's confusing. this is to help users who clone git repos into `~/.middleman/`. --- middleman-core/lib/middleman-core/templates/local.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/middleman-core/lib/middleman-core/templates/local.rb b/middleman-core/lib/middleman-core/templates/local.rb index 9d8c5594..ee9ab58a 100644 --- a/middleman-core/lib/middleman-core/templates/local.rb +++ b/middleman-core/lib/middleman-core/templates/local.rb @@ -9,7 +9,7 @@ class Middleman::Templates::Local < Middleman::Templates::Base # Just copy from the template path # @return [void] def build_scaffold! - directory options[:template].to_s, location, force: options[:force] + directory options[:template].to_s, location, force: options[:force], exclude_pattern: /\.git\/.*/ end end