ruboty-github 0.1.3 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +3 -0
- data/README.md +3 -3
- data/lib/ruboty/github/actions/base.rb +10 -4
- data/lib/ruboty/github/version.rb +1 -1
- data/lib/ruboty/handlers/github.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6ec8b03de436019f0accdda3ec4dcfea4cfe458e
|
4
|
+
data.tar.gz: 418118d889005e3a1f1680d67e2d3bdc240d4201
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 280f46b8b332c5ad84c47487e7922019c65ae7756d1503599db7a53f277f5be6792d507385490e5e3f4929741210b27119a91a140667761d2cb2d087618ffcd4
|
7
|
+
data.tar.gz: 40ad2193ad9086bd71f4b032ece80f27cc91509d3ecea7652a6e0ac749eadfda81018af7a3cdfbb9ffa3b0e9534e837b8c21bd94db6f4de54534f298dfcdae4d
|
data/CHANGELOG.md
CHANGED
data/README.md
CHANGED
@@ -9,16 +9,16 @@ gem "ruboty-github"
|
|
9
9
|
|
10
10
|
## Usage
|
11
11
|
```
|
12
|
-
@ruboty close
|
12
|
+
@ruboty close <URL> - Close an Issue
|
13
13
|
@ruboty create issue "<title>" on <repo>[\n<description>] - Create a new Issue
|
14
|
-
@ruboty merge <
|
14
|
+
@ruboty merge <URL> - Merge a Pull Request
|
15
15
|
@ruboty pull request "<title>" from <from> to <to> - Create a new Pull Request
|
16
16
|
@ruboty remember my github token <token> - Remember sender's GitHub access token
|
17
17
|
```
|
18
18
|
|
19
19
|
## ENV
|
20
20
|
```
|
21
|
-
|
21
|
+
GITHUB_BASE_URL - Pass GitHub base URL if needed (e.g. https://github.example.com)
|
22
22
|
```
|
23
23
|
|
24
24
|
## Image
|
@@ -57,15 +57,21 @@ module Ruboty
|
|
57
57
|
end
|
58
58
|
|
59
59
|
def web_endpoint
|
60
|
-
"
|
60
|
+
"#{github_base_url}/" if github_base_url
|
61
61
|
end
|
62
62
|
|
63
63
|
def api_endpoint
|
64
|
-
"
|
64
|
+
"#{github_base_url}/api/v3" if github_base_url
|
65
65
|
end
|
66
66
|
|
67
|
-
|
68
|
-
|
67
|
+
# @note GITHUB_HOST will be deprecated on the next major version
|
68
|
+
def github_base_url
|
69
|
+
case
|
70
|
+
when ENV["GITHUB_BASE_URL"]
|
71
|
+
ENV["GITHUB_BASE_URL"]
|
72
|
+
when ENV["GITHUB_HOST"]
|
73
|
+
"https://#{ENV['GITHUB_HOST']}"
|
74
|
+
end
|
69
75
|
end
|
70
76
|
end
|
71
77
|
end
|
@@ -3,7 +3,7 @@ module Ruboty
|
|
3
3
|
class Github < Base
|
4
4
|
ISSUE_PATTERN = %r<(?:https?://[^/]+/)?(?<repo>.+)(?:#|/pull/|/issues/)(?<number>\d+) ?>
|
5
5
|
|
6
|
-
env :
|
6
|
+
env :GITHUB_BASE_URL, "Pass GitHub URL if needed (e.g. https://github.example.com)", optional: true
|
7
7
|
|
8
8
|
on(
|
9
9
|
/create issue "(?<title>.+)" on (?<repo>.+)(?:\n(?<description>[\s\S]+))?\z/,
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ruboty-github
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ryo Nakamura
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-06-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -168,7 +168,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
168
168
|
version: '0'
|
169
169
|
requirements: []
|
170
170
|
rubyforge_project:
|
171
|
-
rubygems_version: 2.
|
171
|
+
rubygems_version: 2.4.5
|
172
172
|
signing_key:
|
173
173
|
specification_version: 4
|
174
174
|
summary: Manage GitHub via Ruboty.
|