Class: Jekyll::Site::Cleaner
- Inherits:
-
Object
- Object
- Jekyll::Site::Cleaner
- Defined in:
- lib/jekyll/cleaner.rb
Overview
Handles the cleanup of a site’s destination before it is built.
Instance Method Summary collapse
-
#cleanup! ⇒ Object
Cleans up the site’s destination directory.
-
#initialize(site) ⇒ Cleaner
constructor
A new instance of Cleaner.
Constructor Details
#initialize(site) ⇒ Cleaner
Returns a new instance of Cleaner.
7 8 9 |
# File 'lib/jekyll/cleaner.rb', line 7 def initialize(site) @site = site end |
Instance Method Details
#cleanup! ⇒ Object
Cleans up the site’s destination directory
12 13 14 |
# File 'lib/jekyll/cleaner.rb', line 12 def cleanup! FileUtils.rm_rf(obsolete_files) end |