capistrano-six_pm 0.1.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.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 101b474171a68de1717587342b12b75f55b913eb
4
+ data.tar.gz: d0141f87307f3d02efe09d78223a7f859ff9d5d3
5
+ SHA512:
6
+ metadata.gz: 01e7f741739dda0843ffa5476929a961770a859f60e1123983c5972ced43479132f7caaf36258949f44368a88818179e8137763c0f008a8c689fc58cc53d6e82
7
+ data.tar.gz: 0b5db3cb941ee6683a3543efb2ab09ac0dc5f11f9894c78e52cb8e14a1a02e2d93e2ebce8c4e9e2d56cb9dfe7824ada8eb39bcc27fbaba969f4c37424039df18
data/.gitignore ADDED
@@ -0,0 +1,10 @@
1
+ /bin/
2
+ /.bundle/
3
+ /.yardoc
4
+ /Gemfile.lock
5
+ /_yardoc/
6
+ /coverage/
7
+ /doc/
8
+ /pkg/
9
+ /spec/reports/
10
+ /tmp/
data/.travis.yml ADDED
@@ -0,0 +1,3 @@
1
+ language: ruby
2
+ rvm:
3
+ - 2.1.2
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in capistrano-six_pm.gemspec
4
+ gemspec
data/LICENSE.txt ADDED
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2015 Flavien Raynaud
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,41 @@
1
+ # Capistrano::SixPm
2
+
3
+ Do you really want to deploy after six? Don't you have any kind of life after work?
4
+
5
+ Tested with [capistrano 3.4.0](https://github.com/capistrano/capistrano).
6
+
7
+ Strongly inspired by [capistrano-friday](https://github.com/marshall-lee/capistrano-friday).
8
+
9
+ ## Installation
10
+
11
+ Add this line to your application's Gemfile:
12
+
13
+ ```ruby
14
+ gem 'capistrano-six_pm'
15
+ ```
16
+
17
+ And then execute:
18
+
19
+ $ bundle
20
+
21
+ Or install it yourself as:
22
+
23
+ $ gem install capistrano-six_pm
24
+
25
+ ## Usage
26
+
27
+ Add to your `config/deploy.rb`
28
+
29
+ ```ruby
30
+ require 'capistrano/six_pm'
31
+
32
+ before 'deploy:starting', 'six_pm:check'
33
+ ```
34
+
35
+ ## Contributing
36
+
37
+ 1. Fork it ( https://github.com/flavray/capistrano-six_pm/fork )
38
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
39
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
40
+ 4. Push to the branch (`git push origin my-new-feature`)
41
+ 5. Create a new Pull Request
data/Rakefile ADDED
@@ -0,0 +1 @@
1
+ require "bundler/gem_tasks"
@@ -0,0 +1,26 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'capistrano/six_pm/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "capistrano-six_pm"
8
+ spec.version = Capistrano::SixPm::VERSION
9
+ spec.authors = ["Flavien Raynaud"]
10
+ spec.email = ["flavien.raynaud@gmail.com"]
11
+
12
+ spec.summary = %q{Do you really want to deploy after six?}
13
+ spec.description = %q{Do you really want to deploy after six? Don't you have any kind of life after work?}
14
+ spec.homepage = "https://github.com/flavray/capistrano-six_pm"
15
+ spec.licenses = ["MIT"]
16
+
17
+ spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
18
+ spec.bindir = "exe"
19
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
20
+ spec.require_paths = ["lib"]
21
+
22
+ spec.add_development_dependency "bundler", "~> 1.9"
23
+ spec.add_development_dependency "rake", "~> 10.0"
24
+
25
+ spec.add_dependency "capistrano", "~> 3.0"
26
+ end
@@ -0,0 +1 @@
1
+ load File.expand_path("../tasks/six_pm.rake", __FILE__)
@@ -0,0 +1,5 @@
1
+ module Capistrano
2
+ module SixPm
3
+ VERSION = "0.1.0"
4
+ end
5
+ end
@@ -0,0 +1,18 @@
1
+ namespace :six_pm do
2
+ def prompt
3
+ loop do
4
+ puts "It is later than 6p.m. Do you really want to deploy? [y/N]"
5
+ input = $stdin.gets.chomp.downcase
6
+ next unless ["", "y", "n"].include?(input)
7
+ return input == "y"
8
+ end
9
+ end
10
+
11
+ task :check do
12
+ if Time.now.hour >= 18
13
+ abort("wise choice. here you go: http://media.giphy.com/media/iyyJLZYjST3So/giphy.gif") unless prompt
14
+
15
+ puts "__ ______ _ ____ \n\\ \\ / / __ \\| | / __ \\ \n \\ \\_/ / | | | | | | | | \n \\ /| | | | | | | | | \n | | | |__| | |___| |__| | \n |_| \\____/|______\\____/"
16
+ end
17
+ end
18
+ end
metadata ADDED
@@ -0,0 +1,97 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: capistrano-six_pm
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Flavien Raynaud
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2015-06-09 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.9'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.9'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '10.0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '10.0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: capistrano
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '3.0'
48
+ type: :runtime
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '3.0'
55
+ description: Do you really want to deploy after six? Don't you have any kind of life
56
+ after work?
57
+ email:
58
+ - flavien.raynaud@gmail.com
59
+ executables: []
60
+ extensions: []
61
+ extra_rdoc_files: []
62
+ files:
63
+ - ".gitignore"
64
+ - ".travis.yml"
65
+ - Gemfile
66
+ - LICENSE.txt
67
+ - README.md
68
+ - Rakefile
69
+ - capistrano-six_pm.gemspec
70
+ - lib/capistrano/six_pm.rb
71
+ - lib/capistrano/six_pm/version.rb
72
+ - lib/capistrano/tasks/six_pm.rake
73
+ homepage: https://github.com/flavray/capistrano-six_pm
74
+ licenses:
75
+ - MIT
76
+ metadata: {}
77
+ post_install_message:
78
+ rdoc_options: []
79
+ require_paths:
80
+ - lib
81
+ required_ruby_version: !ruby/object:Gem::Requirement
82
+ requirements:
83
+ - - ">="
84
+ - !ruby/object:Gem::Version
85
+ version: '0'
86
+ required_rubygems_version: !ruby/object:Gem::Requirement
87
+ requirements:
88
+ - - ">="
89
+ - !ruby/object:Gem::Version
90
+ version: '0'
91
+ requirements: []
92
+ rubyforge_project:
93
+ rubygems_version: 2.2.2
94
+ signing_key:
95
+ specification_version: 4
96
+ summary: Do you really want to deploy after six?
97
+ test_files: []