2
0
Fork 0
mirror of https://github.com/alexanderepstein/Bash-Snippets synced 2018-11-08 02:59:35 +01:00
Bash-Snippets/README.md

144 lines
5.3 KiB
Markdown
Raw Normal View History

2017-06-27 02:18:07 +02:00
<div align="center">
2017-06-26 23:55:08 +02:00
# Bash-Snippets
2017-06-27 02:29:24 +02:00
<img src="http://icons.iconarchive.com/icons/paomedia/small-n-flat/1024/terminal-icon.png" height="250px" width="250px">
2017-06-27 03:55:38 +02:00
##### A collection of small bash scripts for heavy terminal users with no dependencies
2017-06-27 02:18:07 +02:00
2017-06-27 19:51:31 +02:00
![Version](https://img.shields.io/github/release/alexanderepstein/Bash-Snippets.svg) [![Codacy Badge](https://api.codacy.com/project/badge/Grade/a4bf023a3d0d499abc9d2bf14b296a14)](https://www.codacy.com/app/alexanderepstein/Bash-Snippets?utm_source=github.com&amp;utm_medium=referral&amp;utm_content=alexanderepstein/Bash-Snippets&amp;utm_campaign=Badge_Grade) ![platform](https://img.shields.io/badge/platform-OSX%20%26%20Linux-blue.svg) [![license](https://img.shields.io/github/license/mashape/apistatus.svg?style=plastic)]()
2017-06-28 02:32:43 +02:00
### All of these scripts have only been tested on OSX and Linux and are not recommended for use with Windows
2017-06-27 02:18:07 +02:00
</div>
## Weather
Provides a 3 day forecast based on your ip address
2017-06-27 02:22:25 +02:00
<div align="center">
<img height="75%" width="75%" src="https://github.com/alexanderepstein/Bash-Snippets/blob/master/weather/weather.png?raw=true">
</div>
2017-06-27 02:18:07 +02:00
#### To Be Added
[ ] Take in location as arguments
## Stocks
Provides information about a certain stock symbol
2017-06-27 02:22:25 +02:00
<div align="center">
<img max-height="500px" max-width="500px" src="https://github.com/alexanderepstein/Bash-Snippets/blob/master/stocks/stocks.png?raw=true">
</div>
2017-06-27 02:18:07 +02:00
## Currency
Converts currency based on realtime exchange rates
2017-06-27 02:22:25 +02:00
<div align="center">
<img max-height="500px" max-width="500px" src="https://github.com/alexanderepstein/Bash-Snippets/blob/master/currency/currency.png?raw=true">
</div>
2017-06-27 02:18:07 +02:00
2017-06-27 03:55:38 +02:00
#### To Be Added
[ ] Pass in arguments as well on top of the option to have it guide you through input
2017-06-27 03:03:40 +02:00
## Encryption & Decryption
A wrapper for openssl that allows for quickly encrypting and decrypting files
2017-06-27 19:55:20 +02:00
```bash
crypt -e [original file] [encrypted file] # encrypts files
crypt -d [encrypted file] [output file] # decrypts files
```
#### Encryption Details
* Uses AES 256 level encryption
* Key is salted before creation
* Password is never in plain text, and OpenSSL generates key based on password
* Data is encrypted in Base64, so it can be used as plain text in an email. (Not usually necessary if attached as a file)
**Tested With** => .pdf, .txt, .docx, .doc, .png, .jpeg
**CAUTION** => Make sure to use different filenames, otherwise your file will be overwritten!
2017-06-27 03:03:40 +02:00
<div align="center">
<img max-height="500px" max-width="500px" src="https://github.com/alexanderepstein/Bash-Snippets/blob/master/crypt/crypt.png?raw=true">
</div>
2017-06-27 04:41:41 +02:00
## Movies
Quick search that grabs relevant information about a movie
<div align="center">
<img max-height="500px" max-width="500px" src="https://github.com/alexanderepstein/Bash-Snippets/blob/master/movies/movies.png?raw=true">
</div>
2017-06-27 02:18:07 +02:00
## API's Used
* To get location based on ip address: <a href="ipinfo.io">ipinfo.io</a>
* To get and print weather based on a location: <a href="wttr.in">wttr.in</a>
2017-06-27 02:33:49 +02:00
* To grab the stock information in JSON format: <a href="https://www.alphavantage.co">alphavantage.co</a>
* To grab the latest exchange rate between currencies: <a href="http://api.fixer.io">api.fixer.io</a>
2017-06-27 04:44:17 +02:00
* To grab information on movies: <a href="http://www.omdbapi.com/">omdbapi.com</a>
2017-06-27 02:33:49 +02:00
#### Inspired by: <a href="https://github.com/jakewmeyer/Ruby-Scripts">Ruby-Scripts</a>
2017-06-27 02:18:07 +02:00
2017-06-27 03:20:38 +02:00
## Installing
* First clone the repository: ```git clone https://github.com/alexanderepstein/Bash-Snippets```
* Then cd into the cloned directory: ```cd Bash-Snippets```
* Run the guided install script with
2017-06-27 03:20:38 +02:00
```bash
./install.sh
```
this will let you choose which scripts to install
2017-06-27 03:20:38 +02:00
## Uninstalling
* If you don't have the Bash-Snippets folder anymore clone the repository: ```git clone https://github.com/alexanderepstein/Bash-Snippets```
* cd into the Bash-Snippets directory: ```cd Bash-Snippets```
#### To uninstall all scripts
```bash
./uninstall.sh
```
#### To uninstall individual scripts
Ex. Weather
```bash
cd weather
./uninstall.sh
```
2017-06-27 02:18:07 +02:00
## Donate
If this project helped you in any way and you feel like buying a broke college kid a cup of coffee
[![Donate](https://img.shields.io/badge/Donate-Venmo-blue.svg)](https://venmo.com/AlexanderEpstein)
[![Donate](https://img.shields.io/badge/Donate-SquareCash-green.svg)](https://cash.me/$AlexEpstein)
## License
MIT License
Copyright (c) 2017 Alex Epstein
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.