vagrant-save 0.2.7 → 0.2.8

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 42ff5bfda3de74ddd3d9ffe0b0904512acf86592
4
- data.tar.gz: 839db02248a34e55080b454477d3419ec4458e29
3
+ metadata.gz: cbb70882ed147e983a61e4a8d71ff3792fb11acc
4
+ data.tar.gz: 9cbb2b2f60f2e7a47a75fa7684f0fbd80bd90902
5
5
  SHA512:
6
- metadata.gz: dd5b662c604e5202c2b53f3a1c2f7dc1daaaeeaf01f0356aab9296f1f40581b840b8ca20a7724247cc6ca9c3059638393602e066f0c9e94a7aa9ee54a3e653d6
7
- data.tar.gz: 0f953acedac4e051360ff279ad91239d3891914eb723baa4f5280f4d7d65fd991ff64f72cb94d15284228a36c9b82be5b9318ed33a0d51993f2aef9cf43a6cce
6
+ metadata.gz: 5436eab73dd9ee675c626c4ea42606c644c6a22973d124e36766107e328a853f3794716d46705bd365fce0a69ddcc0151949161f4b8defbf43bfa0bcbbe0ab72
7
+ data.tar.gz: dd836c4a22a466800e93bd8f202f61cfc56a3f7fb05ad855b38cb05d09dce3bd86ef83e4447e39551d6addcc547e858413ec97d449e1cf330ff9032201a46ec2
data/Gemfile CHANGED
@@ -1,11 +1,11 @@
1
- source 'https://rubygems.org'
2
-
3
- group :development do
4
- gem 'vagrant', git: 'https://github.com/mitchellh/vagrant.git'
5
- end
6
-
7
- gem 'vagrant-export', '>= 0.3.4', git: 'https://github.com/trenker/vagrant-export.git'
8
-
9
- group :plugins do
10
- gem 'vagrant-save', path: '.'
11
- end
1
+ source 'https://rubygems.org'
2
+
3
+ group :development do
4
+ gem 'vagrant', git: 'https://github.com/mitchellh/vagrant.git'
5
+ end
6
+
7
+ gem 'vagrant-export', '>= 0.3.4', git: 'https://github.com/trenker/vagrant-export.git'
8
+
9
+ group :plugins do
10
+ gem 'vagrant-save', path: '.'
11
+ end
data/README.md CHANGED
@@ -1,73 +1,73 @@
1
- # vagrant-save
2
-
3
- This is a simple plugin to export boxes into .box files using [vagrant-export](https://github.com/trenker/vagrant-export) and pushes that file to a [boxserver](https://github.com/trenker/boxserver) instance.
4
-
5
- ## Installation
6
-
7
- Like with any other vagrant plugin:
8
-
9
- ```bash
10
- vagrant plugin install vagrant-save
11
- ```
12
-
13
- ## Usage
14
-
15
- Have a [boxserver](https://github.com/trenker/boxserver) instance running and set the property `config.vm.box_server_url` to its address in your vagrant file. So your `Vagrantfile` contains the following statements:
16
-
17
- ```ruby
18
- Vagrant.configure("2") do |config|
19
- # This must be set
20
- config.vm.box_server_url = "http://localhost:8001"
21
- end
22
- ```
23
-
24
- Then just run
25
-
26
- ```bash
27
- vagrant save
28
- ```
29
-
30
- to release a new version of your box.
31
-
32
- By default, it increases the bugfix version number by one. So an installed 1.0.0 becomes 1.0.1. You can specify the version yourself using the parameter `-v|--version`, like this:
33
-
34
- ```bash
35
- vagrant save -v 1.2.0
36
- ```
37
-
38
- The parameter must always have all three digits and must be greater than the installed version.
39
-
40
- You may want to clean up the boxserver by deleting old versions. The `-k|--keep` parameter sets how many versions to keep. The versions are sorted in descending order, older than the newest X will be deleted:
41
-
42
- ```bash
43
- # Keeping the last six versions
44
- vagrant save -k 6
45
-
46
- # Keeping all versions
47
- # Does not need to be written, as it is the default setting
48
- vagrant save -k 0
49
- ```
50
-
51
- ## License
52
-
53
- The MIT License (MIT)
54
-
55
- Copyright (c) 2014 Georg Großberger
56
-
57
- Permission is hereby granted, free of charge, to any person obtaining a copy
58
- of this software and associated documentation files (the "Software"), to deal
59
- in the Software without restriction, including without limitation the rights
60
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
61
- copies of the Software, and to permit persons to whom the Software is
62
- furnished to do so, subject to the following conditions:
63
-
64
- The above copyright notice and this permission notice shall be included in
65
- all copies or substantial portions of the Software.
66
-
67
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
68
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
69
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
70
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
71
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
72
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
73
- THE SOFTWARE.
1
+ # vagrant-save
2
+
3
+ This is a simple plugin to export boxes into .box files using [vagrant-export](https://github.com/trenker/vagrant-export) and pushes that file to a [boxserver](https://github.com/trenker/boxserver) instance.
4
+
5
+ ## Installation
6
+
7
+ Like with any other vagrant plugin:
8
+
9
+ ```bash
10
+ vagrant plugin install vagrant-save
11
+ ```
12
+
13
+ ## Usage
14
+
15
+ Have a [boxserver](https://github.com/trenker/boxserver) instance running and set the property `config.vm.box_server_url` to its address in your vagrant file. So your `Vagrantfile` contains the following statements:
16
+
17
+ ```ruby
18
+ Vagrant.configure("2") do |config|
19
+ # This must be set
20
+ config.vm.box_server_url = "http://localhost:8001"
21
+ end
22
+ ```
23
+
24
+ Then just run
25
+
26
+ ```bash
27
+ vagrant save
28
+ ```
29
+
30
+ to release a new version of your box.
31
+
32
+ By default, it increases the bugfix version number by one. So an installed 1.0.0 becomes 1.0.1. You can specify the version yourself using the parameter `-v|--version`, like this:
33
+
34
+ ```bash
35
+ vagrant save -v 1.2.0
36
+ ```
37
+
38
+ The parameter must always have all three digits and must be greater than the installed version.
39
+
40
+ You may want to clean up the boxserver by deleting old versions. The `-k|--keep` parameter sets how many versions to keep. The versions are sorted in descending order, older than the newest X will be deleted:
41
+
42
+ ```bash
43
+ # Keeping the last six versions
44
+ vagrant save -k 6
45
+
46
+ # Keeping all versions
47
+ # Does not need to be written, as it is the default setting
48
+ vagrant save -k 0
49
+ ```
50
+
51
+ ## License
52
+
53
+ The MIT License (MIT)
54
+
55
+ Copyright (c) 2014 Georg Großberger
56
+
57
+ Permission is hereby granted, free of charge, to any person obtaining a copy
58
+ of this software and associated documentation files (the "Software"), to deal
59
+ in the Software without restriction, including without limitation the rights
60
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
61
+ copies of the Software, and to permit persons to whom the Software is
62
+ furnished to do so, subject to the following conditions:
63
+
64
+ The above copyright notice and this permission notice shall be included in
65
+ all copies or substantial portions of the Software.
66
+
67
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
68
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
69
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
70
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
71
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
72
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
73
+ THE SOFTWARE.
@@ -66,10 +66,12 @@ module VagrantPlugins
66
66
  end
67
67
  end
68
68
 
69
- ex = VagrantPlugins::Export::Exporter.new(machine, @env, @logger)
70
- file = ex.target_file
69
+ ex = VagrantPlugins::Export::Exporter.new(@env, @logger, machine)
70
+ file = ex.target_box
71
+ box_created = false
71
72
 
72
73
  unless File.file?(file)
74
+ box_created = true
73
75
  ex.handle(false, false)
74
76
  end
75
77
 
@@ -88,7 +90,7 @@ module VagrantPlugins
88
90
  providers: provider_name
89
91
  )
90
92
 
91
- FileUtils.remove(file)
93
+ FileUtils.remove(file) if box_created
92
94
 
93
95
  if options[:keep] && options[:keep] > 1
94
96
  up.clean(machine, options[:keep])
@@ -57,14 +57,14 @@ module VagrantPlugins
57
57
  while true
58
58
  break if connection.finished?
59
59
 
60
- @env.ui.info('.', new_line: false)
61
- i++
62
-
63
60
  if i > 40
64
61
  @env.ui.clear_line
65
62
  i = 0
66
63
  end
67
64
 
65
+ @env.ui.info('.', new_line: false)
66
+ i += 1
67
+
68
68
  sleep 1
69
69
  end
70
70
 
@@ -5,6 +5,6 @@
5
5
 
6
6
  module VagrantPlugins
7
7
  module Save
8
- VERSION = '0.2.7'
8
+ VERSION = '0.2.8'
9
9
  end
10
10
  end
data/vagrant-save.gemspec CHANGED
@@ -46,5 +46,5 @@ Gem::Specification.new do |g|
46
46
 
47
47
  g.files = unignored_files
48
48
  g.require_path = 'lib'
49
- g.add_dependency 'vagrant-export', '>= 0.2.3'
49
+ g.add_dependency 'vagrant-export', '>= 0.3.4'
50
50
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vagrant-save
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.7
4
+ version: 0.2.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Georg Grossberger
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-06-13 00:00:00.000000000 Z
11
+ date: 2015-06-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: vagrant-export
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: 0.2.3
19
+ version: 0.3.4
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - ">="
25
25
  - !ruby/object:Gem::Version
26
- version: 0.2.3
26
+ version: 0.3.4
27
27
  description: Export boxes to a boxserver on a remote machine using HTTP/PUT
28
28
  email: contact@grossberger-ge.org
29
29
  executables: []
@@ -60,7 +60,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
60
60
  version: '0'
61
61
  requirements: []
62
62
  rubyforge_project:
63
- rubygems_version: 2.2.2
63
+ rubygems_version: 2.4.6
64
64
  signing_key:
65
65
  specification_version: 4
66
66
  summary: Export boxes to a boxserver