URL shortener via bit.ly, etc.
There are several URL shortening services such as bit.ly and TinyURL. To use these services, users need to open a browser and enter the URL. We would like to make it easier to shorten the url from the CLI.
urleap -t $(cat token) https://tamada.github.io/ # shorten the given url.
https://bit.ly/43gj5S9 (Bl9h5Cg7gvc) # shorten url (group)
urleap -t $(cat token) # list available shorten urls in the default group.
https://bit.ly/43gj5S9 (Bl9h5Cg7gvc): (https://tamada.github.io/) # shorten (group): original url
https://bit.ly/3pZy7hf (Bl9h5Cg7gvc): (https://tamadalab.github.io/) # shorten (group): original url
urleap [OPTIONS] [URLs...]
OPTIONS
-t, --token <TOKEN> specify the token for the service. This option is mandatory.
-q, --qrcode <FILE> include QR-code of the URL in the output.
-c, --config <CONFIG> specify the configuration file.
-g, --group <GROUP> specify the group name for the service. Default is "urleap"
-d, --delete delete the specified shorten URL.
-h, --help print this mesasge and exit.
-v, --version print the version and exit.
ARGUMENT
URL specify the url for shortening. this arguments accept multiple values.
if no arguments were specified, urleap prints the list of available shorten urls.
urleap
reads the following list of files in order and overwrites the settings.
If the file does not exist, it is simply ignored.
/opt/homebrew/opt/urleap/config.json
/usr/local/opt/urleap/config.json
$URLEAP_HOME/config.json
~/.config/urleap/config.json
./.urleap.json
- files specified by
--config
option
{
"providers": [
{
"api": "bit.ly",
"api_version": "v4",
}
]
}
brew install tamada/tap/urleap
docker run -it --rm tamada/urleap:latest -t <token> <url...>
0.5.0
,latest
- Permitted
- 🙆♀️ Commercial use
- 🙆♀️ Modification
- 🙆♀️ Distribution
- 🙆♀️ Private use
- Limitations
- 🙅♂️ Liability
- 🙅♂️ Warranty