Skip to content

Instantly share code, notes, and snippets.

View dardo82's full-sized avatar
🏠
Working from home

Michele Venturi dardo82

🏠
Working from home
View GitHub Profile
@tuxfight3r
tuxfight3r / 01.bash_shortcuts_v2.md
Last active May 2, 2024 09:06
Bash keyboard shortcuts

Bash Shortcuts

visual cheetsheet

Moving

command description
ctrl + a Goto BEGINNING of command line
@trusktr
trusktr / DefaultKeyBinding.dict
Last active April 21, 2024 06:32
My DefaultKeyBinding.dict for Mac OS X
/* ~/Library/KeyBindings/DefaultKeyBinding.Dict
This file remaps the key bindings of a single user on Mac OS X 10.5 to more
closely match default behavior on Windows systems. This makes the Command key
behave like Windows Control key. To use Control instead of Command, either swap
Control and Command in Apple->System Preferences->Keyboard->Modifier Keys...
or replace @ with ^ in this file.
Here is a rough cheatsheet for syntax.
Key Modifiers
@bzerangue
bzerangue / _verify-repair-permissions-disk.md
Last active April 25, 2024 22:55
Mac OS X Utilities via Terminal: (Verify and Repair: Disk Permissions AND Disk / Software Update / TimeMachine)

Verify and Repair Disk Permissions via Terminal (Mac OS X)

Verify Permissions

diskutil verifyPermissions /

Repair Permissions

diskutil repairPermissions /

@yunga
yunga / Cliref.md
Last active February 1, 2024 00:56
CLIRef.md
_________ _____ _______________       _____
\_   ___ \\    \\___________   \____ / ____\     ~/.bash/cliref.md
/    \  \/|    | |   ||       _/ __ \  __\    copy/paste from whatisdb
\     \___|__  |_|_  ||    |   \  __/|_ |   http://pastebin.com/yGmGiDQX
 \________  /_____ \_||____|_  /____  /_|     yunga.palatino@gmail.com
 20160515 \/ 1527 \/         \/     \/

alias CLIRef.txt='curl -s "http://pastebin.com/raw/yGmGiDQX" | less -i'

@jedisct1
jedisct1 / pureftpd shellshock.txt
Last active August 8, 2023 20:07
Pure-FTPd + external authentication handler #shellshock POC
$ cat > /tmp/handler.sh
#! /bin/bash
echo auth_ok:1
echo uid:42
echo gid:21
echo dir:/tmp
echo end
^D
$ chmod +x /tmp/handler.sh
@jeffaudi
jeffaudi / tumblr-likes-downloader.py
Last active June 15, 2022 01:25
This python script downloads all the photos liked of your tumblr account. This is usually more useful than downloading the photos from a specfic blog. Updated to also download videos and store content is folders. Please, note that currently the Tumblr API only returns the first 1000 likes (https://groups.google.com/forum/#!searchin/tumblr-api/li…
import pytumblr
import os
import code
import oauth2 as oauth
from pprint import pprint
import json
import urllib
import codecs
# Number of likes to fetch in one request
@tristanwietsma
tristanwietsma / term2gif.sh
Created August 27, 2014 14:53
Record terminal session to GIF
#!/bin/bash
TIMING=$1
SCRIPT=$2
W=$WINDOWID
rm -rf /tmp/script-replay-gifs/
mkdir /tmp/script-replay-gifs/
t=$(mktemp)
@lordgnu
lordgnu / gist:bb0a4d039b5f5fd0e67b
Created June 26, 2014 18:41
Add a User to a Group on OS X
# Command Syntax
sudo dseditgroup -o edit -a <USERNAME> -t user <GROUP NAME>
# To Fix Zend Server Permissions Issues
COMMAND="dseditgroup -o edit -a `whoami` -t user zend"
sudo $COMMAND
@neonexus
neonexus / OpenSSL Commands.md
Last active May 17, 2016 14:24
AWS ELB OpenSSL commands list

Generate KEY and CSR:

openssl req -new -newkey rsa:2048 -nodes -keyout DOMAIN.key -out DOMAIN.csr

Echo the KEY in PEM format:

openssl rsa -in DOMAIN.key -outform PEM

Echo the CRT in PEM format:

@vedant
vedant / gist:9333992
Last active May 27, 2020 06:46
Export note files from Google Keep
/* Vedant Misra (vedantmisra.com) (github.com/vedant)
*
* Script for exporting Google Keep note files.
*
* This does not handle attachments or checklists, only note files. Downloads
* each note to a .txt file named for the note's title.
*
* To use this, go to https://drive.google.com/keep/ and wait for the page to
* fully load all of your saved notes; scroll to the bottom to confirm they're
* loaded. Then paste the below in your URI bar, go to the start of the line,