confirm_deploy 0.0.1 → 1.0.0

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.
@@ -0,0 +1,12 @@
1
+ Release 1.0.0
2
+ -------------
3
+
4
+ * Added change log.
5
+ * Readded version file and methods.
6
+ * Added dependency for Capistrano 2.3.0 or higher.
7
+
8
+
9
+ Release 0.0.1
10
+ -------------
11
+
12
+ * Proof of concept.
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # ConfirmDeploy
2
2
 
3
- TODO: Write a gem description
3
+ Simple capistrano recipe to get user(s) to confirm before deploying an app.
4
4
 
5
5
  ## Installation
6
6
 
@@ -18,7 +18,37 @@ Or install it yourself as:
18
18
 
19
19
  ## Usage
20
20
 
21
- TODO: Write usage instructions here
21
+ Add to your capistrano deploy.rb
22
+
23
+ require 'confirm_deploy'
24
+
25
+ ## Examples
26
+
27
+ Confirmed deploy:
28
+
29
+ $ cap deploy
30
+ * 2012-12-15 14:52:11 executing `deploy'
31
+ * 2012-12-15 14:52:11 executing `deploy:update'
32
+ ** transaction: start
33
+ * 2012-12-15 14:52:11 executing `deploy:update_code'
34
+ triggering before callbacks for `deploy:update_code'
35
+ * 2012-12-15 14:52:11 executing `deploy:confirm'
36
+ ** Deploying...
37
+ Are you sure you want to deploy? (yes): yes
38
+ ...
39
+
40
+ Unconfirmed deploy:
41
+
42
+ $ cap deploy
43
+ * 2012-12-15 14:52:11 executing `deploy'
44
+ * 2012-12-15 14:52:11 executing `deploy:update'
45
+ ** transaction: start
46
+ * 2012-12-15 14:52:11 executing `deploy:update_code'
47
+ triggering before callbacks for `deploy:update_code'
48
+ * 2012-12-15 14:52:11 executing `deploy:confirm'
49
+ ** Deploying...
50
+ Are you sure you want to deploy? (yes): no
51
+ *** Deploy cancelled!
22
52
 
23
53
  ## Contributing
24
54
 
@@ -1,10 +1,11 @@
1
1
  # -*- encoding: utf-8 -*-
2
2
  lib = File.expand_path('../lib', __FILE__)
3
3
  $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'confirm_deploy/version'
4
5
 
5
6
  Gem::Specification.new do |gem|
6
7
  gem.name = "confirm_deploy"
7
- gem.version = "0.0.1"
8
+ gem.version = ConfirmDeploy::VERSION
8
9
  gem.authors = ["Daniel Thor"]
9
10
  gem.email = ["daniel.thor@gmail.com"]
10
11
  gem.description = %q{Confirm before deploy in Capistrano}
@@ -15,4 +16,6 @@ Gem::Specification.new do |gem|
15
16
  gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
16
17
  gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
17
18
  gem.require_paths = ["lib"]
19
+
20
+ gem.add_dependency "capistrano", "~> 2.13"
18
21
  end
@@ -1,3 +1,4 @@
1
+ require "confirm_deploy/version"
1
2
  require 'capistrano/configuration'
2
3
 
3
4
  Capistrano::Configuration.instance(:must_exist).load do
@@ -6,9 +7,9 @@ Capistrano::Configuration.instance(:must_exist).load do
6
7
  task :confirm do
7
8
  unless Capistrano::CLI.ui.ask(" Are you sure you want to deploy? (yes): ") == 'yes'
8
9
  logger.important "Deploy cancelled!"
9
- exit
10
+ abort
10
11
  end
11
12
  end
12
13
  before "deploy:update_code", "deploy:confirm"
13
14
  end
14
- end
15
+ end
@@ -0,0 +1,3 @@
1
+ module ConfirmDeploy
2
+ VERSION = "1.0.0"
3
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: confirm_deploy
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 1.0.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,8 +9,24 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-12-13 00:00:00.000000000 Z
13
- dependencies: []
12
+ date: 2012-12-15 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: capistrano
16
+ requirement: !ruby/object:Gem::Requirement
17
+ none: false
18
+ requirements:
19
+ - - ~>
20
+ - !ruby/object:Gem::Version
21
+ version: '2.13'
22
+ type: :runtime
23
+ prerelease: false
24
+ version_requirements: !ruby/object:Gem::Requirement
25
+ none: false
26
+ requirements:
27
+ - - ~>
28
+ - !ruby/object:Gem::Version
29
+ version: '2.13'
14
30
  description: Confirm before deploy in Capistrano
15
31
  email:
16
32
  - daniel.thor@gmail.com
@@ -19,12 +35,14 @@ extensions: []
19
35
  extra_rdoc_files: []
20
36
  files:
21
37
  - .gitignore
38
+ - CHANGELOG
22
39
  - Gemfile
23
40
  - LICENSE.txt
24
41
  - README.md
25
42
  - Rakefile
26
43
  - confirm_deploy.gemspec
27
44
  - lib/confirm_deploy.rb
45
+ - lib/confirm_deploy/version.rb
28
46
  homepage: https://github.com/danielthor/confirm_deploy
29
47
  licenses: []
30
48
  post_install_message: