Merge pull request #2445 from tmatilai/debug_cli_option

core: Add `--debug` option as a shortcut for `VAGRANT_LOG=debug`
This commit is contained in:
Mitchell Hashimoto 2013-11-23 11:41:20 -08:00
commit c49a4d6a1f
2 changed files with 15 additions and 0 deletions

View File

@ -5,6 +5,13 @@
# initializing which have historically resulted in stack traces.
Signal.trap("INT") { exit 1 }
# Set logging level to `debug`. This is done before loading 'vagrant', as it
# sets up the logging system.
if ARGV.include?("--debug")
ARGV.delete("--debug")
ENV["VAGRANT_LOG"] = "debug"
end
require 'log4r'
require 'vagrant'
require 'vagrant/cli'

View File

@ -37,6 +37,14 @@ $ vagrant up
...
```
You can also get the debug level output using the `--debug` command line
option. For example:
```
$ vagrant up --debug
...
```
If you plan on submitting a bug report, please submit debug-level logs
along with the report using [gist](https://gist.github.com/) or
some other paste service.