This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"archive/tar" | |
"bytes" | |
"compress/gzip" | |
"encoding/json" | |
"errors" | |
"fmt" | |
"io" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git clone https://github.com/voidlinux/void-mklive | |
cd void-mklive | |
mkdir -p extra/etc/runit/runsvdir/default/ | |
ln -s /etc/sv/agetty-ttyS0 extra/etc/runit/runsvdir/default/ | |
make | |
sudo ./mklive.sh -a x86_64-musl -I extra/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
// +build freebsd,amd64 | |
import ( | |
"C" | |
"fmt" | |
"os" | |
"syscall" | |
"unsafe" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
set -e | |
mkdir -p target | |
mkdir -p deps | |
git clone https://github.com/rust-lang/semver deps/semver | |
git clone https://github.com/docopt/docopt.rs deps/docopt.rs | |
git clone https://github.com/alexcrichton/curl-rust deps/curl-rust --branch bundle |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
comm -1 -3 <(pacman -Qe | sort) <(pacman -Qt | sort) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import "fmt" | |
func main() { | |
s := "\tfmt.Printf(\"package main\\nimport \\\"fmt\\\"\\nfunc main() {\\n\\ts := %q\\n%s\\n}\\n\", s, s)" | |
fmt.Printf("package main\nimport \"fmt\"\nfunc main() {\n\ts := %q\n%s\n}\n", s, s) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"fmt" | |
"unsafe" | |
) | |
func main() { | |
var ptr uintptr | |
var i int |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* gcc -std=c99 csizes.c -o csizes | |
*/ | |
#include <stddef.h> | |
#include <stdio.h> | |
#define print_size(type) \ | |
printf("%12s = %zd\n", #type, sizeof(type)); | |
int main(void) { |