mirror of
https://github.com/adnanh/webhook.git
synced 2025-05-23 05:42:30 +00:00
fix
This commit is contained in:
parent
f1c4415fc8
commit
ea7fd4cb87
3 changed files with 9 additions and 1 deletions
|
@ -2,6 +2,9 @@
|
||||||
{
|
{
|
||||||
"id": "webhook",
|
"id": "webhook",
|
||||||
"command": "/home/adnan/redeploy-go-webhook.sh",
|
"command": "/home/adnan/redeploy-go-webhook.sh",
|
||||||
|
"args": [
|
||||||
|
"head"
|
||||||
|
],
|
||||||
"cwd": "/home/adnan/go",
|
"cwd": "/home/adnan/go",
|
||||||
"trigger-rule":
|
"trigger-rule":
|
||||||
{
|
{
|
||||||
|
|
|
@ -2,6 +2,7 @@ package hooks
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"encoding/json"
|
"encoding/json"
|
||||||
|
"fmt"
|
||||||
"io/ioutil"
|
"io/ioutil"
|
||||||
"net/url"
|
"net/url"
|
||||||
|
|
||||||
|
@ -41,6 +42,8 @@ func (h *Hook) ParseFormArgs(form url.Values) []string {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fmt.Printf("parse form args %+v\n", args)
|
||||||
|
|
||||||
return args
|
return args
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -58,6 +61,8 @@ func (h *Hook) ParseJSONArgs(payload interface{}) []string {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fmt.Printf("parse json args %+v\n", args)
|
||||||
|
|
||||||
return args
|
return args
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -20,7 +20,7 @@ import (
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
version string = "1.0.2"
|
version string = "1.0.3"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue