diff options
author | siddharth <s@ricketyspace.net> | 2022-04-23 23:31:55 -0400 |
---|---|---|
committer | siddharth <s@ricketyspace.net> | 2022-04-23 23:32:08 -0400 |
commit | 136950d51fe3333895ef8961f49f6ceb75dd3b68 (patch) | |
tree | f3ee0066e04fac086f97b721a745524c5063a473 | |
parent | 4dc123de789333a91721e6012959829538ba88ba (diff) |
http/client: add http.go
-rw-r--r-- | http/client/http.go | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/http/client/http.go b/http/client/http.go new file mode 100644 index 0000000..85bd04b --- /dev/null +++ b/http/client/http.go @@ -0,0 +1,20 @@ +// Copyright © 2022 siddharth <s@ricketyspace.net> +// SPDX-License-Identifier: ISC + +// Thin HTTP client wrapper. +package client + +import "net/http" + +// HTTP client. +var client = http.Client{} + +// Make a HTTP GET request. +func Get(url string) (resp *http.Response, err error) { + return nil, nil +} + +// Add default headers for the peach http client. +func (req *http.Request) buildHeaders() { + req.Header.Set("User-Agent", "peach/"+peach.Version+" ricketyspace.net/contact") +} |