grack 0.0.2 → 0.1.0.pre1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (48) hide show
  1. checksums.yaml +7 -0
  2. data/.travis.yml +7 -0
  3. data/.yardopts +1 -0
  4. data/LICENSE +22 -0
  5. data/NEWS.md +19 -0
  6. data/README.md +211 -0
  7. data/Rakefile +222 -0
  8. data/lib/git_adapter.rb +1 -0
  9. data/lib/grack.rb +1 -0
  10. data/lib/grack/app.rb +482 -0
  11. data/lib/grack/compatible_git_adapter.rb +99 -0
  12. data/lib/grack/file_streamer.rb +41 -0
  13. data/lib/grack/git_adapter.rb +142 -0
  14. data/lib/grack/io_streamer.rb +45 -0
  15. data/tests/app_test.rb +534 -0
  16. data/tests/compatible_git_adapter_test.rb +137 -0
  17. data/tests/example/_git/COMMIT_EDITMSG +1 -0
  18. data/tests/example/_git/HEAD +1 -0
  19. data/tests/example/_git/config +6 -0
  20. data/tests/example/_git/description +1 -0
  21. data/tests/example/_git/hooks/applypatch-msg.sample +15 -0
  22. data/tests/example/_git/hooks/commit-msg.sample +24 -0
  23. data/tests/example/_git/hooks/post-commit.sample +8 -0
  24. data/tests/example/_git/hooks/post-receive.sample +15 -0
  25. data/tests/example/_git/hooks/post-update.sample +8 -0
  26. data/tests/example/_git/hooks/pre-applypatch.sample +14 -0
  27. data/tests/example/_git/hooks/pre-commit.sample +50 -0
  28. data/tests/example/_git/hooks/pre-rebase.sample +169 -0
  29. data/tests/example/_git/hooks/prepare-commit-msg.sample +36 -0
  30. data/tests/example/_git/hooks/update.sample +128 -0
  31. data/tests/example/_git/index +0 -0
  32. data/tests/example/_git/info/exclude +6 -0
  33. data/tests/example/_git/info/refs +1 -0
  34. data/tests/example/_git/logs/HEAD +1 -0
  35. data/tests/example/_git/logs/refs/heads/master +1 -0
  36. data/tests/example/_git/objects/31/d73eb4914a8ddb6cb0e4adf250777161118f90 +0 -0
  37. data/tests/example/_git/objects/cb/067e06bdf6e34d4abebf6cf2de85d65a52c65e +0 -0
  38. data/tests/example/_git/objects/ce/013625030ba8dba906f756967f9e9ca394464a +0 -0
  39. data/tests/example/_git/objects/info/packs +2 -0
  40. data/tests/example/_git/objects/pack/pack-62c9f443d8405cd6da92dcbb4f849cc01a339c06.idx +0 -0
  41. data/tests/example/_git/objects/pack/pack-62c9f443d8405cd6da92dcbb4f849cc01a339c06.pack +0 -0
  42. data/tests/example/_git/refs/heads/master +1 -0
  43. data/tests/file_streamer_test.rb +37 -0
  44. data/tests/git_adapter_test.rb +104 -0
  45. data/tests/io_streamer_test.rb +36 -0
  46. data/tests/test_helper.rb +36 -0
  47. metadata +292 -19
  48. data/lib/git_http.rb +0 -304
@@ -0,0 +1,36 @@
1
+ #!/bin/sh
2
+ #
3
+ # An example hook script to prepare the commit log message.
4
+ # Called by "git commit" with the name of the file that has the
5
+ # commit message, followed by the description of the commit
6
+ # message's source. The hook's purpose is to edit the commit
7
+ # message file. If the hook fails with a non-zero status,
8
+ # the commit is aborted.
9
+ #
10
+ # To enable this hook, rename this file to "prepare-commit-msg".
11
+
12
+ # This hook includes three examples. The first comments out the
13
+ # "Conflicts:" part of a merge commit.
14
+ #
15
+ # The second includes the output of "git diff --name-status -r"
16
+ # into the message, just before the "git status" output. It is
17
+ # commented because it doesn't cope with --amend or with squashed
18
+ # commits.
19
+ #
20
+ # The third example adds a Signed-off-by line to the message, that can
21
+ # still be edited. This is rarely a good idea.
22
+
23
+ case "$2,$3" in
24
+ merge,)
25
+ /usr/bin/perl -i.bak -ne 's/^/# /, s/^# #/#/ if /^Conflicts/ .. /#/; print' "$1" ;;
26
+
27
+ # ,|template,)
28
+ # /usr/bin/perl -i.bak -pe '
29
+ # print "\n" . `git diff --cached --name-status -r`
30
+ # if /^#/ && $first++ == 0' "$1" ;;
31
+
32
+ *) ;;
33
+ esac
34
+
35
+ # SOB=$(git var GIT_AUTHOR_IDENT | sed -n 's/^\(.*>\).*$/Signed-off-by: \1/p')
36
+ # grep -qs "^$SOB" "$1" || echo "$SOB" >> "$1"
@@ -0,0 +1,128 @@
1
+ #!/bin/sh
2
+ #
3
+ # An example hook script to blocks unannotated tags from entering.
4
+ # Called by "git receive-pack" with arguments: refname sha1-old sha1-new
5
+ #
6
+ # To enable this hook, rename this file to "update".
7
+ #
8
+ # Config
9
+ # ------
10
+ # hooks.allowunannotated
11
+ # This boolean sets whether unannotated tags will be allowed into the
12
+ # repository. By default they won't be.
13
+ # hooks.allowdeletetag
14
+ # This boolean sets whether deleting tags will be allowed in the
15
+ # repository. By default they won't be.
16
+ # hooks.allowmodifytag
17
+ # This boolean sets whether a tag may be modified after creation. By default
18
+ # it won't be.
19
+ # hooks.allowdeletebranch
20
+ # This boolean sets whether deleting branches will be allowed in the
21
+ # repository. By default they won't be.
22
+ # hooks.denycreatebranch
23
+ # This boolean sets whether remotely creating branches will be denied
24
+ # in the repository. By default this is allowed.
25
+ #
26
+
27
+ # --- Command line
28
+ refname="$1"
29
+ oldrev="$2"
30
+ newrev="$3"
31
+
32
+ # --- Safety check
33
+ if [ -z "$GIT_DIR" ]; then
34
+ echo "Don't run this script from the command line." >&2
35
+ echo " (if you want, you could supply GIT_DIR then run" >&2
36
+ echo " $0 <ref> <oldrev> <newrev>)" >&2
37
+ exit 1
38
+ fi
39
+
40
+ if [ -z "$refname" -o -z "$oldrev" -o -z "$newrev" ]; then
41
+ echo "Usage: $0 <ref> <oldrev> <newrev>" >&2
42
+ exit 1
43
+ fi
44
+
45
+ # --- Config
46
+ allowunannotated=$(git config --bool hooks.allowunannotated)
47
+ allowdeletebranch=$(git config --bool hooks.allowdeletebranch)
48
+ denycreatebranch=$(git config --bool hooks.denycreatebranch)
49
+ allowdeletetag=$(git config --bool hooks.allowdeletetag)
50
+ allowmodifytag=$(git config --bool hooks.allowmodifytag)
51
+
52
+ # check for no description
53
+ projectdesc=$(sed -e '1q' "$GIT_DIR/description")
54
+ case "$projectdesc" in
55
+ "Unnamed repository"* | "")
56
+ echo "*** Project description file hasn't been set" >&2
57
+ exit 1
58
+ ;;
59
+ esac
60
+
61
+ # --- Check types
62
+ # if $newrev is 0000...0000, it's a commit to delete a ref.
63
+ zero="0000000000000000000000000000000000000000"
64
+ if [ "$newrev" = "$zero" ]; then
65
+ newrev_type=delete
66
+ else
67
+ newrev_type=$(git cat-file -t $newrev)
68
+ fi
69
+
70
+ case "$refname","$newrev_type" in
71
+ refs/tags/*,commit)
72
+ # un-annotated tag
73
+ short_refname=${refname##refs/tags/}
74
+ if [ "$allowunannotated" != "true" ]; then
75
+ echo "*** The un-annotated tag, $short_refname, is not allowed in this repository" >&2
76
+ echo "*** Use 'git tag [ -a | -s ]' for tags you want to propagate." >&2
77
+ exit 1
78
+ fi
79
+ ;;
80
+ refs/tags/*,delete)
81
+ # delete tag
82
+ if [ "$allowdeletetag" != "true" ]; then
83
+ echo "*** Deleting a tag is not allowed in this repository" >&2
84
+ exit 1
85
+ fi
86
+ ;;
87
+ refs/tags/*,tag)
88
+ # annotated tag
89
+ if [ "$allowmodifytag" != "true" ] && git rev-parse $refname > /dev/null 2>&1
90
+ then
91
+ echo "*** Tag '$refname' already exists." >&2
92
+ echo "*** Modifying a tag is not allowed in this repository." >&2
93
+ exit 1
94
+ fi
95
+ ;;
96
+ refs/heads/*,commit)
97
+ # branch
98
+ if [ "$oldrev" = "$zero" -a "$denycreatebranch" = "true" ]; then
99
+ echo "*** Creating a branch is not allowed in this repository" >&2
100
+ exit 1
101
+ fi
102
+ ;;
103
+ refs/heads/*,delete)
104
+ # delete branch
105
+ if [ "$allowdeletebranch" != "true" ]; then
106
+ echo "*** Deleting a branch is not allowed in this repository" >&2
107
+ exit 1
108
+ fi
109
+ ;;
110
+ refs/remotes/*,commit)
111
+ # tracking branch
112
+ ;;
113
+ refs/remotes/*,delete)
114
+ # delete tracking branch
115
+ if [ "$allowdeletebranch" != "true" ]; then
116
+ echo "*** Deleting a tracking branch is not allowed in this repository" >&2
117
+ exit 1
118
+ fi
119
+ ;;
120
+ *)
121
+ # Anything else (is there anything else?)
122
+ echo "*** Update hook: unknown type of update to ref $refname of type $newrev_type" >&2
123
+ exit 1
124
+ ;;
125
+ esac
126
+
127
+ # --- Finished
128
+ exit 0
Binary file
@@ -0,0 +1,6 @@
1
+ # git ls-files --others --exclude-from=.git/info/exclude
2
+ # Lines that start with '#' are comments.
3
+ # For a project mostly in C, the following would be a good set of
4
+ # exclude patterns (uncomment them if you want to use them):
5
+ # *.[oa]
6
+ # *~
@@ -0,0 +1 @@
1
+ cb067e06bdf6e34d4abebf6cf2de85d65a52c65e refs/heads/master
@@ -0,0 +1 @@
1
+ 0000000000000000000000000000000000000000 cb067e06bdf6e34d4abebf6cf2de85d65a52c65e Dawa Ometto <dawa.ometto@phil.uu.nl> 1370206701 +0200 commit (initial): Test Example
@@ -0,0 +1 @@
1
+ 0000000000000000000000000000000000000000 cb067e06bdf6e34d4abebf6cf2de85d65a52c65e Dawa Ometto <dawa.ometto@phil.uu.nl> 1370206701 +0200 commit (initial): Test Example
@@ -0,0 +1,2 @@
1
+ P pack-62c9f443d8405cd6da92dcbb4f849cc01a339c06.pack
2
+
@@ -0,0 +1 @@
1
+ cb067e06bdf6e34d4abebf6cf2de85d65a52c65e
@@ -0,0 +1,37 @@
1
+ require_relative 'test_helper'
2
+
3
+ require 'minitest/autorun'
4
+ require 'minitest/unit'
5
+ require 'tempfile'
6
+
7
+ require 'grack/file_streamer'
8
+
9
+ class FileStreamerTest < MiniTest::Test
10
+ include Grack
11
+
12
+ def setup
13
+ @content = 'abcd' * 10_000
14
+ @file = Tempfile.new('foo')
15
+ @file.write(@content)
16
+ @file.rewind
17
+ @file.close
18
+ @streamer = FileStreamer.new(@file.path)
19
+ end
20
+
21
+ def teardown
22
+ @file.unlink
23
+ end
24
+
25
+ def test_to_path
26
+ assert_equal @file.path, @streamer.to_path
27
+ end
28
+
29
+ def test_mtime
30
+ assert_equal File.mtime(@file.path), @streamer.mtime
31
+ end
32
+
33
+ def test_each
34
+ assert_equal @content, @streamer.to_enum.to_a.join
35
+ end
36
+
37
+ end
@@ -0,0 +1,104 @@
1
+ require_relative 'test_helper'
2
+
3
+ require 'fileutils'
4
+ require 'minitest/autorun'
5
+ require 'minitest/unit'
6
+ require 'mocha/setup'
7
+ require 'stringio'
8
+
9
+ require 'grack/git_adapter'
10
+
11
+
12
+ class GitAdapterTest < Minitest::Test
13
+ include Grack
14
+
15
+ GIT_RECEIVE_RESPONSE = %r{\A001b# service=receive-pack\n0000[0-9a-f]{4}cb067e06bdf6e34d4abebf6cf2de85d65a52c65e refs/heads/master\000\s*report-status delete-refs side-band-64k quiet ofs-delta.*\n0000\z}
16
+
17
+ def git_config_set(name, value)
18
+ system(git_path, 'config', '--local', name, value, :chdir => example_repo)
19
+ end
20
+
21
+ def git_config_unset(name)
22
+ system(
23
+ git_path, 'config', '--local', '--unset-all', name, :chdir => example_repo
24
+ )
25
+ end
26
+
27
+ def setup
28
+ init_example_repository
29
+ @test_git = GitAdapter.new(git_path)
30
+ @test_git.repository_path = example_repo
31
+ end
32
+
33
+ def teardown
34
+ remove_example_repository
35
+ end
36
+
37
+ def test_break_with_bad_git_path
38
+ test_git = GitAdapter.new('a/highly/unlikely/path/to/git')
39
+ test_git.repository_path = example_repo
40
+ assert_raises(Errno::ENOENT) do
41
+ test_git.handle_pack('receive-pack', StringIO.new, StringIO.new)
42
+ end
43
+ end
44
+
45
+ def test_receive_pack
46
+ output = StringIO.new
47
+ @test_git.handle_pack(
48
+ 'receive-pack', StringIO.new, output, :advertise_refs => true
49
+ )
50
+
51
+ assert_match GIT_RECEIVE_RESPONSE, output.string
52
+ end
53
+
54
+ def test_upload_pack
55
+ input = StringIO.new('0000')
56
+ output = StringIO.new
57
+ @test_git.handle_pack('upload-pack', input, output)
58
+
59
+ assert_equal '', output.string
60
+ end
61
+
62
+ def test_update_server_info
63
+ refs_file = File.join(example_repo, 'info/refs')
64
+ refs = File.read(refs_file)
65
+ File.unlink(refs_file)
66
+ assert ! File.exist?(refs_file), 'refs file exists'
67
+ @test_git.update_server_info
68
+ assert_equal refs, File.read(refs_file)
69
+ end
70
+
71
+ def test_exist
72
+ assert @test_git.exist?
73
+ @test_git.repository_path = 'a/highly/unlikely/path/to/a/repository'
74
+ assert ! @test_git.exist?
75
+ end
76
+
77
+ def test_file
78
+ assert_nil @test_git.file('a/highly/unlikely/path/to/a/file')
79
+
80
+ object_path = 'objects/31/d73eb4914a8ddb6cb0e4adf250777161118f90'
81
+ file_path = File.join(example_repo, object_path)
82
+ git_file = @test_git.file(object_path)
83
+
84
+ assert_equal file_path, git_file.to_path.to_s
85
+ assert_equal File.mtime(file_path), git_file.mtime
86
+ end
87
+
88
+ def test_allow_push
89
+ assert ! @test_git.allow_push?, 'Expected allow_push? to return false'
90
+ git_config_set('http.receivepack', 'false')
91
+ assert ! @test_git.allow_push?, 'Expected allow_push? to return false'
92
+ git_config_set('http.receivepack', 'true')
93
+ assert @test_git.allow_push?, 'Expected allow_push? to return true'
94
+ end
95
+
96
+ def test_allow_pull
97
+ assert @test_git.allow_pull?, 'Expected allow_pull? to return true'
98
+ git_config_set('http.uploadpack', 'false')
99
+ assert ! @test_git.allow_pull?, 'Expected allow_pull? to return false'
100
+ git_config_set('http.uploadpack', 'true')
101
+ assert @test_git.allow_pull?, 'Expected allow_pull? to return true'
102
+ end
103
+
104
+ end
@@ -0,0 +1,36 @@
1
+ require_relative 'test_helper'
2
+
3
+ require 'minitest/autorun'
4
+ require 'minitest/unit'
5
+ require 'tempfile'
6
+
7
+ require 'grack/io_streamer'
8
+
9
+ class IOStreamerTest < MiniTest::Test
10
+ include Grack
11
+
12
+ def setup
13
+ @content = 'abcd' * 10_000
14
+ @file = Tempfile.new('foo')
15
+ @file.write(@content)
16
+ @file.rewind
17
+ @streamer = IOStreamer.new(@file, @file.mtime)
18
+ end
19
+
20
+ def teardown
21
+ @file.close
22
+ @file.unlink
23
+ end
24
+
25
+ def test_to_path
26
+ assert ! @streamer.respond_to?(:to_path), 'responds to #to_path'
27
+ end
28
+ def test_mtime
29
+ assert_equal File.mtime(@file.path), @streamer.mtime
30
+ end
31
+
32
+ def test_each
33
+ assert_equal @content, @streamer.to_enum.to_a.join
34
+ end
35
+
36
+ end
@@ -0,0 +1,36 @@
1
+ require 'pathname'
2
+ require 'simplecov'
3
+ require 'tmpdir'
4
+
5
+ SimpleCov.start do
6
+ add_filter 'tests/'
7
+ end
8
+
9
+ $: << File.expand_path('../../lib', __FILE__)
10
+
11
+ def git_path
12
+ ENV.fetch('GIT_PATH', 'git') # Path to git on test system
13
+ end
14
+
15
+ def stock_repo
16
+ File.expand_path('../example/_git', __FILE__)
17
+ end
18
+
19
+ def repositories_root
20
+ @repositories_root
21
+ end
22
+
23
+ def example_repo
24
+ @example_repo
25
+ end
26
+
27
+ def init_example_repository
28
+ @repositories_root = Pathname.new(Dir.mktmpdir('grack-testing'))
29
+ @example_repo = @repositories_root + 'example_repo.git'
30
+
31
+ FileUtils.cp_r(stock_repo, example_repo)
32
+ end
33
+
34
+ def remove_example_repository
35
+ FileUtils.remove_entry_secure(repositories_root)
36
+ end
metadata CHANGED
@@ -1,48 +1,321 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: grack
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
5
- prerelease:
4
+ version: 0.1.0.pre1
6
5
  platform: ruby
7
6
  authors:
8
7
  - Scott Chacon
9
- - Akshay Rawat
8
+ - Dawa Ometto
9
+ - Jeremy Bopp
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2012-10-10 00:00:00.000000000 Z
14
- dependencies: []
15
- description: Git Smart HTTP Server Rack Implementation. Use it as a middleware.
13
+ date: 2015-09-14 00:00:00.000000000 Z
14
+ dependencies:
15
+ - !ruby/object:Gem::Dependency
16
+ name: rack
17
+ requirement: !ruby/object:Gem::Requirement
18
+ requirements:
19
+ - - '>='
20
+ - !ruby/object:Gem::Version
21
+ version: '0'
22
+ type: :runtime
23
+ prerelease: false
24
+ version_requirements: !ruby/object:Gem::Requirement
25
+ requirements:
26
+ - - '>='
27
+ - !ruby/object:Gem::Version
28
+ version: '0'
29
+ - !ruby/object:Gem::Dependency
30
+ name: rake
31
+ requirement: !ruby/object:Gem::Requirement
32
+ requirements:
33
+ - - ~>
34
+ - !ruby/object:Gem::Version
35
+ version: '10.1'
36
+ - - '>='
37
+ - !ruby/object:Gem::Version
38
+ version: 10.1.1
39
+ type: :development
40
+ prerelease: false
41
+ version_requirements: !ruby/object:Gem::Requirement
42
+ requirements:
43
+ - - ~>
44
+ - !ruby/object:Gem::Version
45
+ version: '10.1'
46
+ - - '>='
47
+ - !ruby/object:Gem::Version
48
+ version: 10.1.1
49
+ - !ruby/object:Gem::Dependency
50
+ name: rack-test
51
+ requirement: !ruby/object:Gem::Requirement
52
+ requirements:
53
+ - - ~>
54
+ - !ruby/object:Gem::Version
55
+ version: '0.6'
56
+ - - '>='
57
+ - !ruby/object:Gem::Version
58
+ version: 0.6.3
59
+ type: :development
60
+ prerelease: false
61
+ version_requirements: !ruby/object:Gem::Requirement
62
+ requirements:
63
+ - - ~>
64
+ - !ruby/object:Gem::Version
65
+ version: '0.6'
66
+ - - '>='
67
+ - !ruby/object:Gem::Version
68
+ version: 0.6.3
69
+ - !ruby/object:Gem::Dependency
70
+ name: minitest
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - ~>
74
+ - !ruby/object:Gem::Version
75
+ version: '5.8'
76
+ - - '>='
77
+ - !ruby/object:Gem::Version
78
+ version: 5.8.0
79
+ type: :development
80
+ prerelease: false
81
+ version_requirements: !ruby/object:Gem::Requirement
82
+ requirements:
83
+ - - ~>
84
+ - !ruby/object:Gem::Version
85
+ version: '5.8'
86
+ - - '>='
87
+ - !ruby/object:Gem::Version
88
+ version: 5.8.0
89
+ - !ruby/object:Gem::Dependency
90
+ name: mocha
91
+ requirement: !ruby/object:Gem::Requirement
92
+ requirements:
93
+ - - ~>
94
+ - !ruby/object:Gem::Version
95
+ version: '1.1'
96
+ - - '>='
97
+ - !ruby/object:Gem::Version
98
+ version: 1.1.0
99
+ type: :development
100
+ prerelease: false
101
+ version_requirements: !ruby/object:Gem::Requirement
102
+ requirements:
103
+ - - ~>
104
+ - !ruby/object:Gem::Version
105
+ version: '1.1'
106
+ - - '>='
107
+ - !ruby/object:Gem::Version
108
+ version: 1.1.0
109
+ - !ruby/object:Gem::Dependency
110
+ name: simplecov
111
+ requirement: !ruby/object:Gem::Requirement
112
+ requirements:
113
+ - - ~>
114
+ - !ruby/object:Gem::Version
115
+ version: '0.10'
116
+ - - '>='
117
+ - !ruby/object:Gem::Version
118
+ version: 0.10.0
119
+ type: :development
120
+ prerelease: false
121
+ version_requirements: !ruby/object:Gem::Requirement
122
+ requirements:
123
+ - - ~>
124
+ - !ruby/object:Gem::Version
125
+ version: '0.10'
126
+ - - '>='
127
+ - !ruby/object:Gem::Version
128
+ version: 0.10.0
129
+ - !ruby/object:Gem::Dependency
130
+ name: yard
131
+ requirement: !ruby/object:Gem::Requirement
132
+ requirements:
133
+ - - ~>
134
+ - !ruby/object:Gem::Version
135
+ version: 0.8.7
136
+ - - '>='
137
+ - !ruby/object:Gem::Version
138
+ version: 0.8.7.3
139
+ type: :development
140
+ prerelease: false
141
+ version_requirements: !ruby/object:Gem::Requirement
142
+ requirements:
143
+ - - ~>
144
+ - !ruby/object:Gem::Version
145
+ version: 0.8.7
146
+ - - '>='
147
+ - !ruby/object:Gem::Version
148
+ version: 0.8.7.3
149
+ - !ruby/object:Gem::Dependency
150
+ name: redcarpet
151
+ requirement: !ruby/object:Gem::Requirement
152
+ requirements:
153
+ - - ~>
154
+ - !ruby/object:Gem::Version
155
+ version: '3.1'
156
+ - - '>='
157
+ - !ruby/object:Gem::Version
158
+ version: 3.1.0
159
+ type: :development
160
+ prerelease: false
161
+ version_requirements: !ruby/object:Gem::Requirement
162
+ requirements:
163
+ - - ~>
164
+ - !ruby/object:Gem::Version
165
+ version: '3.1'
166
+ - - '>='
167
+ - !ruby/object:Gem::Version
168
+ version: 3.1.0
169
+ - !ruby/object:Gem::Dependency
170
+ name: github-markup
171
+ requirement: !ruby/object:Gem::Requirement
172
+ requirements:
173
+ - - ~>
174
+ - !ruby/object:Gem::Version
175
+ version: '1.0'
176
+ - - '>='
177
+ - !ruby/object:Gem::Version
178
+ version: 1.0.2
179
+ type: :development
180
+ prerelease: false
181
+ version_requirements: !ruby/object:Gem::Requirement
182
+ requirements:
183
+ - - ~>
184
+ - !ruby/object:Gem::Version
185
+ version: '1.0'
186
+ - - '>='
187
+ - !ruby/object:Gem::Version
188
+ version: 1.0.2
189
+ - !ruby/object:Gem::Dependency
190
+ name: pry
191
+ requirement: !ruby/object:Gem::Requirement
192
+ requirements:
193
+ - - ~>
194
+ - !ruby/object:Gem::Version
195
+ version: '0'
196
+ type: :development
197
+ prerelease: false
198
+ version_requirements: !ruby/object:Gem::Requirement
199
+ requirements:
200
+ - - ~>
201
+ - !ruby/object:Gem::Version
202
+ version: '0'
203
+ description: |
204
+ This project aims to replace the builtin git-http-backend CGI handler
205
+ distributed with C Git with a Rack application. By default, Grack uses calls to
206
+ git on the system to implement Smart HTTP. Since the git-http-backend is really
207
+ just a simple wrapper for the upload-pack and receive-pack processes with the
208
+ '--stateless-rpc' option, this does not actually re-implement very much.
209
+ However, it is possible to use a different backend by specifying a different
210
+ Adapter.
16
211
  email:
17
212
  - schacon@gmail.com
18
- - projects@akshay.cc
213
+ - dawa.ometto@phil.uu.nl
214
+ - jeremy@bopp.net
19
215
  executables: []
20
216
  extensions: []
21
217
  extra_rdoc_files: []
22
218
  files:
23
- - lib/git_http.rb
24
- homepage: https://github.com/akshayrawat/grack-gem
25
- licenses: []
219
+ - .travis.yml
220
+ - .yardopts
221
+ - LICENSE
222
+ - NEWS.md
223
+ - README.md
224
+ - Rakefile
225
+ - lib/git_adapter.rb
226
+ - lib/grack.rb
227
+ - lib/grack/app.rb
228
+ - lib/grack/compatible_git_adapter.rb
229
+ - lib/grack/file_streamer.rb
230
+ - lib/grack/git_adapter.rb
231
+ - lib/grack/io_streamer.rb
232
+ - tests/app_test.rb
233
+ - tests/compatible_git_adapter_test.rb
234
+ - tests/example/_git/COMMIT_EDITMSG
235
+ - tests/example/_git/HEAD
236
+ - tests/example/_git/config
237
+ - tests/example/_git/description
238
+ - tests/example/_git/hooks/applypatch-msg.sample
239
+ - tests/example/_git/hooks/commit-msg.sample
240
+ - tests/example/_git/hooks/post-commit.sample
241
+ - tests/example/_git/hooks/post-receive.sample
242
+ - tests/example/_git/hooks/post-update.sample
243
+ - tests/example/_git/hooks/pre-applypatch.sample
244
+ - tests/example/_git/hooks/pre-commit.sample
245
+ - tests/example/_git/hooks/pre-rebase.sample
246
+ - tests/example/_git/hooks/prepare-commit-msg.sample
247
+ - tests/example/_git/hooks/update.sample
248
+ - tests/example/_git/index
249
+ - tests/example/_git/info/exclude
250
+ - tests/example/_git/info/refs
251
+ - tests/example/_git/logs/HEAD
252
+ - tests/example/_git/logs/refs/heads/master
253
+ - tests/example/_git/objects/31/d73eb4914a8ddb6cb0e4adf250777161118f90
254
+ - tests/example/_git/objects/cb/067e06bdf6e34d4abebf6cf2de85d65a52c65e
255
+ - tests/example/_git/objects/ce/013625030ba8dba906f756967f9e9ca394464a
256
+ - tests/example/_git/objects/info/packs
257
+ - tests/example/_git/objects/pack/pack-62c9f443d8405cd6da92dcbb4f849cc01a339c06.idx
258
+ - tests/example/_git/objects/pack/pack-62c9f443d8405cd6da92dcbb4f849cc01a339c06.pack
259
+ - tests/example/_git/refs/heads/master
260
+ - tests/file_streamer_test.rb
261
+ - tests/git_adapter_test.rb
262
+ - tests/io_streamer_test.rb
263
+ - tests/test_helper.rb
264
+ homepage: https://github.com/grackorg/grack
265
+ licenses:
266
+ - MIT
267
+ metadata: {}
26
268
  post_install_message:
27
269
  rdoc_options: []
28
270
  require_paths:
29
271
  - lib
30
272
  required_ruby_version: !ruby/object:Gem::Requirement
31
- none: false
32
273
  requirements:
33
- - - ! '>='
274
+ - - '>='
34
275
  - !ruby/object:Gem::Version
35
276
  version: '0'
36
277
  required_rubygems_version: !ruby/object:Gem::Requirement
37
- none: false
38
278
  requirements:
39
- - - ! '>='
279
+ - - '>'
40
280
  - !ruby/object:Gem::Version
41
- version: '0'
281
+ version: 1.3.1
42
282
  requirements: []
43
283
  rubyforge_project:
44
- rubygems_version: 1.8.23
284
+ rubygems_version: 2.2.2
45
285
  signing_key:
46
- specification_version: 3
47
- summary: Grack
48
- test_files: []
286
+ specification_version: 4
287
+ summary: This project aims to replace the builtin git-http-backend CGI handler distributed
288
+ with C Git with a Rack application.
289
+ test_files:
290
+ - tests/app_test.rb
291
+ - tests/compatible_git_adapter_test.rb
292
+ - tests/example/_git/COMMIT_EDITMSG
293
+ - tests/example/_git/HEAD
294
+ - tests/example/_git/config
295
+ - tests/example/_git/description
296
+ - tests/example/_git/hooks/applypatch-msg.sample
297
+ - tests/example/_git/hooks/commit-msg.sample
298
+ - tests/example/_git/hooks/post-commit.sample
299
+ - tests/example/_git/hooks/post-receive.sample
300
+ - tests/example/_git/hooks/post-update.sample
301
+ - tests/example/_git/hooks/pre-applypatch.sample
302
+ - tests/example/_git/hooks/pre-commit.sample
303
+ - tests/example/_git/hooks/pre-rebase.sample
304
+ - tests/example/_git/hooks/prepare-commit-msg.sample
305
+ - tests/example/_git/hooks/update.sample
306
+ - tests/example/_git/index
307
+ - tests/example/_git/info/exclude
308
+ - tests/example/_git/info/refs
309
+ - tests/example/_git/logs/HEAD
310
+ - tests/example/_git/logs/refs/heads/master
311
+ - tests/example/_git/objects/31/d73eb4914a8ddb6cb0e4adf250777161118f90
312
+ - tests/example/_git/objects/cb/067e06bdf6e34d4abebf6cf2de85d65a52c65e
313
+ - tests/example/_git/objects/ce/013625030ba8dba906f756967f9e9ca394464a
314
+ - tests/example/_git/objects/info/packs
315
+ - tests/example/_git/objects/pack/pack-62c9f443d8405cd6da92dcbb4f849cc01a339c06.idx
316
+ - tests/example/_git/objects/pack/pack-62c9f443d8405cd6da92dcbb4f849cc01a339c06.pack
317
+ - tests/example/_git/refs/heads/master
318
+ - tests/file_streamer_test.rb
319
+ - tests/git_adapter_test.rb
320
+ - tests/io_streamer_test.rb
321
+ - tests/test_helper.rb