schubert-minglr 1.0.6 → 1.1.0

Sign up to get free protection for your applications and to get access to all the features.
data/.document ADDED
@@ -0,0 +1,5 @@
1
+ README.rdoc
2
+ lib/**/*.rb
3
+ bin/*
4
+ features/**/*.feature
5
+ LICENSE
data/.gitignore ADDED
@@ -0,0 +1 @@
1
+ pkg/*
data/LICENSE ADDED
@@ -0,0 +1,20 @@
1
+ Copyright (c) 2009 Michael Schubert
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
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/PostInstall.txt CHANGED
@@ -1,12 +1 @@
1
-
2
- For more information:
3
- on minglr, see http://github.com/schubert/minglr/tree/master
4
- on Mingle, see http://mingle.thoughtworks.com/mingle-agile-project-management
5
- on the authors (Stephen Chu), see http://www.stephenchu.com
6
- (Michael Schubert), see http://schubert.cx/
7
-
8
- ======================================================================================================
9
- = Don't not forget to enable your Mingle API authentication by configuring the auth_config.yml file! =
10
- ======================================================================================================
11
-
12
- Happy Coding.
1
+ = Don't not forget to enable your Mingle API authentication by configuring the auth_config.yml file! =
data/README.rdoc CHANGED
@@ -71,33 +71,17 @@ Minglr can be used regardless your application is a Ruby on Rails web applicatio
71
71
 
72
72
  == INSTALL:
73
73
 
74
- * sudo gem install schubert-minglr
75
- * Preferably install rb-password (http://www.caliban.org/ruby/ruby-password.shtml), through Macports (sudo port install rb-password)
76
- * Enable Mingle API basic authentication in auth_config.yml, then restart it.
77
- * Copy over the "path-to-minglr/tasks/*.sample.rake" files and start customizing for your check-in needs.
74
+ * sudo gem install schubert-minglr -s http://gems.github.com
78
75
 
79
- == LICENSE:
76
+ * Enable Mingle API basic authentication in auth_config.yml, then restart it.
80
77
 
81
- (The MIT License)
78
+ * Preferably install rb-password (http://www.caliban.org/ruby/ruby-password.shtml), through Macports (sudo port install rb-password)
79
+ * Copy over the "path-to-minglr/tasks/*.sample.rake" files and start customizing for your check-in needs.
82
80
 
83
- Copyright (c) 2009 Michael Schubert
84
- Copyright (c) 2009 Stephen Chu
81
+ == CREDITS:
85
82
 
86
- Permission is hereby granted, free of charge, to any person obtaining
87
- a copy of this software and associated documentation files (the
88
- 'Software'), to deal in the Software without restriction, including
89
- without limitation the rights to use, copy, modify, merge, publish,
90
- distribute, sublicense, and/or sell copies of the Software, and to
91
- permit persons to whom the Software is furnished to do so, subject to
92
- the following conditions:
83
+ Thank you to Stephen Chu and Chris O'Meara for their original work.
93
84
 
94
- The above copyright notice and this permission notice shall be
95
- included in all copies or substantial portions of the Software.
85
+ == Copyright
96
86
 
97
- THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
98
- EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
99
- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
100
- IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
101
- CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
102
- TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
103
- SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
87
+ Copyright (c) 2009 Michael Schubert. See LICENSE for details.
data/Rakefile CHANGED
@@ -1,29 +1,65 @@
1
- %w[rubygems rake rake/clean fileutils newgem rubigen].each { |f| require f }
2
- require File.dirname(__FILE__) + '/lib/minglr'
3
-
4
- # Generate all the Rake tasks
5
- # Run 'rake -T' to see list of generated tasks (from gem root directory)
6
- $hoe = Hoe.new('minglr', Minglr::VERSION) do |p|
7
- p.developer('Michael Schubert', 'michael@schubert.cx')
8
- p.changes = p.paragraphs_of("History.txt", 0..1).join("\n\n")
9
- p.post_install_message = 'PostInstall.txt' # TODO remove if post-install message not required
10
- p.rubyforge_name = p.name # TODO this is default value
11
- p.extra_deps = [
12
- ['activesupport','>= 2.1.0'],
13
- ['activeresource', '>= 2.1.0']
14
- ]
15
- p.extra_dev_deps = [
16
- ['newgem', ">= #{::Newgem::VERSION}"]
17
- ]
18
-
19
- p.clean_globs |= %w[**/.DS_Store tmp *.log]
20
- path = (p.rubyforge_name == p.name) ? p.rubyforge_name : "\#{p.rubyforge_name}/\#{p.name}"
21
- p.remote_rdoc_dir = File.join(path.gsub(/^#{p.rubyforge_name}\/?/,''), 'rdoc')
22
- p.rsync_args = '-av --delete --ignore-errors'
1
+ require 'rubygems'
2
+ require 'rake'
3
+
4
+ begin
5
+ require 'jeweler'
6
+ Jeweler::Tasks.new do |gem|
7
+ if File.exist?('VERSION.yml')
8
+ config = YAML.load(File.read('VERSION.yml'))
9
+ gem.version = "#{config[:major]}.#{config[:minor]}.#{config[:patch]}"
10
+ else
11
+ gem.version = ""
12
+ end
13
+ gem.post_install_message = %q{PostInstall.txt}
14
+
15
+ gem.name = "minglr"
16
+ gem.summary = %q{command line user tool for Mingle (http://mingle.thoughtworks.com/mingle-agile-project-management)}
17
+ gem.description = %q{* This gem provides two executable binaries to interact with Mingle (http://mingle.thoughtworks.com/mingle-agile-project-management) through its API. It also has sample interactive Rake task on how to facilitate easy card movements when a card enters/exits the development queue. * mtx is a binary that facilities transition changes for use on rake tasks * minglr is a more interactive tool that provides a quick interface for many common uses}
18
+ gem.email = "michael@schubert.cx"
19
+ gem.homepage = "http://github.com/schubert/minglr"
20
+ gem.authors = ["Michael Schubert", "Stephen Chu", "Chris O'Meara"]
21
+ gem.executables = ["mtx", "minglr"]
22
+ # gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
23
+ end
24
+ rescue LoadError
25
+ puts "Jeweler (or a dependency) not available. Install it with: sudo gem install jeweler"
26
+ end
27
+
28
+ require 'rake/testtask'
29
+ Rake::TestTask.new(:test) do |test|
30
+ test.libs << 'lib' << 'test'
31
+ test.pattern = 'test/**/*_test.rb'
32
+ test.verbose = true
33
+ end
34
+
35
+ begin
36
+ require 'rcov/rcovtask'
37
+ Rcov::RcovTask.new do |test|
38
+ test.libs << 'test'
39
+ test.pattern = 'test/**/*_test.rb'
40
+ test.verbose = true
41
+ end
42
+ rescue LoadError
43
+ task :rcov do
44
+ abort "RCov is not available. In order to run rcov, you must: sudo gem install spicycode-rcov"
45
+ end
23
46
  end
24
47
 
25
- require 'newgem/tasks' # load /tasks/*.rake
26
- Dir['tasks/**/*.rake'].each { |t| load t }
27
48
 
28
- # TODO - want other tests/tasks run by default? Add them to the list
29
- # task :default => [:spec, :features]
49
+ task :default => :test
50
+
51
+ require 'rake/rdoctask'
52
+ Rake::RDocTask.new do |rdoc|
53
+ if File.exist?('VERSION.yml')
54
+ config = YAML.load(File.read('VERSION.yml'))
55
+ version = "#{config[:major]}.#{config[:minor]}.#{config[:patch]}"
56
+ else
57
+ version = ""
58
+ end
59
+
60
+ rdoc.rdoc_dir = 'rdoc'
61
+ rdoc.title = "minglr #{version}"
62
+ rdoc.rdoc_files.include('README*')
63
+ rdoc.rdoc_files.include('lib/**/*.rb')
64
+ end
65
+
data/VERSION.yml ADDED
@@ -0,0 +1,4 @@
1
+ ---
2
+ :major: 1
3
+ :minor: 1
4
+ :patch: 0
data/bin/minglr CHANGED
@@ -19,7 +19,8 @@ end
19
19
 
20
20
  if project
21
21
  uri_options.merge! rc_config[project]
22
- uri_options[:url].gsub!(/^http\:\/\//, "")
22
+ uri_options[:protocol] = uri_options[:url].slice(/^.*\:/).chop
23
+ uri_options[:url].gsub!(/^(http|https)\:\/\//, "")
23
24
  uri_options[:host_and_port], uri_options[:project] = uri_options[:url].split("/projects/")
24
25
  MingleResource.configure uri_options
25
26
  Attachment.configure
data/lib/minglr.rb CHANGED
@@ -13,12 +13,10 @@ require File.dirname(__FILE__) + '/minglr/property_definition'
13
13
  require File.dirname(__FILE__) + '/minglr/attachment'
14
14
  require File.dirname(__FILE__) + '/minglr/transition_execution'
15
15
  require File.dirname(__FILE__) + '/minglr/input_cache'
16
- require File.dirname(__FILE__) + "/version"
17
16
 
18
17
  $:.unshift(File.dirname(__FILE__)) unless
19
18
  $:.include?(File.dirname(__FILE__)) || $:.include?(File.expand_path(File.dirname(__FILE__)))
20
19
 
21
20
  module Minglr
22
- VERSION = MINGLR_VERSION
23
21
  ROOT = File.expand_path File.join(File.dirname(__FILE__), '..')
24
22
  end
@@ -1,5 +1,5 @@
1
1
  class MingleResource < ActiveResource::Base
2
2
  def self.configure(uri_options)
3
- self.site = "http://#{uri_options[:username]}:#{uri_options[:password]}@#{uri_options[:host_and_port]}/projects/#{uri_options[:project]}"
3
+ self.site = "#{uri_options[:protocol]}://#{uri_options[:username]}:#{uri_options[:password]}@#{uri_options[:host_and_port]}/projects/#{uri_options[:project]}"
4
4
  end
5
5
  end
data/minglr.gemspec ADDED
@@ -0,0 +1,69 @@
1
+ # -*- encoding: utf-8 -*-
2
+
3
+ Gem::Specification.new do |s|
4
+ s.name = %q{minglr}
5
+ s.version = "1.1.0"
6
+
7
+ s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
8
+ s.authors = ["Michael Schubert", "Stephen Chu", "Chris O'Meara"]
9
+ s.date = %q{2009-07-09}
10
+ s.description = %q{* This gem provides two executable binaries to interact with Mingle (http://mingle.thoughtworks.com/mingle-agile-project-management) through its API. It also has sample interactive Rake task on how to facilitate easy card movements when a card enters/exits the development queue. * mtx is a binary that facilities transition changes for use on rake tasks * minglr is a more interactive tool that provides a quick interface for many common uses}
11
+ s.email = %q{michael@schubert.cx}
12
+ s.executables = ["mtx", "minglr"]
13
+ s.extra_rdoc_files = [
14
+ "LICENSE",
15
+ "README.rdoc"
16
+ ]
17
+ s.files = [
18
+ ".document",
19
+ ".gitignore",
20
+ "LICENSE",
21
+ "PostInstall.txt",
22
+ "README.rdoc",
23
+ "Rakefile",
24
+ "VERSION.yml",
25
+ "bin/minglr",
26
+ "bin/mtx",
27
+ "lib/minglr.rb",
28
+ "lib/minglr/attachment.rb",
29
+ "lib/minglr/card.rb",
30
+ "lib/minglr/input_cache.rb",
31
+ "lib/minglr/mingle_resource.rb",
32
+ "lib/minglr/minglr_action.rb",
33
+ "lib/minglr/minglr_config_parser.rb",
34
+ "lib/minglr/minglr_options_parser.rb",
35
+ "lib/minglr/mtx_options_parser.rb",
36
+ "lib/minglr/property_definition.rb",
37
+ "lib/minglr/transition_execution.rb",
38
+ "lib/minglr/user.rb",
39
+ "minglr.gemspec",
40
+ "minglrconfig.sample",
41
+ "tasks/commit.sample.rake",
42
+ "tasks/svn.sample.rake",
43
+ "test/attachment_test.rb",
44
+ "test/minglr_resource_test.rb",
45
+ "test/test_helper.rb"
46
+ ]
47
+ s.has_rdoc = true
48
+ s.homepage = %q{http://github.com/schubert/minglr}
49
+ s.post_install_message = %q{PostInstall.txt}
50
+ s.rdoc_options = ["--charset=UTF-8"]
51
+ s.require_paths = ["lib"]
52
+ s.rubygems_version = %q{1.3.1}
53
+ s.summary = %q{command line user tool for Mingle (http://mingle.thoughtworks.com/mingle-agile-project-management)}
54
+ s.test_files = [
55
+ "test/attachment_test.rb",
56
+ "test/minglr_resource_test.rb",
57
+ "test/test_helper.rb"
58
+ ]
59
+
60
+ if s.respond_to? :specification_version then
61
+ current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
62
+ s.specification_version = 2
63
+
64
+ if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
65
+ else
66
+ end
67
+ else
68
+ end
69
+ end
@@ -0,0 +1,18 @@
1
+ [global]
2
+ default = someproject
3
+ username = yourusername
4
+
5
+ [someproject]
6
+ url = http://your.mingle.host.com/mingle/projects/someproject
7
+ username = yourusername
8
+ password = YOURMINGLEPASSWORD
9
+ delete_property = cp_story_status
10
+ delete_state = Deleted
11
+ status_property = cp_story_status
12
+ story_state_1 = Ready For Development > Sign Up for Story
13
+ story_state_2 = Dev In Progress > Dev Complete
14
+ task_state_1 = New > New to ready for Dev for Task
15
+ task_state_2 = Ready for Development > Dev in Progress
16
+ task_state_3 = Dev In Progress > Story from Dev in Progress to Dev Complete
17
+ story_checkout = story_state_1
18
+ task_checkout = story_state_2
@@ -0,0 +1,24 @@
1
+ require 'test_helper'
2
+
3
+ class AttachmentTest < Test::Unit::TestCase
4
+
5
+ context AttachmentTest do
6
+
7
+ context "configure" do
8
+
9
+ should "append to the site url" do
10
+ options = { :protocol => "proto",
11
+ :username => "user",
12
+ :password => "pass",
13
+ :host_and_port => "somehost.com:1234",
14
+ :project => "my_project"}
15
+ MingleResource.configure(options)
16
+ Attachment.configure
17
+ assert_equal "/projects/my_project/cards/1/", Attachment.prefix(:card_number => 1)
18
+ end
19
+
20
+ end
21
+
22
+ end
23
+
24
+ end
@@ -0,0 +1,24 @@
1
+ require 'test_helper'
2
+
3
+ class MinglrResourceTest < Test::Unit::TestCase
4
+
5
+ context MinglrResourceTest do
6
+
7
+ context "configure" do
8
+
9
+ should "combine options to build url" do
10
+ options = { :protocol => "proto",
11
+ :username => "user",
12
+ :password => "pass",
13
+ :host_and_port => "somehost.com:1234",
14
+ :project => "my_project"}
15
+ MingleResource.configure(options)
16
+ assert_equal "proto://user:pass@somehost.com:1234/projects/my_project",
17
+ MingleResource.site.to_s
18
+ end
19
+
20
+ end
21
+
22
+ end
23
+
24
+ end
@@ -0,0 +1,10 @@
1
+ require 'rubygems'
2
+ require 'test/unit'
3
+ require 'shoulda'
4
+
5
+ $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
6
+ $LOAD_PATH.unshift(File.dirname(__FILE__))
7
+ require 'minglr'
8
+
9
+ class Test::Unit::TestCase
10
+ end
metadata CHANGED
@@ -1,80 +1,41 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: schubert-minglr
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.6
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Schubert
8
+ - Stephen Chu
9
+ - Chris O'Meara
8
10
  autorequire:
9
11
  bindir: bin
10
12
  cert_chain: []
11
13
 
12
- date: 2009-06-02 00:00:00 -07:00
14
+ date: 2009-07-09 00:00:00 -07:00
13
15
  default_executable:
14
- dependencies:
15
- - !ruby/object:Gem::Dependency
16
- name: activesupport
17
- type: :runtime
18
- version_requirement:
19
- version_requirements: !ruby/object:Gem::Requirement
20
- requirements:
21
- - - ">="
22
- - !ruby/object:Gem::Version
23
- version: 2.1.0
24
- version:
25
- - !ruby/object:Gem::Dependency
26
- name: activeresource
27
- type: :runtime
28
- version_requirement:
29
- version_requirements: !ruby/object:Gem::Requirement
30
- requirements:
31
- - - ">="
32
- - !ruby/object:Gem::Version
33
- version: 2.1.0
34
- version:
35
- - !ruby/object:Gem::Dependency
36
- name: newgem
37
- type: :development
38
- version_requirement:
39
- version_requirements: !ruby/object:Gem::Requirement
40
- requirements:
41
- - - ">="
42
- - !ruby/object:Gem::Version
43
- version: 1.4.1
44
- version:
45
- - !ruby/object:Gem::Dependency
46
- name: hoe
47
- type: :development
48
- version_requirement:
49
- version_requirements: !ruby/object:Gem::Requirement
50
- requirements:
51
- - - ">="
52
- - !ruby/object:Gem::Version
53
- version: 1.8.0
54
- version:
16
+ dependencies: []
17
+
55
18
  description: "* This gem provides two executable binaries to interact with Mingle (http://mingle.thoughtworks.com/mingle-agile-project-management) through its API. It also has sample interactive Rake task on how to facilitate easy card movements when a card enters/exits the development queue. * mtx is a binary that facilities transition changes for use on rake tasks * minglr is a more interactive tool that provides a quick interface for many common uses"
56
- email:
57
- - michael@schubert.cx
19
+ email: michael@schubert.cx
58
20
  executables:
59
21
  - mtx
60
22
  - minglr
61
23
  extensions: []
62
24
 
63
25
  extra_rdoc_files:
64
- - History.txt
65
- - Manifest.txt
66
- - PostInstall.txt
26
+ - LICENSE
67
27
  - README.rdoc
68
28
  files:
69
- - History.txt
70
- - Manifest.txt
29
+ - .document
30
+ - .gitignore
31
+ - LICENSE
71
32
  - PostInstall.txt
72
33
  - README.rdoc
73
34
  - Rakefile
74
- - bin/mtx
35
+ - VERSION.yml
75
36
  - bin/minglr
37
+ - bin/mtx
76
38
  - lib/minglr.rb
77
- - lib/version.rb
78
39
  - lib/minglr/attachment.rb
79
40
  - lib/minglr/card.rb
80
41
  - lib/minglr/input_cache.rb
@@ -86,14 +47,18 @@ files:
86
47
  - lib/minglr/property_definition.rb
87
48
  - lib/minglr/transition_execution.rb
88
49
  - lib/minglr/user.rb
50
+ - minglr.gemspec
51
+ - minglrconfig.sample
89
52
  - tasks/commit.sample.rake
90
53
  - tasks/svn.sample.rake
54
+ - test/attachment_test.rb
55
+ - test/minglr_resource_test.rb
56
+ - test/test_helper.rb
91
57
  has_rdoc: true
92
- homepage: http://github.com/schubert/minglr/tree/master
58
+ homepage: http://github.com/schubert/minglr
93
59
  post_install_message: PostInstall.txt
94
60
  rdoc_options:
95
- - --main
96
- - README.rdoc
61
+ - --charset=UTF-8
97
62
  require_paths:
98
63
  - lib
99
64
  required_ruby_version: !ruby/object:Gem::Requirement
@@ -110,10 +75,12 @@ required_rubygems_version: !ruby/object:Gem::Requirement
110
75
  version:
111
76
  requirements: []
112
77
 
113
- rubyforge_project: minglr
78
+ rubyforge_project:
114
79
  rubygems_version: 1.2.0
115
80
  signing_key:
116
81
  specification_version: 2
117
- summary: "* This gem provides two executable binaries to interact with Mingle (http://mingle.thoughtworks.com/mingle-agile-project-management) through its API"
118
- test_files: []
119
-
82
+ summary: command line user tool for Mingle (http://mingle.thoughtworks.com/mingle-agile-project-management)
83
+ test_files:
84
+ - test/attachment_test.rb
85
+ - test/minglr_resource_test.rb
86
+ - test/test_helper.rb
data/History.txt DELETED
@@ -1,8 +0,0 @@
1
- == 0.0.2 2009-04-08
2
- * Added minglr cli tool
3
- * Sample config file. Copy to ~/.minglrconfig
4
-
5
- == 0.0.1 2009-01-13
6
-
7
- * 1 major enhancement:
8
- * Initial release
data/Manifest.txt DELETED
@@ -1,22 +0,0 @@
1
- History.txt
2
- Manifest.txt
3
- PostInstall.txt
4
- README.rdoc
5
- Rakefile
6
- bin/mtx
7
- bin/minglr
8
- lib/minglr.rb
9
- lib/version.rb
10
- lib/minglr/attachment.rb
11
- lib/minglr/card.rb
12
- lib/minglr/input_cache.rb
13
- lib/minglr/mingle_resource.rb
14
- lib/minglr/minglr_action.rb
15
- lib/minglr/minglr_config_parser.rb
16
- lib/minglr/minglr_options_parser.rb
17
- lib/minglr/mtx_options_parser.rb
18
- lib/minglr/property_definition.rb
19
- lib/minglr/transition_execution.rb
20
- lib/minglr/user.rb
21
- tasks/commit.sample.rake
22
- tasks/svn.sample.rake
data/lib/version.rb DELETED
@@ -1 +0,0 @@
1
- MINGLR_VERSION = "1.0.6"