To setup your computer to work with *.test domains, e.g. project.test, awesome.test and so on, without having to add to your hosts file each time.
- Homebrew
- Mountain Lion -> High Sierra
To setup your computer to work with *.test domains, e.g. project.test, awesome.test and so on, without having to add to your hosts file each time.
Ideas are cheap. Make a prototype, sketch a CLI session, draw a wireframe. Discuss around concrete examples, not hand-waving abstractions. Don't say you did something, provide a URL that proves it.
Nothing is real until it's being used by a real user. This doesn't mean you make a prototype in the morning and blog about it in the evening. It means you find one person you believe your product will help and try to get them to use it.
tim@touchsmart:~/Code$ nvm use v0.11.2-generators | |
Now using node v0.11.2-generators | |
tim@touchsmart:~/Code$ node --harmony testgen.js | |
<Buffer 76 61 72 20 66 73 20 3d 20 72 65 71 75 69 72 65 28 27 66 73 27 29 3b 0a 66 75 6e 63 74 69 6f 6e 20 72 65 61 64 46 69 6c 65 28 70 61 74 68 2c 20 65 6e 63 ...> | |
Sleeping for 2000ms... | |
Done |
Provided that you already have a file or stream segmenter generating your .m3u8 playlist and .ts segment files (such as the ffmpeg 'hls' muxer), this little node server will serve up those files to an HLS compatible client (e.g. Safari). If you're using node for your streaming app already, this obviates the need to serve the HLS stream from a separate web server.
loosely based on https://gist.github.com/bnerd/2011232
// loosely based on https://gist.github.com/bnerd/2011232
// requires node.js >= v0.10.0
// assumes that HLS segmenter filename base is 'out'
// and that the HLS playlist and .ts files are in the current directory
# Configs | |
config defaultToCurrentScreen true | |
config nudgePercentOf screenSize | |
config resizePercentOf screenSize | |
config secondsBetweenRepeat 0.1 | |
config checkDefaultsOnLoad true | |
config focusCheckWidthMax 3000 | |
config keyboardLayout qwerty | |
config windowHintsShowIcons true | |
config windowHintsIgnoreHiddenWindows false |
#!/usr/bin/env escript | |
%% -*- erlang -*- | |
%% * slurp in terms using inlined version of kernels file:consult/1 | |
%% * convert to abstract syntax tree | |
%% * annotate all tuples | |
%% * pretty print using a hook to prefix the annotated nodes with newline | |
main([]) -> | |
io:format("%% -*-erlang-*-~n"), |
There is a javascript console, called JSC, in: | |
/System/Library/Frameworks/JavaScriptCore.framework/Versions/Current/Resources/jsc | |
JSC is not in the shell PATH by default, to fix that: | |
$ sudo ln /System/Library/Frameworks/JavaScriptCore.framework/Versions/A/Resources/jsc /usr/local/bin | |
Note that you'll have to use debug() instead of the conventional console.log() in your script to see any output. |
license: gpl-3.0 |
% networked ping | |
% -- | |
% Open firewall ports 4369 (erlang port mapper) and 9100-9105 (communication ports) | |
% | |
% On node 1 start your shell with this command: | |
% erl -name [email protected] -setcookie cook -kernel inet_dist_listen_min 9100 inet_dist_listen_max 9105 | |
% | |
% On node 2 start your shell with this command: | |
% erl -name [email protected] -setcookie cook -kernel inet_dist_listen_min 9100 inet_dist_listen_max 9105 | |
% |
# Script for automatic setup of SOCKS proxy through SSH connection. | |
# It automatically teardowns SOCKS configuration before stopping. | |
# It's supposed to work on Mac OS X 10.6+ | |
# | |
# Author: Adam Stankiewicz (@sheerun) | |
# | |
[[ -n "$1" ]] || { echo "Usage: proxy [email protected]"; exit 1; } | |
# get service GUID and NAME (like Wi-Fi) to set SOCKS proxy |