gitlab_git 5.8.0 → 5.9.0
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.
- checksums.yaml +4 -4
- data/VERSION +1 -1
- data/lib/gitlab_git/commit.rb +1 -12
- data/lib/gitlab_git/repository.rb +3 -4
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 8cea6e1be39cc847f7f0d81bc7e2fd0cd9177292
|
|
4
|
+
data.tar.gz: cda09b8fb88c8877b4cbf5bb61c282cd2dd2e65e
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 92cbf4698bac6eab130adc6b9c126ff61af6a3ba606db8d2abda20db664b8106b5d8e0223d4d15bcae61d0a3f72aca230be26b3431c04f98443052566b4ddfac
|
|
7
|
+
data.tar.gz: 3238fc9e6192919b7d558d24c347f804045106ec7a1c84a38488251c14b27e8ad2aa34c157d8c5dc7ddfa635427269fed1273595152fa46346cf13c01a96b78f
|
data/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
5.
|
|
1
|
+
5.9.0
|
data/lib/gitlab_git/commit.rb
CHANGED
|
@@ -40,18 +40,7 @@ module Gitlab
|
|
|
40
40
|
# Commit.find(repo, 'master')
|
|
41
41
|
#
|
|
42
42
|
def find(repo, commit_id = nil)
|
|
43
|
-
|
|
44
|
-
# because if commit_id is "tag name",
|
|
45
|
-
# repo.commit(commit_id) returns wrong commit sha
|
|
46
|
-
# that is git tag object sha.
|
|
47
|
-
tag = repo.tags.find {|tag| tag.name == commit_id} if commit_id
|
|
48
|
-
|
|
49
|
-
commit = if tag
|
|
50
|
-
repo.log(ref: tag.target).first
|
|
51
|
-
else
|
|
52
|
-
repo.log(ref: commit_id).first
|
|
53
|
-
end
|
|
54
|
-
|
|
43
|
+
commit = repo.log(ref: commit_id, limit: 1).first
|
|
55
44
|
decorate(commit) if commit
|
|
56
45
|
end
|
|
57
46
|
|
|
@@ -56,16 +56,15 @@ module Gitlab
|
|
|
56
56
|
|
|
57
57
|
# Returns an Array of Branches
|
|
58
58
|
def branches
|
|
59
|
-
rugged.
|
|
60
|
-
ref.name =~ /\Arefs\/heads/
|
|
61
|
-
end.map do |rugged_ref|
|
|
59
|
+
rugged.branches.map do |rugged_ref|
|
|
62
60
|
Branch.new(rugged_ref.name, rugged_ref.target)
|
|
63
61
|
end.sort_by(&:name)
|
|
64
62
|
end
|
|
65
63
|
|
|
66
64
|
# Returns an Array of tag names
|
|
67
65
|
def tag_names
|
|
68
|
-
tags
|
|
66
|
+
# rugged.tags returns array of names
|
|
67
|
+
rugged.tags.to_a
|
|
69
68
|
end
|
|
70
69
|
|
|
71
70
|
# Returns an Array of Tags
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: gitlab_git
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 5.
|
|
4
|
+
version: 5.9.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Dmitriy Zaporozhets
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2014-
|
|
11
|
+
date: 2014-06-11 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: gitlab-linguist
|