This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| sessionPWD="/home/$USER/"; | |
| sessionName="new-session"; #must be same as filename | |
| #check if already created | |
| cd ${sessionPWD}; | |
| #create SESSION | |
| tmux new-session -s ${sessionName} -n vim -d | |
| #first window 1: vim | |
| tmux send-keys -t ${sessionName} 'vim' C-m |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #tempmon modified | |
| function tempmon() { | |
| # datadir="$HOME/tempinfo"; | |
| datadir="/tmp/tempinfo"; | |
| # rm -rf $datadir; | |
| mkdir -p $datadir; | |
| sleeptime=10; #seconds |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [user] | |
| name = Pavan Kumar Sunkara | |
| email = pavan.sss1991@gmail.com | |
| [core] | |
| editor = vim | |
| whitespace = fix,-indent-with-non-tab,trailing-space,cr-at-eol | |
| excludesfile = ~/.gitignore | |
| [sendemail] | |
| smtpencryption = tls | |
| smtpserver = smtp.gmail.com |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from __future__ import print_function #from BaseHTTPServer import HTTPServer, BaseHTTPRequestHandler | |
| import http.server, urllib, datetime | |
| #================================================================= | |
| sUrl="/chatbox" #server url | |
| port=8080 #server port | |
| timedRefresh="15" #time before page refreshes | |
| msgBox=[] #messages held here as dict objects | |
| #================================================================= | |
| # create html | |
| #================================================================= |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from __future__ import print_function #from BaseHTTPServer import HTTPServer, BaseHTTPRequestHandler | |
| import http.server, urllib, datetime, json | |
| #================================================================= | |
| sUrl="/testServer" #server url | |
| port=8000 #server port | |
| #================================================================= | |
| # data | |
| #================================================================= | |
| jsonDict = { | |
| "login" : { # sent at login |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!doctype html> | |
| <html> | |
| <!-- | |
| TODO: | |
| ---- | |
| write things to do here | |
| --> | |
| <head> | |
| <meta charset="utf-8"> | |
| <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # backup script for incremental backups | |
| tbkp () { | |
| [[ -z "$1" ]] && ( echo "Usage:"; | |
| echo "tbkp /path/to/dir/"; return 1; ) | |
| fp="$(readlink -f "$1")"; #full path of dir to be used | |
| if [ -d "$fp" ]; then | |
| lc="${fp%/*}"; #absolute location to be removed from tar |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/python2.7 | |
| import os, sys, re | |
| from PIL import Image, ImageChops, ImageOps | |
| def show_usage () : | |
| print("""Simple JPEG to monitor sized wallpaper generator\nDeps: PIL(2.7)\nUsage:\n[python2.7] %s /path/to/image [/path/to/outfile] [WIDTHxHEIGHT]\n""" % (sys.argv[0],)) | |
| def makeThumb(f_in, f_out, size=(80,80), pad=False): | |
| image = Image.open(f_in) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <script type="text/javascript" src="https://www.google.com/jsapi"></script> | |
| <script type="text/javascript"> | |
| /*!-- Sample feedbox html -- | |
| <div class="feeds"> | |
| <p class="feed-title"> | |
| <a href="url">title</a> | |
| description | |
| </p> | |
| <ul> | |
| <li> entry </li> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| #script to find git repositories when it becomes hard to keep track of all git repositories | |
| #takes $1 as root path to search, default= $PWD | |
| # argumnet -diff checks if any of the gits are modified locally | |
| # argumnet -url checks if any of the gits are modified locally | |
| # both arguments are enabled by default so use -nodiff, -nourl | |
| #read location or use current dir |
OlderNewer