git reflog --all | grep something
git fsck --full --no-reflogs --unreachable --lost-found | grep commit | cut -d\ -f3 | xargs -n 1 git log -n 1 --pretty=oneline > .git/lost-found.txt
git reflog --all | grep something
git fsck --full --no-reflogs --unreachable --lost-found | grep commit | cut -d\ -f3 | xargs -n 1 git log -n 1 --pretty=oneline > .git/lost-found.txt
git branch --no-merged
git branch --merged | egrep -v "(^\*|master|dev)" | xargs git branch -d
git branch --no-merged
git branch --merged | egrep -v "(^\*|master|dev)" | xargs git branch -d
vi /path/to/message.sh
#!/bin/bash
PID=$(pgrep gnome-session)
dbus=$(grep -z DBUS_SESSION_BUS_ADDRESS /proc/$PID/environ|cut -d= -f2-)
export DBUS_SESSION_BUS_ADDRESS=$dbus
notify-send -u critical "$1"
crontab:
0 * * * * /path/to/message.sh "my message"
vi /path/to/message.sh
#!/bin/bash
PID=$(pgrep gnome-session)
dbus=$(grep -z DBUS_SESSION_BUS_ADDRESS /proc/$PID/environ|cut -d= -f2-)
export DBUS_SESSION_BUS_ADDRESS=$dbus
notify-send -u critical "$1"
crontab:
0 * * * * /path/to/message.sh "my message"
tail /var/log/auth.log
find . -type f -newermt 2017-01-01 ! -newermt 2017-01-31
grep -lr --include=*.php "base64_decode"
grep -lr --include=*.php "@require"
tail /var/log/auth.log
find . -type f -newermt 2017-01-01 ! -newermt 2017-01-31
grep -lr --include=*.php "base64_decode"
grep -lr --include=*.php "@require"
git config receive.denycurrentbranch ignore
vi .git/hooks/post-receive
#!/bin/bash
cd ../
env -i git reset --hard
chmod +x .git/hooks/post-receive
git diff --name-status SHA1 SHA2 | cut -f2
git config receive.denycurrentbranch ignore
vi .git/hooks/post-receive
#!/bin/bash
cd ../
env -i git reset --hard
chmod +x .git/hooks/post-receive
git diff --name-status SHA1 SHA2 | cut -f2