Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tedivm/urlparser
Extract information from URLs inside shell scripts
https://github.com/tedivm/urlparser
bash shell shell-scripting url-parser
Last synced: 5 days ago
JSON representation
Extract information from URLs inside shell scripts
- Host: GitHub
- URL: https://github.com/tedivm/urlparser
- Owner: tedivm
- License: mit
- Created: 2018-10-11T16:47:13.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2018-10-13T02:43:00.000Z (about 6 years ago)
- Last Synced: 2024-05-01T21:37:45.454Z (7 months ago)
- Topics: bash, shell, shell-scripting, url-parser
- Language: Python
- Homepage: https://pypi.org/project/urlparser/
- Size: 5.86 KB
- Stars: 4
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# urlparser
This is a simple command line tool for extracting pieces (such as the scheme, port, or hostname) of a standard URL.
## Install
This project is available on the [pypi repository](https://pypi.org/project/urlparser/).
`pip3 install urlparser`
## Usage
```bash
$ urlparser hostname http://google.com
google.com
$ urlparser hostname google.com
google.com
$ urlparser port http://google.com
80
$ urlparser port https://google.com
443
$ urlparser port https://example.com:9443
9443
$ urlparser scheme https://google.com
https
```## Help
```
Usage: urlparser [OPTIONS] COMMAND [ARGS]...Options:
--help Show this message and exit.Commands:
fragment Get fragment from URL
hostname Get hostname from URL
netloc Get netloc from URL
params Get params from URL
password Get password from URL
path Get path from URL
port Get port from URL
query Get query from URL
scheme Get scheme from URL
username Get username from URL
```## Contributing
Development is managed on [Github](https://github.com/tedivm/urlparser) and pull requests are always appreciated.