vagrant-butter 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/.gitignore ADDED
@@ -0,0 +1,17 @@
1
+ *.gem
2
+ *.rbc
3
+ .bundle
4
+ .config
5
+ .yardoc
6
+ Gemfile.lock
7
+ InstalledFiles
8
+ _yardoc
9
+ coverage
10
+ doc/
11
+ lib/bundler/man
12
+ pkg
13
+ rdoc
14
+ spec/reports
15
+ test/tmp
16
+ test/version_tmp
17
+ tmp
data/Gemfile ADDED
@@ -0,0 +1,3 @@
1
+ source 'http://rubygems.org'
2
+
3
+ gemspec
data/README.md ADDED
File without changes
data/Rakefile ADDED
@@ -0,0 +1,2 @@
1
+ #!/usr/bin/env rake
2
+ require 'bundler/gem_tasks'
@@ -0,0 +1,31 @@
1
+ # coding: utf-8
2
+
3
+ require 'socket'
4
+
5
+ module Vagrant
6
+ module Butter
7
+ module Helpers
8
+ ##
9
+ # Returns the local IP address of the host running the vagrant VMs.
10
+ #
11
+ # Thanks to:
12
+ # https://github.com/jedi4ever/veewee/blob/c75a5b175c5b8ac7e5aa3341e93493923d0c7af0/lib/veewee/session.rb#L622
13
+ #
14
+ # @return [String] the local IP address
15
+ def local_ip
16
+ @local_ip ||= begin
17
+ # turn off reverse DNS resolution temporarily
18
+ orig, Socket.do_not_reverse_lookup =
19
+ Socket.do_not_reverse_lookup, true
20
+
21
+ UDPSocket.open do |s|
22
+ s.connect '64.233.187.99', 1
23
+ s.addr.last
24
+ end
25
+ ensure
26
+ Socket.do_not_reverse_lookup = orig
27
+ end
28
+ end
29
+ end
30
+ end
31
+ end
@@ -0,0 +1,7 @@
1
+ # coding: utf-8
2
+
3
+ module Vagrant
4
+ module Butter
5
+ VERSION = "0.0.1"
6
+ end
7
+ end
@@ -0,0 +1,3 @@
1
+ # coding: utf-8
2
+
3
+ require 'vagrant/butter/helpers'
@@ -0,0 +1,3 @@
1
+ # coding: utf-8
2
+
3
+ require 'vagrant-butter'
@@ -0,0 +1,19 @@
1
+ # -*- encoding: utf-8 -*-
2
+ require File.expand_path('../lib/vagrant/butter/version', __FILE__)
3
+
4
+ Gem::Specification.new do |gem|
5
+ gem.authors = ["Fletcher Nichol"]
6
+ gem.email = ["fnichol@nichol.ca"]
7
+ gem.description = %q{Smooth out Vagrantfiles with some common helpers and shims}
8
+ gem.summary = %q{Smooth out Vagrantfiles with some common helpers and shims}
9
+ gem.homepage = 'https://github.com/fnichol/vagrant-butter#readme'
10
+
11
+ gem.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
12
+ gem.files = `git ls-files`.split("\n")
13
+ gem.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
14
+ gem.name = "vagrant-butter"
15
+ gem.require_paths = ['lib']
16
+ gem.version = Vagrant::Butter::VERSION
17
+
18
+ gem.add_dependency "vagrant", "~> 0.8.2"
19
+ end
metadata ADDED
@@ -0,0 +1,65 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: vagrant-butter
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ prerelease:
6
+ platform: ruby
7
+ authors:
8
+ - Fletcher Nichol
9
+ autorequire:
10
+ bindir: bin
11
+ cert_chain: []
12
+ date: 2011-08-02 00:00:00.000000000Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: vagrant
16
+ requirement: &2157263740 !ruby/object:Gem::Requirement
17
+ none: false
18
+ requirements:
19
+ - - ~>
20
+ - !ruby/object:Gem::Version
21
+ version: 0.8.2
22
+ type: :runtime
23
+ prerelease: false
24
+ version_requirements: *2157263740
25
+ description: Smooth out Vagrantfiles with some common helpers and shims
26
+ email:
27
+ - fnichol@nichol.ca
28
+ executables: []
29
+ extensions: []
30
+ extra_rdoc_files: []
31
+ files:
32
+ - .gitignore
33
+ - Gemfile
34
+ - README.md
35
+ - Rakefile
36
+ - lib/vagrant-butter.rb
37
+ - lib/vagrant/butter/helpers.rb
38
+ - lib/vagrant/butter/version.rb
39
+ - lib/vagrant_init.rb
40
+ - vagrant-butter.gemspec
41
+ homepage: https://github.com/fnichol/vagrant-butter#readme
42
+ licenses: []
43
+ post_install_message:
44
+ rdoc_options: []
45
+ require_paths:
46
+ - lib
47
+ required_ruby_version: !ruby/object:Gem::Requirement
48
+ none: false
49
+ requirements:
50
+ - - ! '>='
51
+ - !ruby/object:Gem::Version
52
+ version: '0'
53
+ required_rubygems_version: !ruby/object:Gem::Requirement
54
+ none: false
55
+ requirements:
56
+ - - ! '>='
57
+ - !ruby/object:Gem::Version
58
+ version: '0'
59
+ requirements: []
60
+ rubyforge_project:
61
+ rubygems_version: 1.8.6
62
+ signing_key:
63
+ specification_version: 3
64
+ summary: Smooth out Vagrantfiles with some common helpers and shims
65
+ test_files: []