Skip to content

Instantly share code, notes, and snippets.

View vaibhavrawdev's full-sized avatar

Vaibhav Rawat vaibhavrawdev

View GitHub Profile
@vaibhavrawdev
vaibhavrawdev / git-deploy.bash
Created February 26, 2020 07:23 — forked from taniarascia/git-deploy.bash
Track, commit, and push to git origin and development with bash script
#!/bin/bash
read -r -p 'Commit message: ' ${desc} # prompt user for commit message
git add . # track all files
git add -u # track all deleted files
git commit -m "$desc" # commit with message
git push origin master # push to origin
git push production master # push to development server
@vaibhavrawdev
vaibhavrawdev / remove-known-hosts.sh
Created February 18, 2020 17:29 — forked from geedew/remove-known-hosts.sh
Quickly removing a ~/.ssh/known_hosts entry
# ssh-keygen -R hostname [-f known_hosts_file]
# ssh-keygen -r hostname [-f input_keyfile] [-g]
#e.g.
ssh-keygen -R 192.168.99.99
ssh-keygen -R mytestdomain.vagrant
# Terminal Cheat Sheet
pwd # print working directory
ls # list files in directory
cd # change directory
~ # home directory
.. # up one directory
- # previous working directory
help # get help
-h # get help