Sha256: ea993becc83e6b728edac46e48ec0ae04fd028a2ceeade9fad0d09fe5dcb7431

Contents?: true

Size: 1.06 KB

Versions: 1

Compression:

Stored size: 1.06 KB

Contents

#!/usr/bin/env ruby

$:.unshift File.dirname(__FILE__) + '/../lib'
require "slop"
require 'vundle_migrator'
require 'vundle_migrator/version'

opts = Slop.parse do |o|
  o.banner = "usage: vundle_migrate vimrc-location [OPTIONS]"
  o.string '-l', '--vimrc-location', 'Required - Used to add a line to your vimrc that sources the final plugins.vim'
  o.string '-b', '--bundle-location', 'Optional - Used to build the list of plugins. Default: ~/.vim/bundle'
  o.string '-d', '--destination', 'Optional - Used as the destination of the plugins file. Default: ~/.vim/vundle/plugins.vim'
  o.bool '-r', '--dry-run', 'displays the results of creating the plugins.vim without modifying files'
  o.bool '-h', '--help', 'displays this page'
  o.on '-v', '--version', 'displays the version' do
    puts VundleMigrator::VERSION
    exit
  end
end

if ARGV.count.zero? || opts.help?
  puts opts
  exit
end

if opts[:vimrc_location].nil?
  puts "Please provide a vimrc location with the -l flag"
  exit
end

if opts.dry_run?
  VundleMigrator.dry_run(opts)
else
  VundleMigrator.migrate(opts)
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
vundle_migrator-0.0.2 bin/vundle_migrator