From 988f3fd19ad03bdd09e65092725ebdf45ab084f3 Mon Sep 17 00:00:00 2001
From: Martin Polden
Date: Mon, 27 Aug 2018 20:33:29 +0200
Subject: [PATCH] Rename ipd -> echoip
---
README.md | 10 +++++-----
cmd/{ipd => echoip}/main.go | 8 ++++----
heroku.yml | 2 +-
http/http.go | 6 +++---
http/http_test.go | 2 +-
index.html | 4 ++--
vendor/vendor.json | 2 +-
7 files changed, 17 insertions(+), 17 deletions(-)
rename cmd/{ipd => echoip}/main.go (91%)
diff --git a/README.md b/README.md
index e3c0fd4..aa54496 100644
--- a/README.md
+++ b/README.md
@@ -1,6 +1,6 @@
-# ipd
+# echoip
-[![Build Status](https://travis-ci.org/mpolden/ipd.svg)](https://travis-ci.org/mpolden/ipd)
+[![Build Status](https://travis-ci.org/mpolden/echoip.svg)](https://travis-ci.org/mpolden/echoip)
A simple service for looking up your IP address. This is the code that powers
https://ifconfig.co.
@@ -89,7 +89,7 @@ between IPv4 and IPv6 lookup.
Compiling requires the [Golang compiler](https://golang.org/) to be installed.
This package can be installed with `go get`:
-`go get github.com/mpolden/ipd/...`
+`go get github.com/mpolden/echoip/...`
For more information on building a Go project, see the [official Go
documentation](https://golang.org/doc/code.html).
@@ -97,9 +97,9 @@ documentation](https://golang.org/doc/code.html).
### Usage
```
-$ ipd -h
+$ echoip -h
Usage:
- ipd [OPTIONS]
+ echoip [OPTIONS]
Application Options:
-f, --country-db=FILE Path to GeoIP country database
diff --git a/cmd/ipd/main.go b/cmd/echoip/main.go
similarity index 91%
rename from cmd/ipd/main.go
rename to cmd/echoip/main.go
index 4d659bf..fb42b68 100644
--- a/cmd/ipd/main.go
+++ b/cmd/echoip/main.go
@@ -7,9 +7,9 @@ import (
"os"
- "github.com/mpolden/ipd/http"
- "github.com/mpolden/ipd/iputil"
- "github.com/mpolden/ipd/iputil/geo"
+ "github.com/mpolden/echoip/http"
+ "github.com/mpolden/echoip/iputil"
+ "github.com/mpolden/echoip/iputil/geo"
)
func main() {
@@ -27,7 +27,7 @@ func main() {
os.Exit(1)
}
- log := log.New(os.Stderr, "ipd: ", 0)
+ log := log.New(os.Stderr, "echoip: ", 0)
r, err := geo.Open(opts.CountryDBPath, opts.CityDBPath)
if err != nil {
log.Fatal(err)
diff --git a/heroku.yml b/heroku.yml
index b0490a2..0d550a5 100644
--- a/heroku.yml
+++ b/heroku.yml
@@ -4,4 +4,4 @@ build:
pre:
- make geoip-download
run:
- web: ipd -f data/country.mmdb -c data/city.mmdb -p -r -H CF-Connecting-IP -H X-Forwarded-For -l :$PORT
+ web: echoip -f data/country.mmdb -c data/city.mmdb -p -r -H CF-Connecting-IP -H X-Forwarded-For -l :$PORT
diff --git a/http/http.go b/http/http.go
index 5cc3082..fbf4acb 100644
--- a/http/http.go
+++ b/http/http.go
@@ -7,9 +7,9 @@ import (
"path/filepath"
"strings"
- "github.com/mpolden/ipd/iputil"
- "github.com/mpolden/ipd/iputil/geo"
- "github.com/mpolden/ipd/useragent"
+ "github.com/mpolden/echoip/iputil"
+ "github.com/mpolden/echoip/iputil/geo"
+ "github.com/mpolden/echoip/useragent"
"math/big"
"net"
diff --git a/http/http_test.go b/http/http_test.go
index 0849019..9bf8179 100644
--- a/http/http_test.go
+++ b/http/http_test.go
@@ -8,7 +8,7 @@ import (
"net/http/httptest"
"testing"
- "github.com/mpolden/ipd/iputil/geo"
+ "github.com/mpolden/echoip/iputil/geo"
)
func lookupAddr(net.IP) (string, error) { return "localhost", nil }
diff --git a/index.html b/index.html
index b2081f4..385f5a4 100644
--- a/index.html
+++ b/index.html
@@ -117,9 +117,9 @@ $ http {{ .Host }}/port/8080
Can I run my own service?
- Yes, the source code and documentation is available on GitHub.
+ Yes, the source code and documentation is available on GitHub.
-
+