Thes instructions have been tested on OSX, but should work just as fine on Linux.
Required:
- CMake
- clang
| {-# LANGUAGE OverloadedStrings #-} | |
| {-| | |
| Tokenizer for SLF0 serialization format, used by Xcode to, at the very least, | |
| encode some log files. | |
| For example, `.xcactivitylog` logs are gzipped files of this format, | |
| serializing some objc classes which represent the build log. | |
| This class tokenizes the raw byte stream into a flat list of tokens. The actual |
| #!/bin/bash | |
| # where to store the sparse-image | |
| WORKSPACE=~/Documents/workspace.dmg.sparseimage | |
| create() { | |
| hdiutil create -type SPARSE -fs 'Case-sensitive Journaled HFS+' -size 60g -volname workspace ${WORKSPACE} | |
| } | |
| detach() { |
| // Just before switching jobs: | |
| // Add one of these. | |
| // Preferably into the same commit where you do a large merge. | |
| // | |
| // This started as a tweet with a joke of "C++ pro-tip: #define private public", | |
| // and then it quickly escalated into more and more evil suggestions. | |
| // I've tried to capture interesting suggestions here. | |
| // | |
| // Contributors: @r2d2rigo, @joeldevahl, @msinilo, @_Humus_, | |
| // @YuriyODonnell, @rygorous, @cmuratori, @mike_acton, @grumpygiant, |
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 8000| import sys | |
| import colorsys | |
| from colorz import colorz | |
| WALLPAPER = '/home/james/.wallpaper' | |
| COLORS = '/home/james/.colors' | |
| XRESOURCES = '/home/james/.Xresources' | |
| cols = '' | |
| xres = """ |
| 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 |
| # INSTALL INSTRUCTIONS: save as ~/.gdbinit | |
| # | |
| # DESCRIPTION: A user-friendly gdb configuration file. | |
| # | |
| # REVISION : 7.3 (16/04/2010) | |
| # | |
| # CONTRIBUTORS: mammon_, elaine, pusillus, mong, zhang le, l0kit, | |
| # truthix the cyberpunk, fG!, gln | |
| # | |
| # FEEDBACK: https://www.reverse-engineering.net |
| #include <iostream> | |
| // This is a rewrite and analysis of the technique in this article: | |
| // http://bloglitb.blogspot.com/2010/07/access-to-private-members-thats-easy.html | |
| // ------- Framework ------- | |
| // The little library required to work this magic | |
| // Generate a static data member of type Tag::type in which to store | |
| // the address of a private member. It is crucial that Tag does not |
| #! /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 |