As configured in my dotfiles.
start new:
tmux
start new with session name:
| #! /usr/bin/env python | |
| """ Convert values between RGB hex codes and xterm-256 color codes. | |
| Nice long listing of all 256 colors and their codes. Useful for | |
| developing console color themes, or even script output schemes. | |
| Resources: | |
| * http://en.wikipedia.org/wiki/8-bit_color | |
| * http://en.wikipedia.org/wiki/ANSI_escape_code |
| // Reconstruct worldspace depth value from z/w depth buffer | |
| float depth = -(z_near * z_far) / (zbuffer_depth * (z_far - z_near) - z_far); | |
| // Compute screenspace coordinate of pixel | |
| float2 screenspace = (float2(pixel.xy) / float2(viewport_size.xy)) * 2.0f - 1.0f; | |
| // Get direction of ray from camera through pixel | |
| float3 ray_direction = normalize(camera_forward + camera_right * screenspace.x - camera_up * screenspace.y); | |
| // Reconstruct world position from depth: depth in z buffer is distance to picture plane, not camera |
As configured in my dotfiles.
start new:
tmux
start new with session name:
To run this, you can try:
curl -ksO https://gist.githubusercontent.com/nicerobot/2697848/raw/uninstall-node.sh
chmod +x ./uninstall-node.sh
./uninstall-node.sh
rm uninstall-node.sh
| Latency Comparison Numbers (~2012) | |
| ---------------------------------- | |
| L1 cache reference 0.5 ns | |
| Branch mispredict 5 ns | |
| L2 cache reference 7 ns 14x L1 cache | |
| Mutex lock/unlock 25 ns | |
| Main memory reference 100 ns 20x L2 cache, 200x L1 cache | |
| Compress 1K bytes with Zippy 3,000 ns 3 us | |
| Send 1K bytes over 1 Gbps network 10,000 ns 10 us | |
| Read 4K randomly from SSD* 150,000 ns 150 us ~1GB/sec SSD |
| require 'tumblr_client' | |
| require 'mechanize' | |
| require 'date' | |
| require 'yaml' | |
| require 'uri' | |
| Tumblr.configure do |config| | |
| config.consumer_key = "consumer_key" | |
| config.consumer_secret = "consumer_secret" | |
| config.oauth_token = "oath_token" |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000Attention: the list was moved to
https://github.com/dypsilon/frontend-dev-bookmarks
This page is not maintained anymore, please update your bookmarks.