I hereby claim:
- I am hadrianw on github.
- I am hawski (https://keybase.io/hawski) on keybase.
- I have a public key ASB7SqEkozW7v4jD75NZ4Mzrfz_OAY2jwl2v0SQkcI47TQo
To claim this, I am signing this object:
| /* | |
| Compile with: | |
| $ gcc prace.c -o prace -std=c99 -pedantic -Wall -Wextra | |
| Example usage in shell script: | |
| $ ((sleep 4; echo foo)& (sleep 2; echo bar)& exec ./prace) | |
| bar | |
| $ | |
| */ |
| .c: Makefile | |
| gcc -std=c99 -pedantic -Wall -Wextra $< -o $@ | |
| all: | |
| make $$(for i in *.c; do echo $${i%.c}; done) | |
| .c: Makefile | |
| gcc -std=c99 -pedantic -Wall -Wextra $< -o $@ | |
| .PHONY: all |
| #if 0 | |
| set -e; [ "$0" -nt "$0.bin" ] && | |
| gcc -Wall -Wextra -pedantic -std=c99 "$0" -o "$0.bin" | |
| exec "$0.bin" "$@" | |
| #endif | |
| #include <stdio.h> | |
| int | |
| main(int argc, char *argv[]) { |
| var d=document; | |
| var q=d.querySelector.bind(d); | |
| var c='width=device-width,initial-scale=1'; | |
| var v=q('meta[name=viewport]'); | |
| if(v){ | |
| v.content=c | |
| }else{ | |
| v=d.createElement('meta'); | |
| v.name='viewport'; | |
| v.content=c; |
| #include <ftw.h> | |
| #include <stdio.h> | |
| #include <sqlite3.h> | |
| #define INSERT_QUERY "INSERT INTO index VALUES (?, ?)", | |
| static sqlite3 *db; | |
| static sqlite3_stmt *insert_stmt; | |
| static int step(const char *path, const struct stat *sb, int flag, struct FTW *ftwbuf) |
I hereby claim:
To claim this, I am signing this object:
| #!/bin/bash | |
| set -e | |
| VERSION="siteprep-1" | |
| EXT=".html" | |
| HEAD='<!DOCTYPE html> | |
| <meta charset=utf-8> | |
| <meta name=viewport content="width=device-width,initial-scale=1"> | |
| <style> |
| #define _XOPEN_SOURCE | |
| #include <assert.h> | |
| #include <stdbool.h> | |
| #include <stddef.h> | |
| #include <stdint.h> | |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <string.h> | |
| #include <unistd.h> |
| #if 0 | |
| set -e; [ "$0" -nt "$0.bin" ] && | |
| gcc -Wall -Wextra -pedantic -std=c99 "$0" -o "$0.bin" | |
| exec "$0.bin" "$@" | |
| #endif | |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #define LEN(x) (sizeof(x)/sizeof((x)[0])) |