Class: OsCtld::Assets::Symlink
- Inherits:
-
Assets::BaseFile
- Object
- Assets::BaseFile
- OsCtld::Assets::Symlink
- Defined in:
- lib/osctld/assets/symlink.rb
Instance Method Summary collapse
- #stat ⇒ Object protected
- #validate(run) ⇒ Object protected
Instance Method Details
#stat ⇒ Object (protected)
19 20 21 |
# File 'lib/osctld/assets/symlink.rb', line 19 def stat @stat ||= File.lstat(path) end |
#validate(run) ⇒ Object (protected)
9 10 11 12 13 14 15 16 17 |
# File 'lib/osctld/assets/symlink.rb', line 9 def validate(run) begin add_error('not a symlink') if exist? && !stat.symlink? rescue Errno::ENOENT add_error('does not exist') end super end |