git-dag 0.0.1 → 0.0.2

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.
@@ -0,0 +1,36 @@
1
+ ## git-dag
2
+
3
+ git-dag is a ruby script that generates a DAG tree (in the 'dot' format) for a
4
+ given Git repository.
5
+
6
+ ## Preprequisite
7
+ You need to have [Graphviz](http://graphviz.org/) installed if you want
8
+ to render the DAG visually. You can install it using the package manager
9
+ provided by your OS.
10
+
11
+ For instance, if you use Mac OS X and have homebrew installed, you can do:
12
+
13
+ $ brew install graphviz
14
+
15
+ ## Install
16
+ Easy install with RubyGems:
17
+
18
+ $ gem install git-dag
19
+
20
+ ## Usage
21
+ To generate a DAG (in the format 'dot') for a Git repository, do
22
+
23
+ $ git-dag <path_to_git_repo> > history.dot
24
+
25
+ Use to 'dot' to draw the DAG:
26
+
27
+ $ dot -Tsvg history.dot -o history.svg
28
+
29
+ You can pipe the 2 commands together:
30
+
31
+ $ git-dag <path_to_git_repo> | dot -Tsvg -o history.svg
32
+
33
+ Now you can open up 'history.svg' to see the DAG.
34
+
35
+ Graphviz supports a lot of other formats, such as jpg, pdf, png, ps2 etc. Please
36
+ see [Graphviz](http://graphviz.org/) for more info.
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env ruby
2
2
 
3
- require_relative "../lib/git-dag"
3
+ require 'git-dag'
4
4
 
5
5
  GitDag::Application.run(ARGV[0])
6
6
 
@@ -0,0 +1,22 @@
1
+ # -*- encoding: utf-8 -*-
2
+ $:.push File.expand_path("../lib", __FILE__)
3
+ require "git-dag/version"
4
+
5
+ Gem::Specification.new do |s|
6
+ s.name = "git-dag"
7
+ s.version = GitDag::VERSION
8
+ s.authors = ["Jingjing Duan"]
9
+ s.email = ["jingjing.duan@gmail.com"]
10
+ s.homepage = "https://github.com/jduan/git-dag"
11
+ s.summary = %q{A ruby script that generates a 'dot' file (Git DAG tree) for a given Git repository.}
12
+ s.description = %q{A ruby script that generates a 'dot' file (Git DAG tree) for a given Git repository.}
13
+
14
+ s.required_rubygems_version = ">= 1.8.10"
15
+
16
+ s.files = `git ls-files`.split("\n")
17
+ s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
18
+ s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
19
+ s.require_paths = ["lib"]
20
+
21
+ s.add_dependency("grit", "~> 2.5.0")
22
+ end
@@ -0,0 +1,3 @@
1
+ module GitDag
2
+ VERSION = "0.0.2"
3
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: git-dag
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -37,14 +37,17 @@ extensions: []
37
37
  extra_rdoc_files: []
38
38
  files:
39
39
  - .gitignore
40
+ - README.md
40
41
  - Rakefile
41
42
  - bin/git-dag
43
+ - git-dag.gemspec
42
44
  - lib/git-dag.rb
43
45
  - lib/git-dag/application.rb
44
46
  - lib/git-dag/commit_node.rb
45
47
  - lib/git-dag/fake_head.rb
46
48
  - lib/git-dag/git_graph.rb
47
49
  - lib/git-dag/node.rb
50
+ - lib/git-dag/version.rb
48
51
  - test/integ/git_graph_test.rb
49
52
  - test/test_helper.rb
50
53
  homepage: https://github.com/jduan/git-dag
@@ -67,7 +70,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
67
70
  version: 1.8.10
68
71
  requirements: []
69
72
  rubyforge_project:
70
- rubygems_version: 1.8.23
73
+ rubygems_version: 1.8.24
71
74
  signing_key:
72
75
  specification_version: 3
73
76
  summary: A ruby script that generates a 'dot' file (Git DAG tree) for a given Git