Note: these instructions are for pre-Sierra MacOS. Sierra (10.12) and newer users see https://gist.github.com/gravitylow/fb595186ce6068537a6e9da6d8b5b96d by @gravitylow
If you are getting this in gdb on OSX while trying to run a program:
| (defconst doom-fringe-size '3 "Default fringe width") | |
| ;;; Setting up the fringe | |
| ;; switches order of fringe and margin | |
| (setq-default fringes-outside-margins t) | |
| ;; standardize fringe width | |
| (fringe-mode doom-fringe-size) | |
| (push `(left-fringe . ,doom-fringe-size) default-frame-alist) | |
| (push `(right-fringe . ,doom-fringe-size) default-frame-alist) |
Note: these instructions are for pre-Sierra MacOS. Sierra (10.12) and newer users see https://gist.github.com/gravitylow/fb595186ce6068537a6e9da6d8b5b96d by @gravitylow
If you are getting this in gdb on OSX while trying to run a program:
| # This is not a script! These are notes! | |
| KEY= | |
| DOMAINID= | |
| RESOURCE_ID= | |
| # Getting the domain ID | |
| https://api.linode.com/?api_key=$KEY&api_action=domain.list | |
| # Getting the resource ID |
| ;; Thanks to: https://github.com/winterTTr/ace-jump-mode/issues/23 | |
| (defun ace-jump-two-chars-mode (&optional query-char query-char-2) | |
| "AceJump two chars mode" | |
| (interactive) | |
| (evil-half-cursor) | |
| (setq query-char (or query-char (read-char ">"))) | |
| (setq query-char-2 (or query-char-2 (read-char (concat ">" (string query-char))))) | |
| (if (eq (ace-jump-char-category query-char) 'other) |
| ;; A hack to add vim file modifiers to evil-mode's ex commandline: | |
| ;; | |
| ;; Requires projectile (https://github.com/bbatsov/projectile) for | |
| ;; project-awareness, and f.el (https://github.com/rejeep/f.el) for file | |
| ;; functions. | |
| (defun +evil*ex-replace-special-filenames (file-name) | |
| "Replace special symbols in FILE-NAME. Modified to include other substitution | |
| flags. See http://vimdoc.sourceforge.net/htmldoc/cmdline.html#filename-modifiers." | |
| (let* (case-fold-search | |
| (regexp (concat "\\(?:^\\|[^\\\\]\\)" |
| /** | |
| * LaunchBar Javascript API (see http://www.obdev.at/products/launchbar/index.html) | |
| * | |
| * For use with auto-completion libraries. | |
| */ | |
| // Included to hide "unused function" warnings | |
| run(); | |
| runWithItem({}); | |
| runWithPaths({}); |
| " I remap the leader/localleader, and ; to alias :, but what if I like , and ;? | |
| let mapleader = ',' | |
| noremap ; : | |
| " Makes f, F, t and T repeat the search. Support repeating with . | |
| nnoremap <Plug>NextMatch ; | |
| nnoremap <silent> f :<C-u>call repeat#set("\<lt>Plug>NextMatch")<CR>f | |
| nnoremap <silent> F :<C-u>call repeat#set("\<lt>Plug>NextMatch")<CR>F | |
| nnoremap <silent> t :<C-u>call repeat#set("\<lt>Plug>NextMatch")<CR>t | |
| nnoremap <silent> T :<C-u>call repeat#set("\<lt>Plug>NextMatch")<CR>T |
| # ag <https://github.com/ggreer/the_silver_searcher> | |
| # usage: ag-replace.sh [search] [replace] | |
| # caveats: will choke if either arguments contain a forward slash | |
| # notes: will back up changed files to *.bak files | |
| ag -0 -l $1 | xargs -0 perl -pi.bak -e "s/$1/$2/g" | |
| # or if you prefer sed's regex syntax: | |
| ag -0 -l $1 | xargs -0 sed -ri.bak -e "s/$1/$2/g" |
| #!/bin/bash | |
| IPT="/sbin/iptables" | |
| #### IPS ###### | |
| # Get server public ip | |
| SERVER_IP=$(ifconfig eth0 | grep 'inet addr:' | awk -F'inet addr:' '{ print $2}' | awk '{ print $1}') | |
| #### FILES ##### | |
| BLOCKED_IP_TDB=/root/.fw/blocked.ip.txt | |
| SPOOFIP="127.0.0.0/8 192.168.0.0/16 172.16.0.0/12 10.0.0.0/8 169.254.0.0/16 0.0.0.0/8 240.0.0.0/4 255.255.255.255/32 168.254.0.0/16 224.0.0.0/4 240.0.0.0/5 248.0.0.0/5 192.0.2.0/24" |