I hereby claim:
- I am stonegray on github.
- I am stonegray (https://keybase.io/stonegray) on keybase.
- I have a public key whose fingerprint is E0A9 E8BA 5410 5182 A93B 3AF7 1360 199F B17A CA3D
To claim this, I am signing this object:
// tetromino.c | |
// Reddit Programming Challenge | |
// https://www.reddit.com/r/dailyprogrammer/comments/3ofsyb/20151012_challenge_236_easy_random_bag_system/ | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <time.h> | |
int main() { | |
// Magic numbers | |
unsigned long long m = 0x4F49535A4C4A54; |
// Month name to month integer. | |
// Input a lowercase month name | |
#include <stdio.h> | |
int main(int argc, char *argv[]){ | |
if (argc != 2) return 1; | |
const int __ = 0b1; | |
const int x_ = 0b11; | |
const int _x=x_+ 0b111; | |
char _[42]="\0\0LCPHGDOCTCRTOC[LWPLWNCWIUGRQEVPQXFGEmx\0"; | |
while(1){ |
// Arduino compatibility snippet to use with other platforms. | |
// Doesn't work (or not optimized) on your platform? Email me! | |
// https://gist.github.com/stonegray/348e4855a39074daa9a5540edda78984 | |
#if defined( __AVR__ ) | |
#include <avr/pgmspace.h> | |
#elif defined( ESP8266 ) | |
#include <pgmspace.h> | |
#define F(x) (x) | |
#elif defined( __arm__ ) | |
#define pgm_read_byte(addr) (*(const unsigned char *)(addr)) |
" Stone's vimrc v0.1 | |
"""""""""""""""""""""""" | |
" View changes | |
syntax on | |
set ruler | |
set visualbell | |
filetype indent plugin on | |
filetype off |
I hereby claim:
To claim this, I am signing this object:
/* brackets.js | |
* | |
* Obfuscated JS practice. | |
* | |
* Accepts a string containing Javascirpt code, returns true if the brackets | |
* are balanced. Supports (), {}, and []. | |
*/ | |
const bracketsAreBalanced = n => ( | |
( |
There's no immedialy obvious way to determine which block device is definitely an AWS ephemeral storage device, so this quick snippet will grab it.
No error checking, so if you don't actually have an ephemeral storage device it will return the string "/dev/".
EPHEMERAL_STORAGE=/dev/$(lsblk -o +MODEL |grep "EC2 NVMe Instance Storage" | sed "s/ .*//")
# Get ephemereral storage device by block model data:
# Quick install script for esp-idf | |
# Should you be using the Docker container instead? | |
# https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-guides/tools/idf-docker-image.html | |
brew install python3 cmake ninja dfu-util | |
mkdir -p ~/esp | |
cd ~/esp | |
git clone --recursive https://github.com/espressif/esp-idf.git |
<!-- ~~~~~~~~~~~~~~~~~~~~ --> | |
/$$ Stones Evil Eval() $$/ | |
<!-- ~~~~~~~~~~~~~~~~~~~~ --> | |
/* | |
* This file implements an alternate version of the builtin eval(); | |
* function. Please note this is known to crash some parsers. (fixed | |
* in latest versions) | |
* | |
* If this loads missing indentation on GitHub, just reload the page. |
services: | |
mosquitto: | |
image: eclipse-mosquitto | |
container_name: mosquitto | |
restart: unless-stopped | |
labels: | |
- "docker-compose-watcher.watch=1" | |
- "docker-compose-watcher.dir=." | |
volumes: |