Commit e72f99e5 authored by Sam Pablo Kuper's avatar Sam Pablo Kuper Committed by Sam Pablo Kuper
Browse files

Initial commit

parents
This diff is collapsed.
Command-line tool to shorten URLs using [v.gd](https://v.gd).
Assuming GNU/Linux with the `apt-get` command installed and working, GNU Bash as your shell, and installation rights available using `sudo`, you install `vgd` as follows:
sudo apt-get install curl gridsite-clients
mkdir -p ~/bin
curl -w "\n" XXXXXX > ~/bin/vgd
chmod ~/bin/vgd
echo -e '\n# Add ~/bin to PATH\nexport PATH="$HOME/bin:$PATH"' >> ~/.bashrc
source ~/.bashrc
You can now run vgd by entering `vgd` followed by the URL you want to shorten. Put the URL in single quotes. For example:
$ vgd 'example.com'
https://v.gd/RaZxUe
An example using a longer URL:
$ vgd 'https://en.wikipedia.org/w/index.php?title=CURL&action=history'
https://v.gd/35qysF
#!/bin/bash
# Copyright (C) 2016 Sam Pablo Kuper
# License: AGPLv3
# License URL: www.fsf.org/licensing/licenses/agpl-3.0.html
curl 'https://v.gd/create.php?format=simple&url='$(urlencode "$1")
  • We are providing ideal jobs for our youth do apply and get your best profession for further details [https://startjobs.pk/

Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment