Class: Nanoc2::Extra::VCS
Overview
Nanoc2::Extra::VCS is a very simple representation of a version control system that abstracts the add, remove and move operations. It does not commit. This class is primarily used by data sources that store data as flat files on the disk.
This is the abstract superclass for all VCSes. Subclasses should implement the indicated methods.
Direct Known Subclasses
Nanoc2::Extra::VCSes::Bazaar, Nanoc2::Extra::VCSes::Dummy, Nanoc2::Extra::VCSes::Git, Nanoc2::Extra::VCSes::Mercurial, Nanoc2::Extra::VCSes::Subversion
Constant Summary
Constants inherited from Plugin
Instance Method Summary collapse
-
#add(filename) ⇒ Object
Adds the file with the given filename to the working copy.
-
#move(src, dst) ⇒ Object
Moves the file with the given filename to a new location.
-
#remove(filename) ⇒ Object
Removes the file with the given filename from the working copy.
Methods inherited from Plugin
identifier, identifiers, named, register
Instance Method Details
#add(filename) ⇒ Object
Adds the file with the given filename to the working copy.
Subclasses must implement this method.
15 16 17 |
# File 'lib/nanoc2/extra/vcs.rb', line 15 def add(filename) not_implemented('add') end |
#move(src, dst) ⇒ Object
Moves the file with the given filename to a new location. When this method is executed, the original file should no longer be present on the disk.
Subclasses must implement this method.
33 34 35 |
# File 'lib/nanoc2/extra/vcs.rb', line 33 def move(src, dst) not_implemented('move') end |
#remove(filename) ⇒ Object
Removes the file with the given filename from the working copy. When this method is executed, the file should no longer be present on the disk.
Subclasses must implement this method.
24 25 26 |
# File 'lib/nanoc2/extra/vcs.rb', line 24 def remove(filename) not_implemented('remove') end |