versi 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: e9cbec2ba506cbb32289dbe6b4300f8d7defbc5c
4
+ data.tar.gz: e7d9ce4ca99cd20374d3a09d0e5ff2e5a52082cb
5
+ SHA512:
6
+ metadata.gz: 037477f330f48ec777a4e2e7da7553a70e1f6a0bd239d7aa23c67dd1c89fe1812f3ba986098db6dc46abec3a42d24bad631f374423fdc3ca80d764e344b995be
7
+ data.tar.gz: a8309272311540182803cb23099bdb5f3d9233dda7def12c163a9a96cf0ee7dc8bd74384375cf299e34b3a7038a9e4094e4533c39b1e5ab946a807cd4de218c7
data/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2016-2017 Airton Sampaio de Sobral
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
data/README.md ADDED
File without changes
data/bin/versi ADDED
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env ruby
2
+ require "versi"
3
+
4
+ Versi.run
@@ -0,0 +1,24 @@
1
+ require "clamp"
2
+ require "versi/semantic_release_types"
3
+
4
+ class Versi < Clamp::Command
5
+ class GenerateCommand < Clamp::Command
6
+ option ["-t", "--type"], "TYPE", "The release type #{SemanticReleaseTypes::ALL.to_a.to_s}"
7
+ option ["-n", "--name"], "NAME", "The release tag name"
8
+ option ["-p", "--prefix"], "PREFIX", "The release tag prefix"
9
+ option ["-m", "--message"], "MESSAGE", "The release tag annotation message"
10
+ option ["-d", "--debug"], :flag, "This flag will prevent the command from persisting the release tag"
11
+
12
+ def execute
13
+ validate
14
+ end
15
+
16
+ private
17
+
18
+ def validate
19
+ if type != nil && !SemanticReleaseTypes::ALL.include?(type)
20
+ raise "Invalid release type: \"#{type}\". The valid ones are: #{SemanticReleaseTypes::ALL.to_a.to_s}"
21
+ end
22
+ end
23
+ end
24
+ end
@@ -0,0 +1,11 @@
1
+ require "clamp"
2
+ require "set"
3
+
4
+ class Versi < Clamp::Command
5
+ class SemanticReleaseTypes
6
+ PATCH = "patch".freeze
7
+ MINOR = "minor".freeze
8
+ MAJOR = "major".freeze
9
+ ALL = Set.new([PATCH, MINOR, MAJOR])
10
+ end
11
+ end
data/lib/versi.rb ADDED
@@ -0,0 +1,6 @@
1
+ require "clamp"
2
+ require "versi/generate_command"
3
+
4
+ class Versi < Clamp::Command
5
+ subcommand "generate", "Generate Release Version", Versi::GenerateCommand
6
+ end
metadata ADDED
@@ -0,0 +1,82 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: versi
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Airton Sobral
8
+ - Guilherme Cavalcanti
9
+ autorequire:
10
+ bindir: bin
11
+ cert_chain: []
12
+ date: 2016-12-18 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: clamp
16
+ requirement: !ruby/object:Gem::Requirement
17
+ requirements:
18
+ - - '='
19
+ - !ruby/object:Gem::Version
20
+ version: 1.1.1
21
+ type: :runtime
22
+ prerelease: false
23
+ version_requirements: !ruby/object:Gem::Requirement
24
+ requirements:
25
+ - - '='
26
+ - !ruby/object:Gem::Version
27
+ version: 1.1.1
28
+ - !ruby/object:Gem::Dependency
29
+ name: interactor
30
+ requirement: !ruby/object:Gem::Requirement
31
+ requirements:
32
+ - - '='
33
+ - !ruby/object:Gem::Version
34
+ version: 3.1.0
35
+ type: :runtime
36
+ prerelease: false
37
+ version_requirements: !ruby/object:Gem::Requirement
38
+ requirements:
39
+ - - '='
40
+ - !ruby/object:Gem::Version
41
+ version: 3.1.0
42
+ description: Release Version Automation for GIT
43
+ email:
44
+ - airtonsobral@gmail.com
45
+ - guiocavalcanti@gmail.com
46
+ executables:
47
+ - versi
48
+ extensions: []
49
+ extra_rdoc_files:
50
+ - README.md
51
+ files:
52
+ - LICENSE
53
+ - README.md
54
+ - bin/versi
55
+ - lib/versi.rb
56
+ - lib/versi/generate_command.rb
57
+ - lib/versi/semantic_release_types.rb
58
+ homepage: http://rubygemgem.org/gems/versi
59
+ licenses:
60
+ - MIT
61
+ metadata: {}
62
+ post_install_message:
63
+ rdoc_options: []
64
+ require_paths:
65
+ - lib
66
+ required_ruby_version: !ruby/object:Gem::Requirement
67
+ requirements:
68
+ - - ">="
69
+ - !ruby/object:Gem::Version
70
+ version: '2.2'
71
+ required_rubygems_version: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - ">="
74
+ - !ruby/object:Gem::Version
75
+ version: '0'
76
+ requirements: []
77
+ rubyforge_project:
78
+ rubygems_version: 2.4.8
79
+ signing_key:
80
+ specification_version: 4
81
+ summary: Git Version Automation
82
+ test_files: []