Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
H
HappyKit
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
mobile
HappyKit
Commits
e06cc23e
Commit
e06cc23e
authored
Jun 21, 2019
by
gm
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修正收件人;使用jaguar作为发件人
parent
68bd4c05
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
7 deletions
+11
-7
.gitignore
.gitignore
+1
-0
notify_release_date_by_email.rb
notify_release_date_by_email.rb
+10
-7
No files found.
.gitignore
View file @
e06cc23e
*.log
.DS_Store
notify_release_date_by_email.rb
View file @
e06cc23e
...
...
@@ -43,7 +43,7 @@ def login
end
def
today
# return Date.parse("2019-06-
1
0")
# return Date.parse("2019-06-
2
0")
return
Date
.
today
end
...
...
@@ -91,6 +91,7 @@ def should_send_email_today
response
=
get_dev_events_response
obj
=
JSON
.
parse
(
response
.
body
,
object_class:
OpenStruct
)
for
event
in
obj
.
events
puts
"
#{
event
.
title
}
#{
event
.
start
}
"
start
=
Date
.
parse
(
event
.
start
)
if
start
==
today
return
true
...
...
@@ -106,8 +107,8 @@ def send_email(deliver_info)
delivery_method
:smtp
,
{
:port
=>
465
,
:address
=>
"smtp.exmail.qq.com"
,
:user_name
=>
"
wangyang
@igengmei.com"
,
:password
=>
"
UkZqL94RvD48htFM
"
,
:user_name
=>
"
jaguar
@igengmei.com"
,
:password
=>
"
Jaguar@131415
"
,
:enable_starttls_auto
=>
false
,
:openssl_verify_mode
=>
'none'
,
:authentication
=>
:plain
,
...
...
@@ -117,10 +118,10 @@ def send_email(deliver_info)
mail
=
Mail
.
deliver
do
# 其实下面都是方法调用,不要被迷惑了
to
[
'hualu@igengmei.com'
,
'wangjun@igengmei.com'
,
'
lizhen@igengmei.com'
,
'sunwenhui@igengmei.com'
,
'tanchenshuai@igengmei.com'
,
'zhucuicui@igengmei.com'
,
'huchunhe@igengmei.com'
,
'dongqiang@igengmei.com'
,
'SJ-liuxiao@igengmei.com'
,
'wangyang@igengmei.com'
,
'cliedn
-rd@igengmei.com'
]
#to ['
dujuan
@igengmei.com']
from
'
wangyang
@igengmei.com'
subject
"
test 请忽略!
更美app
#{
deliver_info
.
title
}
商店物料信息"
to
[
'hualu@igengmei.com'
,
'wangjun@igengmei.com'
,
'
sunwenhui@igengmei.com'
,
'tanchenshuai@igengmei.com'
,
'zhucuicui@igengmei.com'
,
'huchunhe@igengmei.com'
,
'dongqiang@igengmei.com'
,
'SJ-liuxiao@igengmei.com'
,
'client
-rd@igengmei.com'
]
#to ['
jaguar
@igengmei.com']
from
'
jaguar
@igengmei.com'
subject
"更美app
#{
deliver_info
.
title
}
商店物料信息"
body
"Hi,All,
#{
deliver_info
.
title
}
时间为
#{
deliver_info
.
date
.
to_s
}
,请准备商店相关的物料信息(是否更换APP icon和商店海报),谢谢~"
end
...
...
@@ -144,4 +145,6 @@ if should_send_email_today
)
DingBot
.
send_msg
(
message
)
end
else
puts
"今天不是发邮件日期"
end
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment