workflow-cli 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/License +20 -0
- data/README.md +27 -0
- data/Rakefile +37 -0
- data/lib/workflow.rb +4 -0
- data/lib/workflow/version.rb +42 -0
- data/spec/workflow_spec.rb +5 -0
- data/workflow.gemspec +33 -0
- metadata +64 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 35b18ee2e99cd94b759f897b11af767f869b7393
|
4
|
+
data.tar.gz: c9e4509864c9253967551e001ccbc005f3a6e4d2
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: e9af8730ec6ccf6038e1a0ab1191819c27cbed9a2981897be962f90af42a5c67663c06a904569837436d01fcfe09e5af0d3d87640ba7e67cc83a8d05ba0b0e6a
|
7
|
+
data.tar.gz: a5d573a69b037a6e53c2ffb144c594d1c38bad5f3ca8ddbb385eec7b950ec5836a5b6d02faf1b0cf3d2bff7198a31641a867c860ceed428eb4ae698cb81d7906
|
data/License
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
Copyright (c) 2014 Aiden Nichols
|
2
|
+
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
+
a copy of this software and associated documentation files (the
|
5
|
+
'Software'), to deal in the Software without restriction, including
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
9
|
+
the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be
|
12
|
+
included in all copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
17
|
+
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
18
|
+
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
19
|
+
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
20
|
+
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,27 @@
|
|
1
|
+
I have no clue what this library does.
|
2
|
+
|
3
|
+
# Pro Tip
|
4
|
+
|
5
|
+
To not have too many boilerplate commits (so you avoid ppl from thinking "WTF?
|
6
|
+
Why did he/she start with rspec but instantly switched to minitest, and what's
|
7
|
+
all that nonsense in the readme?") use `git commit --amend` to make changes in
|
8
|
+
the initial commit rather than creating new commits. Just saying.
|
9
|
+
|
10
|
+
# Usage
|
11
|
+
|
12
|
+
``` ruby
|
13
|
+
require 'workflow'
|
14
|
+
fail("Dunno how to use %p" % Workflow)
|
15
|
+
```
|
16
|
+
|
17
|
+
# Installation
|
18
|
+
|
19
|
+
gem install workflow
|
20
|
+
|
21
|
+
# TODO
|
22
|
+
|
23
|
+
* Write code and documentation
|
24
|
+
* Fix project description in gemspec
|
25
|
+
* Change testing framework if necessary (see Rakefile, currently RSpec)
|
26
|
+
* Adjust workflow.gemspec if your github name is not GITHUB_USER
|
27
|
+
* Adjust License if your real name is not Aiden Nichols
|
data/Rakefile
ADDED
@@ -0,0 +1,37 @@
|
|
1
|
+
$LOAD_PATH.unshift File.expand_path('../lib', __FILE__)
|
2
|
+
|
3
|
+
begin
|
4
|
+
require 'bundler'
|
5
|
+
Bundler::GemHelper.install_tasks
|
6
|
+
rescue LoadError => e
|
7
|
+
$stderr.puts e
|
8
|
+
end
|
9
|
+
|
10
|
+
desc "run specs"
|
11
|
+
task(:spec) { ruby '-S rspec spec' }
|
12
|
+
|
13
|
+
desc "generate gemspec"
|
14
|
+
task 'workflow.gemspec' do
|
15
|
+
require 'workflow/version'
|
16
|
+
content = File.read 'workflow.gemspec'
|
17
|
+
|
18
|
+
fields = {
|
19
|
+
:authors => `git shortlog -sn`.scan(/[^\d\s].*/),
|
20
|
+
:email => `git shortlog -sne`.scan(/[^<]+@[^>]+/),
|
21
|
+
:files => `git ls-files`.split("\n").reject { |f| f =~ /^(\.|Gemfile)/ }
|
22
|
+
}
|
23
|
+
|
24
|
+
fields.each do |field, values|
|
25
|
+
updated = " s.#{field} = ["
|
26
|
+
updated << values.map { |v| "\n %p" % v }.join(',')
|
27
|
+
updated << "\n ]"
|
28
|
+
content.sub!(/ s\.#{field} = \[\n( .*\n)* \]/, updated)
|
29
|
+
end
|
30
|
+
|
31
|
+
content.sub! /(s\.version.*=\s+).*/, "\\1\"#{Workflow::VERSION}\""
|
32
|
+
File.open('workflow.gemspec', 'w') { |f| f << content }
|
33
|
+
end
|
34
|
+
|
35
|
+
task :gemspec => 'workflow.gemspec'
|
36
|
+
task :default => :spec
|
37
|
+
task :test => :spec
|
data/lib/workflow.rb
ADDED
@@ -0,0 +1,42 @@
|
|
1
|
+
module Workflow
|
2
|
+
def self.version
|
3
|
+
VERSION
|
4
|
+
end
|
5
|
+
|
6
|
+
module VERSION
|
7
|
+
extend Comparable
|
8
|
+
|
9
|
+
MAJOR = 0
|
10
|
+
MINOR = 0
|
11
|
+
TINY = 1
|
12
|
+
SIGNATURE = [MAJOR, MINOR, TINY]
|
13
|
+
STRING = SIGNATURE.join '.'
|
14
|
+
|
15
|
+
def self.major; MAJOR end
|
16
|
+
def self.minor; MINOR end
|
17
|
+
def self.tiny; TINY end
|
18
|
+
def self.to_s; STRING end
|
19
|
+
|
20
|
+
def self.hash
|
21
|
+
STRING.hash
|
22
|
+
end
|
23
|
+
|
24
|
+
def self.<=>(other)
|
25
|
+
other = other.split('.').map { |i| i.to_i } if other.respond_to? :split
|
26
|
+
SIGNATURE <=> Array(other)
|
27
|
+
end
|
28
|
+
|
29
|
+
def self.inspect
|
30
|
+
STRING.inspect
|
31
|
+
end
|
32
|
+
|
33
|
+
def self.respond_to?(meth, *)
|
34
|
+
meth.to_s !~ /^__|^to_str$/ and STRING.respond_to? meth unless super
|
35
|
+
end
|
36
|
+
|
37
|
+
def self.method_missing(meth, *args, &block)
|
38
|
+
return super unless STRING.respond_to?(meth)
|
39
|
+
STRING.send(meth, *args, &block)
|
40
|
+
end
|
41
|
+
end
|
42
|
+
end
|
data/workflow.gemspec
ADDED
@@ -0,0 +1,33 @@
|
|
1
|
+
# Run `rake workflow.gemspec` to update the gemspec.
|
2
|
+
Gem::Specification.new do |s|
|
3
|
+
# general infos
|
4
|
+
s.name = "workflow-cli"
|
5
|
+
s.version = "0.0.1"
|
6
|
+
s.description = "No Description Yet"
|
7
|
+
s.homepage = "http://github.com/GITHUB_USER/workflow"
|
8
|
+
s.summary = s.description
|
9
|
+
|
10
|
+
# generated from git shortlog -sn
|
11
|
+
s.authors = [
|
12
|
+
"Aiden Nichols"
|
13
|
+
]
|
14
|
+
|
15
|
+
# generated from git shortlog -sne
|
16
|
+
s.email = [
|
17
|
+
"aiden@a1digital.co"
|
18
|
+
]
|
19
|
+
|
20
|
+
# generated from git ls-files
|
21
|
+
s.files = [
|
22
|
+
"License",
|
23
|
+
"README.md",
|
24
|
+
"Rakefile",
|
25
|
+
"lib/workflow.rb",
|
26
|
+
"lib/workflow/version.rb",
|
27
|
+
"spec/workflow_spec.rb",
|
28
|
+
"workflow.gemspec"
|
29
|
+
]
|
30
|
+
|
31
|
+
# dependencies
|
32
|
+
s.add_development_dependency "rspec", "~> 2.0"
|
33
|
+
end
|
metadata
ADDED
@@ -0,0 +1,64 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: workflow-cli
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.1
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Aiden Nichols
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2014-12-22 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: rspec
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '2.0'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '2.0'
|
27
|
+
description: No Description Yet
|
28
|
+
email:
|
29
|
+
- aiden@a1digital.co
|
30
|
+
executables: []
|
31
|
+
extensions: []
|
32
|
+
extra_rdoc_files: []
|
33
|
+
files:
|
34
|
+
- License
|
35
|
+
- README.md
|
36
|
+
- Rakefile
|
37
|
+
- lib/workflow.rb
|
38
|
+
- lib/workflow/version.rb
|
39
|
+
- spec/workflow_spec.rb
|
40
|
+
- workflow.gemspec
|
41
|
+
homepage: http://github.com/GITHUB_USER/workflow
|
42
|
+
licenses: []
|
43
|
+
metadata: {}
|
44
|
+
post_install_message:
|
45
|
+
rdoc_options: []
|
46
|
+
require_paths:
|
47
|
+
- lib
|
48
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
49
|
+
requirements:
|
50
|
+
- - ">="
|
51
|
+
- !ruby/object:Gem::Version
|
52
|
+
version: '0'
|
53
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
54
|
+
requirements:
|
55
|
+
- - ">="
|
56
|
+
- !ruby/object:Gem::Version
|
57
|
+
version: '0'
|
58
|
+
requirements: []
|
59
|
+
rubyforge_project:
|
60
|
+
rubygems_version: 2.2.2
|
61
|
+
signing_key:
|
62
|
+
specification_version: 4
|
63
|
+
summary: No Description Yet
|
64
|
+
test_files: []
|