Module: VRundler

Defined in:
lib/vrundler/bundle.rb,
lib/vrundler/bundles.rb,
lib/vrundler/version.rb,
lib/vrundler/vrundler.rb,
lib/vrundler/basic_bundle.rb,
lib/vrundler/bundle_group.rb,
lib/vrundler/vim_zip_group.rb,
lib/vrundler/symlink_bundle.rb,
lib/vrundler/vim_zip_bundle.rb,
lib/vrundler/vim_script_group.rb,
lib/vrundler/script_type_group.rb,
lib/vrundler/vim_script_bundle.rb

Defined Under Namespace

Modules: BasicBundle Classes: Bundle, BundleGroup, Bundles, ScriptTypeGroup, SymlinkBundle, VimScriptBundle, VimScriptGroup, VimZipBundle, VimZipGroup

Constant Summary collapse

VERSION =
"0.2.1"

Instance Method Summary collapse

Instance Method Details

#bundles_dir(path) ⇒ Object



2
3
4
# File 'lib/vrundler/vrundler.rb', line 2

def bundles_dir(path)
  Bundles.bundles_dir path
end

#configure(item, &block) ⇒ Object



28
29
30
31
# File 'lib/vrundler/vrundler.rb', line 28

def configure(item, &block)
  item.instance_eval(&block)
  item
end

#git(user_clone_url, &block) ⇒ Object



6
7
8
# File 'lib/vrundler/vrundler.rb', line 6

def git(user_clone_url, &block)
  group(user_clone_url, &block)
end

#group(name, &block) ⇒ Object



33
34
35
36
# File 'lib/vrundler/vrundler.rb', line 33

def group(name, &block)
  item = BundleGroup.new(name)
  configure(item, &block)
end

Yields:



20
21
22
23
24
25
# File 'lib/vrundler/vrundler.rb', line 20

def symlink(destination_folder_key, source_path)
  bundle = SymlinkBundle.new(destination_folder_key, source_path)
  Bundles << bundle
  yield bundle, Bundles if block_given?
  bundle
end

#vimscripts(&block) ⇒ Object



10
11
12
13
# File 'lib/vrundler/vrundler.rb', line 10

def vimscripts(&block)
  vim_script_group = VimScriptGroup.new
  configure(vim_script_group, &block)
end

#vimzips(&block) ⇒ Object



15
16
17
18
# File 'lib/vrundler/vrundler.rb', line 15

def vimzips(&block)
  zip_group = VimZipGroup.new
  configure(zip_group, &block)
end