gitea-client 0.7.0 → 0.7.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ca16b2d2421abb2131045e85d96ae8ef9da5f06e94e817f8aa1bf80122ba15c2
4
- data.tar.gz: 3b3db595d5fa6d5c6430e2e9fa9e78f89c870ef7c862e76ecfd143adfb8fd07d
3
+ metadata.gz: cc354d6ebcd5ec3bf4fd76fd7647cdaea7f1d024a0bd578c5058a982244f815d
4
+ data.tar.gz: 38bc505b08560028ea865c2f039cf2cb3cbc6a2a4757f397a378e8013118e240
5
5
  SHA512:
6
- metadata.gz: a8132c9f6a7cc1baec42ce4e924883aea793a21948e6a02c351625c1b542a1839a26b2c0067850fbda241bdba02e65b5bf14afb67bdcc6f2954168a98a572bfd
7
- data.tar.gz: 884c00d5b01de20ce995f6fb3b3c645649bba524a76dd6eaeb0abdf4f1febae3b8665ee2d3629900edfa4e46d07843633d81c0988c0bcc6035c3aab874a88de4
6
+ metadata.gz: 636116430f19f3771b0c4f91b54466f62bf54f6c375f51d346a07166d8092c19f5814a43316806fabb39e15579ba20ffe6ce73f3b043b7e422ec0e5768a8f2ff
7
+ data.tar.gz: b6f7b35bc709f73776da18d4b3adee78ed956eb65e11ed8d3401cd796e6d82de828daf9995a0dc4ebec811fd6164c5791a8102f3854d4be0e2191748bcd6a621
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- gitea-client (0.7.0)
4
+ gitea-client (0.7.1)
5
5
  rest-client (~> 2.1.0)
6
6
 
7
7
  GEM
@@ -0,0 +1,17 @@
1
+ module Gitea
2
+ module Api
3
+ module Activity
4
+ def get_activity(opt={})
5
+ @http.get("/activity", opt)
6
+ end
7
+
8
+ def get_activity_develop(opt={})
9
+ @http.get("/activity/develop", opt)
10
+ end
11
+
12
+ def get_activity_project(opt={})
13
+ @http.get("/activity/project", opt)
14
+ end
15
+ end # Activity
16
+ end # Api
17
+ end # Gitea
@@ -44,6 +44,7 @@ module Gitea
44
44
  include Gitea::Api::Notification
45
45
  include Gitea::Api::Miscellaneous
46
46
  include Gitea::Api::Admin
47
+ include Gitea::Api::Activity
47
48
  end
48
49
  end # User
49
50
  end # Gitea
@@ -29,6 +29,10 @@ module Gitea
29
29
  @http.get("/repos/#{owner}/#{repo}/assignees", opt)
30
30
  end
31
31
 
32
+ def get_repos_branch_name_set_by_owner_repo(owner, repo, opt = {})
33
+ @http.get("/repos/#{owner}/#{repo}/branch_name_set", opt)
34
+ end
35
+
32
36
  def get_repos_branch_protections_by_owner_repo(owner, repo, opt = {})
33
37
  @http.get("/repos/#{owner}/#{repo}/branch_protections", opt)
34
38
  end
@@ -49,6 +53,10 @@ module Gitea
49
53
  @http.patch("/repos/#{owner}/#{repo}/branch_protections/#{name}", opt)
50
54
  end
51
55
 
56
+ def get_repos_branch_tag_count_by_owner_repo(owner, repo, opt={})
57
+ @http.get("/repos/#{owner}/#{repo}/branch_tag_count", opt)
58
+ end
59
+
52
60
  def get_repos_branches_by_owner_repo(owner, repo, opt = {})
53
61
  @http.get("/repos/#{owner}/#{repo}/branches", opt)
54
62
  end
@@ -57,6 +65,10 @@ module Gitea
57
65
  @http.get("/repos/#{owner}/#{repo}/branches", opt)
58
66
  end
59
67
 
68
+ def get_repos_branches_branches_slice_by_owner_repo(owner, repo, opt = {})
69
+ @http.get("/repos/#{owner}/#{repo}/branches/branches_slice", opt)
70
+ end
71
+
60
72
  def get_repos_branches_by_owner_repo_branch(owner, repo, branch, opt = {})
61
73
  @http.get("/repos/#{owner}/#{repo}/branches/#{branch}", opt)
62
74
  end
@@ -89,6 +101,10 @@ module Gitea
89
101
  @http.get("/repos/#{owner}/#{repo}/commits/#{ref}/statuses", opt)
90
102
  end
91
103
 
104
+ def get_repos_commits_slice_by_owner_repo(owner, repo, opt = {})
105
+ @http.get("/repos/#{owner}/#{repo}/commits_slice", opt)
106
+ end
107
+
92
108
  def get_repos_contents_by_owner_repo(owner, repo, opt = {})
93
109
  @http.get("/repos/#{owner}/#{repo}/contents", opt)
94
110
  end
@@ -109,10 +125,26 @@ module Gitea
109
125
  @http.delete("/repos/#{owner}/#{repo}/contents/#{filepath}", opt)
110
126
  end
111
127
 
128
+ def get_repos_contributors_by_owner_repo(owner, repo, opt={})
129
+ @http.get("/repos/#{owner}/#{repo}/contributors", opt)
130
+ end
131
+
132
+ def get_repos_count_by_owner_repo(owner, repo, opt={})
133
+ @http.get("/repos/#{owner}/#{repo}/count", opt)
134
+ end
135
+
112
136
  def get_repos_editorconfig_by_owner_repo_filepath(owner, repo, filepath, opt = {})
113
137
  @http.get("/repos/#{owner}/#{repo}/editorconfig/#{filepath}", opt)
114
138
  end
115
139
 
140
+ def get_repos_file_commits_by_owner_repo_filepath(owner, repo, filepath, opt={})
141
+ @http.get("/repos/#{owner}/#{repo}/file_commits/#{filepath}", opt)
142
+ end
143
+
144
+ def get_repos_find_by_owner_repo_filepath(owner, repo, filepath, opt={})
145
+ @http.get("/repos/#{owner}/#{repo}/find", opt)
146
+ end
147
+
116
148
  def get_repos_forks_by_owner_repo(owner, repo, opt = {})
117
149
  @http.get("/repos/#{owner}/#{repo}/forks", opt)
118
150
  end
@@ -181,6 +213,10 @@ module Gitea
181
213
  @http.patch("/repos/#{owner}/#{repo}/hooks/#{id}", opt)
182
214
  end
183
215
 
216
+ def get_repos_hooks_hooktasks_by_owner_repo_id(owner, repo, id, opt={})
217
+ @http.get("/repos/#{owner}/#{repo}/hooks/#{id}/hooktasks", opt)
218
+ end
219
+
184
220
  def post_repos_hooks_tests_by_owner_repo_id(owner, repo, id, opt = {})
185
221
  @http.post("/repos/#{owner}/#{repo}/hooks/#{id}/tests", opt)
186
222
  end
@@ -221,6 +257,10 @@ module Gitea
221
257
  @http.post("/repos/#{owner}/#{repo}/pulls", opt)
222
258
  end
223
259
 
260
+ def get_repos_pulls_by_owner_repo_index(owner, repo, opt = {})
261
+ @http.get("/repos/#{owner}/#{repo}/pulls/#{index}", opt)
262
+ end
263
+
224
264
  def patch_repos_pulls_by_owner_repo_index(owner, repo, index, opt = {})
225
265
  @http.patch("/repos/#{owner}/#{repo}/pulls/#{index}", opt)
226
266
  end
@@ -285,6 +325,14 @@ module Gitea
285
325
  @http.get("/repos/#{owner}/#{repo}/raw/#{filepath}", opt)
286
326
  end
287
327
 
328
+ def get_repos_readme_by_owner_repo(owner, repo, opt={})
329
+ @http.get("/repos/#{owner}/#{repo}/readme", opt)
330
+ end
331
+
332
+ def get_repos_readme_by_owner_repo_dir(owner, repo, dir, opt={})
333
+ @http.get("/repos/#{owner}/#{repo}/readme/#{dir}", opt)
334
+ end
335
+
288
336
  def get_repos_releases_by_owner_repo(owner, repo, opt = {})
289
337
  @http.get("/repos/#{owner}/#{repo}/releases", opt)
290
338
  end
@@ -166,6 +166,10 @@ module Gitea
166
166
  @http.get("/user/#{username}/gpg_keys", opt)
167
167
  end
168
168
 
169
+ def get_users_heatmap_by_username(username, opt={})
170
+ @http.get("/users/#{username}/heatmap", opt)
171
+ end
172
+
169
173
  def get_users_keys_by_username(username, opt={})
170
174
  @http.get("/user/#{username}/keys", opt)
171
175
  end
data/lib/gitea/api.rb CHANGED
@@ -7,6 +7,7 @@ require_relative 'api/organization'
7
7
  require_relative 'api/notification'
8
8
  require_relative 'api/miscellaneous'
9
9
  require_relative 'api/admin'
10
+ require_relative 'api/activity'
10
11
  require_relative 'api/client'
11
12
  require_relative 'api/config'
12
13
  require_relative 'api/exception'
data/lib/gitea/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Gitea
4
- VERSION = "0.7.0"
4
+ VERSION = "0.7.1"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gitea-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.0
4
+ version: 0.7.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - viletyy
@@ -44,6 +44,7 @@ files:
44
44
  - gitea-client.gemspec
45
45
  - lib/gitea-client.rb
46
46
  - lib/gitea/api.rb
47
+ - lib/gitea/api/activity.rb
47
48
  - lib/gitea/api/admin.rb
48
49
  - lib/gitea/api/client.rb
49
50
  - lib/gitea/api/config.rb