Version 1.4
This commit is contained in:
parent
e57284511e
commit
912785a7e3
13
main.go
13
main.go
@ -19,7 +19,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
VERSION = "1.3"
|
VERSION = "v1.4"
|
||||||
|
|
||||||
HELP = `
|
HELP = `
|
||||||
*list* or *li*
|
*list* or *li*
|
||||||
@ -220,14 +220,15 @@ func init() {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
re := regexp.MustCompile(`"Incomplete" to "Complete"`)
|
|
||||||
|
|
||||||
// [2017-02-22 21:00:00.898] File-Name State changed from "Incomplete" to "Complete" (torrent.c:2218)
|
// [2017-02-22 21:00:00.898] File-Name State changed from "Incomplete" to "Complete" (torrent.c:2218)
|
||||||
const start = len(`[2017-02-22 21:00:00.898] `)
|
const (
|
||||||
const end = len(` State changed from "Incomplete" to "Complete" (torrent.c:2218)`)
|
substring = `"Incomplete" to "Complete"`
|
||||||
|
start = len(`[2017-02-22 21:00:00.898] `)
|
||||||
|
end = len(` State changed from "Incomplete" to "Complete" (torrent.c:2218)`)
|
||||||
|
)
|
||||||
|
|
||||||
for line := range ft.Lines {
|
for line := range ft.Lines {
|
||||||
if re.MatchString(line.Text) {
|
if strings.Contains(line.Text, substring) {
|
||||||
// if we don't have a chatID continue
|
// if we don't have a chatID continue
|
||||||
if chatID == 0 {
|
if chatID == 0 {
|
||||||
continue
|
continue
|
||||||
|
Loading…
Reference in New Issue
Block a user