Created
December 19, 2016 08:27
-
-
Save walterheck/9ddc42ef9bcdfa27741b34303f53d26b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
walterheck@walter-envy:~/source/opstheater/deploy/vagrant-oscar$ vagrant provision foss-master | |
Vagrant failed to initialize at a very early stage: | |
There was an error loading a Vagrantfile. The file being loaded | |
and the error message are shown below. This is usually caused by | |
a syntax error. | |
Path: /home/walterheck/Dropbox/Source/opstheater/deploy/vagrant-oscar/Vagrantfile | |
Line number: 4 | |
Message: LoadError: cannot load such file -- git | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'rubygems' | |
require 'git' | |
git = Git.open(Dir.pwd + "../../..") | |
ENV['GIT_BRANCH'] = ENV['GIT_BRANCH'] || git.current_branch |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
walterheck@walter-envy:~/source/opstheater/deploy/vagrant-oscar$ irb | |
irb(main):001:0> require 'git' | |
=> true | |
irb(main):002:0> Git.open(Dir.pwd + "../../..").current_branch | |
=> "refactoring" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment