Permalink
Browse files

Merge branch 'deving'

  • Loading branch information...
2 parents aeaf3ea + dde7f5f commit befc50524c4673d68015576c40a29b9328778de3 @jeffWelling jeffWelling committed Feb 15, 2011
Showing with 1,135 additions and 978 deletions.
  1. +0 −5 .gitignore
  2. +1 −0 .rvmrc
  3. +0 −13 Gemfile
  4. +0 −30 Gemfile.lock
  5. +681 −0 LICENSE_GPL
  6. +9 −1 LICENSE → LICENSE_MIT
  7. +62 −30 README.mkd
  8. +0 −92 Rakefile
  9. +5 −9 bin/ti
  10. +6 −13 lib/{ticgit.rb → ticgit-ng.rb}
  11. +65 −49 lib/{ticgit → ticgit-ng}/base.rb
  12. +10 −9 lib/{ticgit → ticgit-ng}/cli.rb
  13. +3 −3 lib/{ticgit → ticgit-ng}/command.rb
  14. +1 −1 lib/{ticgit → ticgit-ng}/command/assign.rb
  15. +1 −1 lib/{ticgit → ticgit-ng}/command/checkout.rb
  16. +1 −1 lib/{ticgit → ticgit-ng}/command/comment.rb
  17. +1 −1 lib/{ticgit → ticgit-ng}/command/list.rb
  18. +1 −1 lib/{ticgit → ticgit-ng}/command/milestone.rb
  19. +1 −1 lib/{ticgit → ticgit-ng}/command/new.rb
  20. +1 −1 lib/{ticgit → ticgit-ng}/command/points.rb
  21. +1 −1 lib/{ticgit → ticgit-ng}/command/recent.rb
  22. +1 −1 lib/{ticgit → ticgit-ng}/command/show.rb
  23. +1 −1 lib/{ticgit → ticgit-ng}/command/state.rb
  24. +29 −0 lib/ticgit-ng/command/sync.rb
  25. +1 −1 lib/{ticgit → ticgit-ng}/command/tag.rb
  26. +1 −1 lib/{ticgit → ticgit-ng}/comment.rb
  27. +3 −3 lib/{ticgit → ticgit-ng}/ticket.rb
  28. +3 −0 lib/ticgit-ng/version.rb
  29. +0 −13 lib/ticgit/command/sync.rb
  30. +0 −3 lib/ticgit/version.rb
  31. +71 −70 spec/base_spec.rb
  32. +14 −14 spec/cli_spec.rb
  33. +111 −46 spec/merging_spec.rb
  34. +13 −13 spec/spec_helper.rb
  35. +13 −13 spec/ticgit_spec.rb
  36. +0 −30 tasks/authors.rake
  37. +0 −66 tasks/bacon.rake
  38. +0 −18 tasks/changelog.rake
  39. +0 −6 tasks/cucumber.rake
  40. +0 −22 tasks/gem.rake
  41. +0 −76 tasks/gem_installer.rake
  42. +0 −46 tasks/git.rake
  43. +0 −12 tasks/grancher.rake
  44. +0 −6 tasks/install_dependencies.rake
  45. +0 −4 tasks/manifest.rake
  46. +0 −32 tasks/metric_changes.rake
  47. +0 −23 tasks/rcov.rake
  48. +0 −69 tasks/release.rake
  49. +0 −8 tasks/reversion.rake
  50. +0 −24 tasks/setup.rake
  51. +0 −27 tasks/todo.rake
  52. +0 −21 tasks/traits.rake
  53. +0 −4 tasks/yard.rake
  54. +0 −22 tasks/ycov.rake
  55. +24 −0 ticgit-ng.gemspec
  56. +0 −21 ticgit.gemspec
View
@@ -1,5 +0,0 @@
-bin/*.log
-pkg
-coverage
-ticgit*gem
-tmp
View
1 .rvmrc
@@ -0,0 +1 @@
+rvm use --create default@ticgit
View
13 Gemfile
@@ -1,13 +0,0 @@
-source :rubygems
-
-gem 'rake'
-gem 'git', '>= 1.0.5'
-
-group :web do
- gem 'sinatra'
- gem 'haml'
-end
-
-group :dev do
- gem 'rspec', '>= 2.0.0.beta.22'
-end
View
@@ -1,30 +0,0 @@
-GEM
- remote: http://rubygems.org/
- specs:
- diff-lcs (1.1.2)
- git (1.2.5)
- haml (3.0.18)
- rack (1.2.1)
- rake (0.8.7)
- rspec (2.0.0.beta.22)
- rspec-core (= 2.0.0.beta.22)
- rspec-expectations (= 2.0.0.beta.22)
- rspec-mocks (= 2.0.0.beta.22)
- rspec-core (2.0.0.beta.22)
- rspec-expectations (2.0.0.beta.22)
- diff-lcs (>= 1.1.2)
- rspec-mocks (2.0.0.beta.22)
- rspec-core (= 2.0.0.beta.22)
- rspec-expectations (= 2.0.0.beta.22)
- sinatra (1.0)
- rack (>= 1.0)
-
-PLATFORMS
- ruby
-
-DEPENDENCIES
- git (>= 1.0.5)
- haml
- rake
- rspec (>= 2.0.0.beta.22)
- sinatra
View
Oops, something went wrong.
View
@@ -1,6 +1,14 @@
The MIT License
-Copyright (c) 2008 Scott Chacon
+Portions, Copyright (c) 2008 Scott Chacon
+Other portions, Copyright (c) 2011 Jeff Welling
+Other portions, Copyright of their respective authors.
+
+This MIT license and notice pertains ONLY to code NOT authored by Jeff Welling.
+Contributions by Jeff Welling are licensed under GPLv3, a copy of
+which is included with the source code. For information on determining
+which code was authored by whom, see
+http://www.kernel.org/pub/software/scm/git/docs/git-blame.html
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
View
@@ -1,19 +1,21 @@
-## TicGit ##
+## TicGit-ng ##
This project provides a ticketing system built on Git that is kept in a
-separate branch in your projects Git repository.
+separate branch in your projects Git repository. Originally called TicGit,
+it is now known as TicGit-ng to continue development and avoid namespace
+clashes.
### About ###
-TicGit is a simple ticketing system, roughly similar to the Lighthouse model, that is based in git. It provides a command line client that uses the ‘git’ gem to keep its ticketing information in a separate branch (called ‘ticgit’) within your existing git repository. All the data is file based and rarely changing, decreasing the likelihood of a merge issue. Right now, ticket branch merges need to be done manually and separately, but work is being done on a `ti sync` command to make this easier and more intuitive.
+TicGit-ng is a simple ticketing system, roughly similar to the Lighthouse model, that is based in git. It provides a command line client that uses the ‘git’ gem to keep its ticketing information in a separate branch (called ‘ticgit-ng’) within your existing git repository. All the data is file based and rarely changing, decreasing the likelihood of a merge issue. Right now, ticket branch merges need to be done manually and separately, but work is being done on a `ti sync` command to make this easier and more intuitive.
The idea is that it keeps your tickets in the same repository, but without mucking up your working tree. By using its own seperate branch to store its information it keeps the working trees in all your other branches untouched.
There are two interfaces available, the command line `ti` command and the `ticgitweb` web interface, though `ticgitweb` has many more prerequisites than `ti`.
-It will automatically create the new branch the first time you use it, and it caches all the data (another working directory and index file) in your ~/.ticgit directory by default. If you delete that directory, it will just create it again the next time, you will lose no data (except some of your saved preferences).
+It will automatically create the new branch the first time you use it, and it caches all the data (another working directory and index file) in your ~/.ticgit-ng directory by default. If you delete that directory, it will just create it again the next time, you will lose no data (except some of your saved preferences).
-TicGit is currently using itself to store its feature requests and bug reports.
+TicGit-ng is currently using itself to store its feature requests and bug reports.
### Prerequisites ###
@@ -66,7 +68,7 @@ And those notices should go away.
### Installing ###
-Installation on a Debian stable system. Note that the command line interface for ticgit can be run from Debian stable, but some of the gems required for the web interface may require you to use [apt](http://jaqque.sbih.org/kplug/apt-pinning.html) [pinning](http://jeffwelling.github.com//2010/09/05/Apt-Pinning.html) to run without errors. See below.
+Installation on a Debian stable system. Note that the command line interface for TicGit-ng can be run from Debian stable, but some of the gems required for the web interface may require you to use [apt](http://jaqque.sbih.org/kplug/apt-pinning.html) [pinning](http://jeffwelling.github.com//2010/09/05/Apt-Pinning.html) to run without errors. See below.
If you know what rake is and know you already have it installed, you can use the command `rake setup` to automatically install all dependencies, but the suggested method is to manually install as outlined below.
@@ -93,7 +95,7 @@ To get a list of all commands with short description:
Options for help command:
- The available ticgit commands are:
+ The available TicGit-ng commands are:
recent List recent activities
checkout Checkout a ticket
tag Modify tags of a ticket
@@ -143,7 +145,7 @@ The available commands are:
### Usage Examples ###
-The first time you use any command in ticgit, it will create a new branch in your repo called ‘ticgit’ and setup a caching area in ~/.ticgit.
+The first time you use any command in Ticgit-ng, it will create a new branch in your repo called ‘ticgit-ng’ and setup a caching area in ~/.ticgit-ng.
If you run it without arguments, it will tell you what is available to run
@@ -152,7 +154,7 @@ If you run it without arguments, it will tell you what is available to run
Usage: ti COMMAND [FLAGS] [ARGS]
- The available ticgit commands are:
+ The available TicGit-ng commands are:
recent List recent activities
checkout Checkout a ticket
tag Modify tags of a ticket
@@ -290,51 +292,79 @@ Then if you want to later list tickets with the same options as you used above,
## Collaboration ##
-If you have cloned a repository and would like to get the ticgit branch for that repo (presuming they have one), do this.
+If you have cloned a repository and would like to get the ticgit-ng branch for that repo (presuming they have one), do this.
- $git branch ticgit origin/ticgit
+ $git branch ticgit-ng origin/ticgit-ng
-This will create a ticgit branch in your local repo based on the ticgit branch in origin. Now you can run `ti list` and it will show you the ticgit tickets for that repository.
+This will create a ticgit-ng branch in your local repo based on the ticgit-ng branch in origin. Now you can run `ti list` and it will show you the ticgit-ng tickets for that repository.
+### Getting the TicGit-ng ticgit-ng branch ##
+
+To download your own copy of the TicGit-ng ticgit branch after cloning the repo, so that you can add or alter a bug yourself, follow these instructions.
+
+This will checkout a ticgit-ng branch and set it to track the ticgit-ng branch upstream in origin, and then checks out the master branch. You must checkout the master branch because TicGit-ng gets confused if you are already in the ticgit-ng branch when running TicGit-ng.
+
+ $ git checkout origin/ticgit-ng
+ $ git checkout -b ticgit-ng
+ $ git checkout master
+
+This will show you all of the bugs in TicGit-ng's ticgit-ng branch.
+
+ $ ti list
+
+To submit your changes back to the upstream maintainer, push the bugs in your ticgit-ng branch to your public repo on Github
+
+ $ git push origin ticgit-ng
+
+Then contact the upstream maintainer by sending a Pull Request or Email and ask them to review and accept your bug changes.
### Sharing your tickets with others ###
-Sharing your ticgit tickets with other people is as easy as asking them either creating their ticgit branch based on yours if they haven't already started their own ticgit branch, or pulling your ticgit branch into theirs.
+Sharing your ticgit tickets with other people is as easy as asking them either creating their ticgit-ng branch based on yours if they haven't already started their own ticgit-ng branch, or pulling your ticgit-ng branch into theirs.
-If you host your repositories on [Github](http://www.github.com) as I do then this process is simplified some because you don't have to worry about hosting your repository somewhere where other people can access it to pull your ticgit branch.
+If you host your repositories on [Github](http://www.github.com) as I do then this process is simplified some because you don't have to worry about hosting your repository somewhere where other people can access it to pull your ticgit-ng branch.
-For example, when I want my friend wnight to have the changes I made to my tickets in my ticgit repository, I do a
+For example, when I want my friend wnight to have the changes I made to my tickets in my ticgit-ng repository, I do a
$ git push origin
to update all my remote branches with my current ones, and then I ask him to do a
- $ git checkout ticgit
- $ git pull git@github.com:jeffWelling/ticgit.git ticgit
+ $ git checkout ticgit-ng
+ $ git pull git@github.com:jeffWelling/ticgit.git ticgit-ng
$ git checkout master
-to pull my changes into his ticgit branch and then switch back to his master branch. Now when he does `ti list` it will show the changes I made to the tickets on my system.
+to pull my changes into his ticgit-ng branch and then switch back to his master branch. Now when he does `ti list` it will show the changes I made to the tickets on my system.
-### Incorporating other peoples changes into your ticgit branch ###
+### Incorporating other peoples changes into your ticgit-ng branch ###
The process is much the same as above, except the rolls are reversed. Once you know they have published their changes and you have a URL to do a git pull from, you simply do
- $ git checkout ticgit
- $ git pull SOURCE_URL ticgit
+ $ git checkout ticgit-ng
+ $ git pull SOURCE_URL ticgit-ng
$ git checkout master
-Replacing SOURCE_URL with the URL you were told to pull from, now you can see the changes they made, in your ticgit branch. You can easily publish these changes with a `git push origin` so anyone following your work can also see these changes.
+Replacing SOURCE_URL with the URL you were told to pull from, now you can see the changes they made, in your ticgit-ng branch. You can easily publish these changes with a `git push origin` so anyone following your work can also see these changes.
### Next generation collaboration ###
-Changes made by [Bruno Santos](http://github.com/pheres) to add a [`ti sync`](http://github.com/jeffWelling/ticgit/commit/7388386fab4fb12c36e6eeb7d19eaa4e4b16b853) command are currently in the process of being integrated into the master branch. Once this is done, syncing with other people should be as easy as `ti sync REMOTE_REPO` where REMOTE_REPO is a repo URL.
+Changes made by [Bruno Santos](http://github.com/pheres) to add a [`ti sync`](http://github.com/jeffWelling/ticgit/commit/7388386fab4fb12c36e6eeb7d19eaa4e4b16b853) command were integrated on February 15th 2011. You can now use the `ti sync [options]` command to sync your tickets with anyone else you've added with `git remote add`. To use `ti sync`, all you need to do is first make sure you've already added the remote source with `git remote add`, and then do
+
+ $ ti sync --repo REMOTE_SOURCE
+
+if you want to pull their tickets into your ticgit-ng branch *and* push your tickets to their ticgit-ng branch, or
+ $ ti sync --repo REMOTE_SOURCE --no-push
+
+if you want to pull their tickets into your ticgit-ng branch without pushing your tickets to their branch.
+
+More information on using ti sync can be gleemed from reviewing the [merge specs](https://github.com/jeffWelling/ticgit/blob/deving/spec/merging_spec.rb)
### Ticgitweb ###
-To run the Sinatra enabled web UI for your TicGit repo, simply cd to your repository and run 'ticgitweb', or 'ticgitweb -p 3456' to change the port to something other than '4567', which is the Sinatra default.
+To run the Sinatra enabled web UI for your TicGit-ng repo, simply cd to your repository and run 'ticgitweb', or 'ticgitweb -p 3456' to change the port to something other than '4567', which is the Sinatra default.
Here is what the Ticket listing looks like:
@@ -347,11 +377,11 @@ And here is an individual ticket:
## Development ##
-The original author had used rspec to write specs for ticgit, but one of the maintainers since then switched it over to bacon[[1](http://www.ruby-forum.com/topic/137928)][[2](http://www.ruby-forum.com/topic/172139)][[3](http://testanything.org/wiki/index.php/Testing_with_Ruby)] and I haven't been too inclined to switch it back.
+The original author had used rspec to write specs for ticgit-ng, but one of the maintainers since then switched it over to bacon[[1](http://www.ruby-forum.com/topic/137928)][[2](http://www.ruby-forum.com/topic/172139)][[3](http://testanything.org/wiki/index.php/Testing_with_Ruby)] and I haven't been too inclined to switch it back.
### Prerequisites ###
-To install the prerequisites on Debian stable for testing ticgit, you will need [apt](http://jaqque.sbih.org/kplug/apt-pinning.html) [pinning](http://jeffwelling.github.com//2010/09/05/Apt-Pinning.html).
+To install the prerequisites on Debian stable for testing ticgit-ng, you will need [apt](http://jaqque.sbih.org/kplug/apt-pinning.html) [pinning](http://jeffwelling.github.com//2010/09/05/Apt-Pinning.html).
$ sudo aptitude -t testing install rubygems rake
$ sudo gem install yard bacon
@@ -361,17 +391,19 @@ I pull rubygems from testing to avoid a problem with gherkin creating a syntacti
### How To Test ###
-To test your version of ticgit, go to your ticgit directory and run
+To test your version of ticgit-ng, go to your ticgit-ng directory and run
rake bacon
-### How to generate a gem from your development copy of ticgit ###
+### How to generate a gem from your development copy of ticgit-ng ###
-To create a gem from your development copy of ticgit, go to your ticgit directory and do
+To create a gem from your development copy of ticgit-ng, go to your ticgit-ng directory and do
rake gem
-This will create a pkg/ directory, which will contain a newly created ticgit gem for you to install.
+This will create a pkg/ directory, which will contain a newly created ticgit-ng gem for you to install.
+
+More information on developing TicGit-ng and collaborating with other TicGit-ng developers at [here](https://github.com/jeffWelling/ticgit/wiki/Development)
More information on developing TicGit-ng and collaborating with other TicGit-ng developers at [here](https://github.com/jeffWelling/ticgit/wiki/Development)
View
@@ -1,92 +0,0 @@
-# Ensure that the basics are installed before doing anything more
-# complicated.
-%w[rubygems bundler].each do |gem|
- begin
- require gem
- rescue LoadError
- $stderr.puts 'Missing gem: ' << gem
- $load_error = true
- end
-end
-exit 1 if $load_error
-
-# This namespace must be loaded near the top in order to be able to
-# display bundle-related rake tasks in the next section.
-namespace :bundle do
- namespace :install do
- desc 'Install gems for all tasks, including testing.'
- task :all do
- system 'bundle install'
- end
-
- desc 'Install standard CLI and web dependencies.'
- task :std do
- system 'bundle install --without dev'
- end
-
- # The gem will not currently build properly without the ticgitweb
- # dependencies. Leave this task commented until the gemspec will
- # build just the CLI.
- #desc 'Install CLI dependencies only.'
- #task :cli do
- # system 'bundle install --without dev web'
- #end
- end
-
- desc 'List bundled gems.'
- task :show do
- system 'bundle show'
- end
-end
-
-# If 'bundler install' hasn't been run, display the available bundler
-# tasks.
-unless File.directory? '.bundle'
- $stderr.puts 'You must run one of the bundle:install tasks first:'
- $stderr.puts
- Rake::Task.tasks.each {|task| $stderr.puts " rake #{task}"}
- $stderr.puts
- exit 1 if ARGV.to_s.grep(/bundle:install/).empty?
-end
-
-require 'bundler/setup'
-require 'rake/gempackagetask'
-
-begin
- require "rspec/core/rake_task"
- namespace :test do
- desc 'Run all RSpec tests'
- RSpec::Core::RakeTask.new
-
- desc 'Remove RSpec temp directories'
- task :clean do
- rmtree Dir.glob('/tmp/ticgit-*')
- end
- end
-rescue LoadError
- $stderr.puts 'RSpec ~> 2.0 needed for testing.'
- $stderr.puts
-end
-
-gemspec = eval(File.read('ticgit.gemspec'))
-Rake::GemPackageTask.new(gemspec) do |pkg|
- pkg.need_tar = true
-end
-
-desc "Clean out the coverage and pkg directories"
-task :clean do
- rm_rf 'coverage'
- rm_rf 'pkg'
- rm Dir.glob('ticgit*gem')
-end
-
-task :make => "pkg/#{gemspec.name}-#{gemspec.version}.gem" do
- puts "Generating #{gemspec.name}-#{gemspec.version}.gem"
-end
-
-task :install do
- puts "Installing #{gemspec.name}-#{gemspec.version}.gem ..."
- system "gem install pkg/#{gemspec.name}-#{gemspec.version}.gem"
-end
-
-task :default => [:make, :install]
View
14 bin/ti
@@ -1,17 +1,13 @@
#!/usr/bin/env ruby
-
-# This is a command line client that does all the actual tic commands
-#
-# author : Scott Chacon (schacon@gmail.com)
-#
-
require 'rubygems'
require 'fileutils'
# Add the library from the source tree to the front of the load path.
# This allows ti to run without first installing a ticgit gem, which is
# important when testing multiple branches of development.
-$LOAD_PATH.unshift File.join(File.dirname(__FILE__), '..', 'lib')
-require 'ticgit'
+if File.exist? File.join('lib', 'ticgit-ng.rb')
+ $LOAD_PATH.unshift File.join(File.dirname(__FILE__), '..', 'lib')
+end
+require 'ticgit-ng'
-TicGit::CLI.execute
+TicGitNG::CLI.execute
Oops, something went wrong.

0 comments on commit befc505

Please sign in to comment.