From 136950d51fe3333895ef8961f49f6ceb75dd3b68 Mon Sep 17 00:00:00 2001 From: siddharth Date: Sat, 23 Apr 2022 23:31:55 -0400 Subject: http/client: add http.go --- http/client/http.go | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 http/client/http.go 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 +// 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") +} -- cgit v1.2.3