Documentation
¶
Overview ¶
Example ¶
package main
import (
"fmt"
"log"
"net/http"
"github.com/k1LoW/curlreq"
)
func main() {
cmd := "curl https://example.com"
req, err := curlreq.NewRequest(cmd)
if err != nil {
log.Fatal(err)
}
client := http.DefaultClient
resp, err := client.Do(req)
if err != nil {
log.Fatal(err)
}
defer resp.Body.Close()
fmt.Println(resp.StatusCode)
}
Output: 200
Index ¶
Examples ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Option ¶ added in v0.4.0
type Option func(*config) error
func WithWorkingDirectory ¶ added in v0.4.0
type Parsed ¶
func (*Parsed) MarshalJSON ¶ added in v0.2.0
Click to show internal directories.
Click to hide internal directories.