Benchmarking results for common command-line operations on macOS.
- Time: 16.7ms ± 0.3ms
- Usage:
if pgrep -q ssh; then echo "SSH running"; fi - Why: Fast, clean exit codes, no output parsing
| #!/bin/bash | |
| # Claude Code Status Bar with Current Directory | |
| # Prepends the current working directory to your Claude Code status bar | |
| # Home directory is displayed as ~ for cleaner output | |
| # Read the input JSON from Claude Code | |
| input=$(cat) | |
| # Extract the current working directory from the workspace data | |
| current_dir=$(echo "$input" | jq -r '.workspace.current_dir') |
| import math | |
| import matplotlib.pyplot as plt | |
| timestamps = [] | |
| xs = [] | |
| ys = [] | |
| sample_rate = 4 # 10ms | |
| x_begin = x_end = 0x285 |
| local apps = {} | |
| -- App-specific code, runs when you launch or switch to another app | |
| local App = {} | |
| App.new = function(name) | |
| log.d('new App for ',name) | |
| local self = {} | |
| self.name = name | |
| self.bindings = {} |
| /* | |
| PoC WhatsApp enumeration of phonenumbers, profile pics, about texts and online statuses | |
| Floated div edition | |
| 01-05-2017 | |
| (c) 2017 - Loran Kloeze - loran@ralon.nl | |
| This script creates a UI on top of the WhatsApp Web interface. It enumerates certain kinds | |
| of information from a range of phonenumbers. It doesn't matter if these numbers are part | |
| of your contact list. At the end a table is displayed containing phonenumbers, profile pics, | |
| about texts and online statuses. The online statuses are being updated every |
| " | |
| " how to install | |
| " | |
| " git clone https://github.com/gmarik/vundle.git ~/.vim/bundle/vundle | |
| " vim +BundleInstall +qall | |
| " | |
| set nocompatible | |
| " vundle { | |
| filetype off |
| #include <math.h> | |
| #include <stdint.h> | |
| #include <stdlib.h> | |
| static char encoding_table[] = {'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', | |
| 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', | |
| 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', | |
| 'Y', 'Z', 'a', 'b', 'c', 'd', 'e', 'f', | |
| 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', |
| void GetArgAsStdString(const Arguments& args, int n, std::string& str) { | |
| Local<String> inbuf_str = args[n].As<String>(); | |
| str.resize(inbuf_str->Utf8Length()); | |
| inbuf_str->WriteUtf8((char *) &(str[0])); | |
| } | |
| bool GetObjValAsUInteger(Handle<Object> obj, const char *key, size_t& uintVal) { | |
| Local<String> k = String::New(key); | |
| if (!obj->Has(k)) { | |
| return false; |