Skip to content

Instantly share code, notes, and snippets.

View markedagain's full-sized avatar

Mark Kalender markedagain

View GitHub Profile
@markedagain
markedagain / gist:5294466
Last active December 15, 2015 17:09
diff example
diff --exclude=".svn" -ruNb /home/production/code /home/stage/code > /tmp/diff.patch
cat /tmp/flix.patch
echo "file can be found at /tmp/diff.patch "
@markedagain
markedagain / gist:5379168
Created April 13, 2013 16:51
cron for auto removing complete list from transmission
*/5 * * * * /usr/bin/transmission-remote -l | grep 100\% | grep Done | awk '{print $1}' | xargs -n 1 -I \% /usr/bin/transmission-remote -t \% -r
@markedagain
markedagain / gist:5405020
Created April 17, 2013 15:01
disable java toolbar install during update
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft]
"SPONSORS"="DISABLE"
[HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\JavaSoft]
"SPONSORS"="DISABLE"
@markedagain
markedagain / gist:5405027
Created April 17, 2013 15:02
ubuntu install latest agent on clone device
#sed -i "s/old_host_name/new_host_name/g" /etc/hosts
#sed -i "s/old_host_name/new_host_name/g" /etc/hostname
#hostname new_host_name
#reboot now #for changes to take affect
#
grep puppet /etc/hosts; [ $? -eq 1 ] && echo "192.168.1.128 puppet" >> /etc/hosts
#ping puppet #test
#
apt-get update
apt-get dist-upgrade -y
public static List<GameObject> getRoute(GameObject fromRoad , GameObject toRoad , GameObject lastRoad, List<GameObject> pathSoFar ){
List<GameObject> _tmpListRoad = GeneralHelper.findTilesNear(_roadList,fromRoad.transform.position,2);
for (int i = 0; i < _tmpListRoad.Count; i++) {
if (_tmpListRoad[i] == toRoad ){//we found our destination
pathSoFar.Add(_tmpListRoad[i]);
return pathSoFar;
}else{//nope lets make sure this tile is not where we currently are and try the next tile in connection
if (fromRoad != _tmpListRoad[i] && lastRoad != _tmpListRoad[i]){ //make sure this tile was not already verified
if (getRoute(_tmpListRoad[i],toRoad,fromRoad , pathSoFar) != null){
$(document).ready(function() {
$("#issue-form").submit(function(e){
if ($("#issue_status_id option[value='11']").attr('selected')){
if ($('#issue_tags ul li').length == 1){
alert('no tags');
return false
}
}
this.submit();
return true;
const int LED_PIN = 13;
const int BRAUD_RATE = 9600;
const int PIN_NO = 29;
const int STATE_PIN_NO = 4;
// Input pin management
int rPins[PIN_NO] = {A3,A4,A11,A12,A13,A14,A15,5,6,7,8,9,10,11,12,22,23,24,25,26,27,34,35,36,37,38,39,40,41};
int rPinsFlags[PIN_NO][2];
int statePins[STATE_PIN_NO] = {28,29,31,32};
@markedagain
markedagain / tmux.md
Created March 8, 2018 04:08 — forked from andreyvit/tmux.md
tmux cheatsheet

tmux cheat sheet

(C-x means ctrl+x, M-x means alt+x)

Prefix key

The default prefix is C-b. If you (or your muscle memory) prefer C-a, you need to add this to ~/.tmux.conf:

remap prefix to Control + a

nc -lvnp 1234
http://pentestmonkey.net/cheat-sheet/shells/reverse-shell-cheat-sheet
python -c 'import pty;pty.spawn("/bin/bash");'
ctrl + z
stty raw -echo
fg