mirror of
https://github.com/middleman/middleman.git
synced 2022-11-09 12:20:27 -05:00
also "build" .htpasswd files
This commit is contained in:
parent
cad7f8a0a4
commit
c121c407df
6 changed files with 6 additions and 2 deletions
|
@ -14,6 +14,7 @@ Feature: Builder
|
||||||
| images/Read me (example).txt |
|
| images/Read me (example).txt |
|
||||||
| images/Child folder/regular_file(example).txt |
|
| images/Child folder/regular_file(example).txt |
|
||||||
| .htaccess |
|
| .htaccess |
|
||||||
|
| .htpasswd |
|
||||||
| feed.xml |
|
| feed.xml |
|
||||||
Then the following files should not exist:
|
Then the following files should not exist:
|
||||||
| _partial |
|
| _partial |
|
||||||
|
|
1
middleman-core/fixtures/large-build-app/source/.htpasswd
Normal file
1
middleman-core/fixtures/large-build-app/source/.htpasswd
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# .htpasswd
|
|
@ -220,7 +220,7 @@ module Middleman::Cli
|
||||||
|
|
||||||
paths = ::Middleman::Util.all_files_under(@destination)
|
paths = ::Middleman::Util.all_files_under(@destination)
|
||||||
@cleaning_queue += paths.select do |path|
|
@cleaning_queue += paths.select do |path|
|
||||||
!path.to_s.match(/\/\./) || path.to_s.match(/\.htaccess/)
|
!path.to_s.match(/\/\./) || path.to_s.match(/\.htaccess|\.htpasswd/)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -29,7 +29,7 @@ module Middleman
|
||||||
|
|
||||||
# Files starting with an dot, but not .htaccess
|
# Files starting with an dot, but not .htaccess
|
||||||
:source_dotfiles => proc { |file|
|
:source_dotfiles => proc { |file|
|
||||||
file.match(%r{/\.}) && !file.match(%r{/\.htaccess})
|
file.match(%r{/\.}) && !file.match(%r{/\.htaccess|\.htpasswd})
|
||||||
},
|
},
|
||||||
|
|
||||||
# Files starting with an underscore, but not a double-underscore
|
# Files starting with an underscore, but not a double-underscore
|
||||||
|
|
|
@ -11,6 +11,7 @@ Feature: Directory Index
|
||||||
| wildcard_leave_me_alone.html |
|
| wildcard_leave_me_alone.html |
|
||||||
| regular/index.html |
|
| regular/index.html |
|
||||||
| .htaccess |
|
| .htaccess |
|
||||||
|
| .htpasswd |
|
||||||
Then the following files should not exist:
|
Then the following files should not exist:
|
||||||
| egular/index/index.html |
|
| egular/index/index.html |
|
||||||
| needs_index.html |
|
| needs_index.html |
|
||||||
|
|
1
middleman-more/fixtures/indexable-app/source/.htpasswd
Normal file
1
middleman-more/fixtures/indexable-app/source/.htpasswd
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# .htpasswd
|
Loading…
Reference in a new issue