This file contains 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
#!/usr/bin/env bash | |
# mac services | |
# https://gist.github.com/marcelaraujo/9a9fe07c5a4bcaea8c06 | |
# disable SIP from recovery mode | |
csrutil disable | |
# disable spotlight indexing | |
sudo launchctl unload -w /System/Library/LaunchDaemons/com.apple.metadata.mds.plist |
This file contains 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
#!/usr/bin/env bash | |
# add note | |
nb a "some text" | |
# edit note 12 | |
nb e 12 | |
# delete note 12 | |
nb d 12 |
This file contains 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
[ | |
{ "keys": ["super+q"], "command": "exit" }, | |
{ "keys": ["super+shift+n"], "command": "new_window" }, | |
{ "keys": ["super+shift+w"], "command": "close_window" }, | |
{ "keys": ["super+o"], "command": "prompt_open_file" }, | |
// { "keys": ["super+shift+t"], "command": "reopen_last_file" }, | |
{ "keys": ["super+n"], "command": "new_file" }, | |
{ "keys": ["super+s"], "command": "save", "args": { "async": true } }, | |
{ "keys": ["super+shift+s"], "command": "prompt_save_as" }, | |
// { "keys": ["super+f4"], "command": "close_file" }, |
This file contains 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
#!/usr/bin/env bash | |
# Search the gist list and filter on the supplied arguments. | |
# Display the results or if a single match is found then open the gist in the code editor. | |
set -o errexit | |
set -o nounset | |
set -o pipefail | |
IFS=$'\n\t' |
This file contains 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
#!/usr/bin/env bash | |
# allow port 80 (tcp optional) | |
sudo ufw allow 80 | |
sudo ufw allow 80/tcp | |
# block port 80 | |
sudo ufw deny 80 | |
# allow 1433 access for specific IP address |
This file contains 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
#!/usr/bin/env bash | |
chmod -R 666 * |
This file contains 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
#!/usr/bin/env bash | |
# Update the ufw rules to allow access for the supplied IP address to the port specified below. | |
# If a rule already exists it will be deleted. | |
# This script was created to get round server restrictions when working at home without allowing open | |
# public access. | |
PORT=1433 | |
ip=$1 |
This file contains 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/sh -x | |
#This script removes Mono from an OS X System. It must be run as root | |
rm -r /Library/Frameworks/Mono.framework | |
rm -r /Library/Receipts/MonoFramework-* | |
for dir in /usr/bin /usr/share/man/man1 /usr/share/man/man3 /usr/share/man/man5; do | |
(cd ${dir}; |
This file contains 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
#!/usr/bin/env bash | |
# go to character 25 on line 2 | |
:call cursor(2,25) | |
# show whitespace | |
:set listchars=eol:¬,tab:>·,trail:~,extends:>,precedes:<,space:␣ | |
:set list | |
# hide whitespace |
This file contains 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
#!/usr/bin/env bash | |
# list the directories in the current directory | |
tree -d -L 1 | |
# list the directories, and their immediate child directories in the current directory | |
tree -d -L 2 | |
OlderNewer