Discover Packages
github.com/leesoh/hacks
uniqurl
command
Version:
v0.0.0-...-f9b4428
Opens a new window with list of versions in this module.
Published: Feb 17, 2022
License: GPL-3.0
Opens a new window with license information.
Imports: 4
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
README
README
¶
uniqurl
Uniqurl takes a list of URLs on stdin and deduplicates the domains, returning only the HTTPS URL for a given domain pair. If no HTTPS URL exists, the HTTP URL is returned.
Usage
$ cat urls.txt
https://www.google.com
http://www.google.com
https://www.facebook.com
http://www.facebook.com
https://www.yahoo.com
http://www.uber.com
$ cat urls.txt | uniqurl
https://www.google.com
https://www.facebook.com
https://www.yahoo.com
http://www.uber.com
Installation
$ go get -u github.com/leesoh/hacks/uniqurl
Thanks
@dee-see for the idea.
Expand ▾
Collapse ▴
Documentation
¶
There is no documentation for this package.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.