12306邮件导入日历
Accepts
Rich Text and Text
COMMENT
使用方法:
在邮件正文中,长按,点击全选,并点击“共享”,选择“捷径”-“12306邮件导入日历”即可。
通过其他第三方邮件app把邮件直接分享亦可(如Spark)。
COMMENT
v1.0-26Sep2018
Features:
直接从邮件导入所有信息,包括车次、座位、始发终点站、出发到站时间,并联网抓取时刻表于日历项的备注中。(在日历项中点击“显示所有备注”以查看完整列车时刻表)
COMMENT
联系方式:
socoolike@gmail.com
Kirk Li
DOCUMENTS
Get text from
Input

Text
VARIABLES
Set variable
str
to
Input
TEXT
Match
((?!0000)[0-9]{4})(?=年((?!00)[0-9]{2})月((?!00)[0-9]{2})日((?!00)[0-9]{2}):)
in
Text

Matches
VARIABLES
Set variable
year
to
Input
VARIABLES
Get
str
TEXT
Match
((?!00)[0-9]{2})(?=月((?!00)[0-9]{2})日((?!00)[0-9]{2}):)
in
Text

Matches
VARIABLES
Set variable
month
to
Input
VARIABLES
Get
str
TEXT
Match
((?!00)[0-9]{2})(?=日((?!00)[0-9]{2}):([0-9]{2})开)
in
Text

Matches
VARIABLES
Set variable
day
to
Input
VARIABLES
Get
str
TEXT
Match
((?!00)[0-9]{2}):([0-9]{2})(?=开)
in
Text

Matches
VARIABLES
Set variable
time
to
Input
VARIABLES
Get
str
TEXT
Match
(?<=开,).*?([号座])
in
Text

Matches
VARIABLES
Set variable
title
to
Input
VARIABLES
Get
title
TEXT
Match
(.*)?(?=,)
in
Text

Matches
VARIABLES
Set variable
location
to
Input
VARIABLES
Get
title
TEXT
Match
([DGKZ])([0-9]*)(?=次列车)
in
Text

Matches
VARIABLES
Set variable
train
to
Input
VARIABLES
Get
title
TEXT
Match
(?<=[,]).*
in
Text

Matches
VARIABLES
Set variable
seat
to
Input
VARIABLES
Get
title
TEXT
Match
(?<=\-).*?(?=,)
in
Text

Matches
VARIABLES
Set variable
destination
to
Input
TEXT
http://touch.qunar.com/h5/train/trainStaChoose?trainNum=
train

Text
SAFARI
Get contents of web page at
URL

Contents of Web Page
TEXT
Match
(?<=发车时间\n\n)[\s\S]*(终到站)
in
Text

Matches
VARIABLES
Set variable
timetable
to
Input
TEXT
Match
(?<=
destination
\n)([0-9]{2}):([0-9]{2})
in
Text

Matches
VARIABLES
Set variable
ETA
to
Input
CALENDAR

New Event
CALENDAR
Show
Event
in Calendar
Showcuts