integrity-notifyio 0.2.1 → 0.2.3
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.
- data/Changelog +6 -0
- data/README.markdown +10 -10
- data/README.rdoc +12 -0
- data/Rakefile +1 -0
- data/VERSION +1 -1
- data/integrity-notifyio.gemspec +3 -4
- data/lib/integrity/notifier/notifyio.rb +18 -13
- metadata +5 -6
data/Changelog
ADDED
data/README.markdown
CHANGED
@@ -4,22 +4,22 @@ Integrity
|
|
4
4
|
[Integrity][] is your friendly automated Continuous Integration server.
|
5
5
|
|
6
6
|
Integrity Notify.io Notifier
|
7
|
-
|
7
|
+
============================
|
8
8
|
|
9
9
|
This lets Integrity post notifications to Notify.io after each build is made.
|
10
10
|
|
11
11
|
Setup Instructions
|
12
12
|
==================
|
13
13
|
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
should be
|
14
|
+
To use integrity-notifyio you need to do the following:
|
15
|
+
In the *Gemfile* add:
|
16
|
+
gem "integrity-notifyio", '>=0.2.2'
|
17
|
+
|
18
|
+
In *init.rb* add:
|
19
|
+
# = Notify.io
|
20
|
+
require "integrity/notifier/notifyio"
|
21
|
+
|
22
|
+
Reload Integrity and you should be able to add/edit your projects and see the new Notify.IO panel
|
23
23
|
|
24
24
|
License
|
25
25
|
=======
|
data/README.rdoc
CHANGED
@@ -2,6 +2,18 @@
|
|
2
2
|
|
3
3
|
A Notify.io based notifier for the Integrity continuous integration server.
|
4
4
|
|
5
|
+
== Installation
|
6
|
+
|
7
|
+
To use integrity-notifyio you need to do the following:
|
8
|
+
In the *Gemfile* add:
|
9
|
+
gem "integrity-notifyio", '>=0.2.2'
|
10
|
+
|
11
|
+
In *init.rb* add:
|
12
|
+
# = Notify.io
|
13
|
+
require "integrity/notifier/notifyio"
|
14
|
+
|
15
|
+
Reload Integrity and you should be able to add/edit your projects and see the new Notify.IO panel
|
16
|
+
|
5
17
|
== Copyright
|
6
18
|
|
7
19
|
Copyright (c) 2010 Andrew Kalek. See LICENSE for details.
|
data/Rakefile
CHANGED
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.3
|
data/integrity-notifyio.gemspec
CHANGED
@@ -5,7 +5,7 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{integrity-notifyio}
|
8
|
-
s.version = "0.2.
|
8
|
+
s.version = "0.2.3"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Andrew Kalek"]
|
@@ -13,12 +13,11 @@ Gem::Specification.new do |s|
|
|
13
13
|
s.description = %q{Let Integrity post notifications to your Notifiy.io account after each build}
|
14
14
|
s.email = %q{andrew.kalek@anlek.com}
|
15
15
|
s.extra_rdoc_files = [
|
16
|
-
"
|
17
|
-
"README.markdown",
|
18
|
-
"README.rdoc"
|
16
|
+
"Changelog"
|
19
17
|
]
|
20
18
|
s.files = [
|
21
19
|
".gitignore",
|
20
|
+
"Changelog",
|
22
21
|
"LICENSE",
|
23
22
|
"README.markdown",
|
24
23
|
"README.rdoc",
|
@@ -11,7 +11,7 @@ module Integrity
|
|
11
11
|
end
|
12
12
|
|
13
13
|
def deliver!
|
14
|
-
post(config['email'], config['api_key'], short_message, full_message) if announce_build?
|
14
|
+
post(config['email'], config['api_key'], short_message, full_message, :link => build_url) if announce_build?
|
15
15
|
end
|
16
16
|
|
17
17
|
def to_s
|
@@ -22,20 +22,24 @@ module Integrity
|
|
22
22
|
private
|
23
23
|
#######
|
24
24
|
|
25
|
+
def short_message
|
26
|
+
"#{build.project.name} :: #{build.human_status}"
|
27
|
+
end
|
28
|
+
|
25
29
|
def full_message
|
26
|
-
|
27
|
-
== #{
|
28
|
-
|
29
|
-
Commit
|
30
|
-
Commit Date: #{build.commit.committed_at}
|
31
|
-
Commit
|
32
|
-
|
33
|
-
Link: #{build_url}
|
34
|
-
|
35
|
-
|
30
|
+
msg = []
|
31
|
+
msg << "== #{build.failed? ? "Failed" : "Passed!"} =="
|
32
|
+
msg << ''
|
33
|
+
msg << "Commit Author: #{build.commit.author.name}"
|
34
|
+
msg << "Commit Date: #{build.commit.committed_at}"
|
35
|
+
msg << "Commit Message: #{build.commit.message}"
|
36
|
+
msg << ''
|
37
|
+
msg << "Link: #{build_url}"
|
38
|
+
|
39
|
+
msg.join("\n")
|
36
40
|
end
|
37
41
|
|
38
|
-
def post(emails, api_key, title, body)
|
42
|
+
def post(emails, api_key, title, body, options={})
|
39
43
|
return if emails.nil? || emails.empty? || api_key.nil? || api_key.empty?
|
40
44
|
emails.split(',').each do |email|
|
41
45
|
email_hash = MD5.hexdigest(email.strip)
|
@@ -44,7 +48,8 @@ EOM
|
|
44
48
|
:query => {
|
45
49
|
:api_key => api_key,
|
46
50
|
:title => title,
|
47
|
-
:text => body
|
51
|
+
:text => body,
|
52
|
+
:link => options[:link]
|
48
53
|
}
|
49
54
|
|
50
55
|
end
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: integrity-notifyio
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 17
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 2
|
9
|
-
-
|
10
|
-
version: 0.2.
|
9
|
+
- 3
|
10
|
+
version: 0.2.3
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Andrew Kalek
|
@@ -53,11 +53,10 @@ executables: []
|
|
53
53
|
extensions: []
|
54
54
|
|
55
55
|
extra_rdoc_files:
|
56
|
-
-
|
57
|
-
- README.markdown
|
58
|
-
- README.rdoc
|
56
|
+
- Changelog
|
59
57
|
files:
|
60
58
|
- .gitignore
|
59
|
+
- Changelog
|
61
60
|
- LICENSE
|
62
61
|
- README.markdown
|
63
62
|
- README.rdoc
|