Class: Vimpack::Models::Base
- Inherits:
-
Object
- Object
- Vimpack::Models::Base
- Extended by:
- Utils::File, Utils::Git
- Defined in:
- lib/vimpack/models/base.rb
Class Attribute Summary collapse
-
.attributes(*attribute_names) ⇒ Object
readonly
Returns the value of attribute attributes.
Attributes included from Utils::File
#bundle_path, #home_path, #pack_path, #script_path, #vim_path
Instance Method Summary collapse
-
#initialize(attributes = Hash.new) ⇒ Base
constructor
A new instance of Base.
Methods included from Utils::Git
add_submodule, init_repo, init_submodule, remove_submodule, replace_contents, repo_add_dot, repo_add_remote, repo_clone, repo_commit, repo_exec, repo_pull, repo_push, repo_remote?, sanitize_commands, update_submodule
Methods included from Utils::Process
#run_process!, #run_process_and_wait!, #run_process_or_die!, #wait_for_child, #within_dir
Methods included from Utils::Io
#die!, #exit_with_error!, #say, #scream
Methods included from Utils::File
create_link, directory_exists?, file_exists?, make_dir, move_path, remove_directory, remove_link, setup_paths, symlink_exists?, template, template_path
Constructor Details
#initialize(attributes = Hash.new) ⇒ Base
Returns a new instance of Base.
21 22 23 24 25 |
# File 'lib/vimpack/models/base.rb', line 21 def initialize(attributes = Hash.new) attributes.each do |name, value| send("#{name}=".to_sym, value) end end |
Class Attribute Details
.attributes(*attribute_names) ⇒ Object (readonly)
Returns the value of attribute attributes.
10 11 12 |
# File 'lib/vimpack/models/base.rb', line 10 def attributes @attributes end |