mwarkentin / yuri

CLI tool to parse URIs into their components
MIT License
4 stars 3 forks source link

Custom map #13

Closed mwarkentin closed 7 years ago

mwarkentin commented 7 years ago

Fixes #11.

Replaces direct marshalling of Golang URL object with a custom map.

Example output

$ go run src/yuri.go https://username:password@stage.example.com:443/path?query1=1\&query2=2 | jq
{
  "host": "stage.example.com:443",
  "opaque": "",
  "password": "password",
  "path": "/path",
  "rawpath": "",
  "rawquery": "query1=1&query2=2",
  "scheme": "https",
  "username": "username"
}