Skip to content

Instantly share code, notes, and snippets.

@copy
copy / Dockerfile
Last active February 20, 2021 20:02
FROM i386/alpine:latest
# https://wiki.gentoo.org/wiki/OpenRC/Baselayout_1_to_2_migration#Boot_runlevel
# https://wiki.alpinelinux.org/wiki/Installing_Alpine_Linux_in_a_chroot#Entering_your_chroot
RUN apk update && \
apk upgrade && \
apk add --no-cache linux-vanilla vim openrc && \
rc-update add devfs sysinit && \
rc-update add root boot && \
@copy
copy / jbuild
Created October 30, 2017 19:32
Expect tests
(library
((name foo)
(modules foo)
(library_flags (-linkall))
(libraries (ppx_inline_test.runtime-lib ppx_expect.collector))
(preprocess (pps (ppx_jane ppx_driver.runner)))))
(executable
((name test_runner)
(modules (test_runner))
[
structure_item (test.ml[8,78+0]..[13,135+17])
Pstr_value Nonrec
[
<def>
pattern (test.ml[8,78+4]..[8,78+5])
Ppat_any
expression (test.ml[9,86+2]..[13,135+17])
Pexp_apply
expression (test.ml[9,86+2]..[13,135+17])
[
structure_item (test.ml[1,0+0]..[4,53+17])
Pstr_value Nonrec
[
<def>
pattern (test.ml[1,0+4]..[1,0+5])
Ppat_any
expression (test.ml[2,8+2]..[4,53+17])
Pexp_let Nonrec
[
### Keybase proof
I hereby claim:
* I am copy on github.
* I am copy (https://keybase.io/copy) on keybase.
* I have a public key whose fingerprint is 2EDC CE9E 18CB 62BE 1915 0A75 DA3D 3B2C C720 A253
To claim this, I am signing this object:
(gdb) disass camlCCEqual__int_1201
Dump of assembler code for function camlCCEqual__int_1201:
0x0000000000402650 <+0>: sub rsp,0x8
0x0000000000402654 <+4>: mov rdi,rax
0x0000000000402657 <+7>: mov rsi,rbx
0x000000000040265a <+10>: mov rax,0x40a4a0
0x0000000000402661 <+17>: call 0x419870 <caml_c_call>
0x0000000000402666 <+22>: mov r11,0x62c3e8
0x000000000040266d <+29>: mov r15,QWORD PTR [r11]
0x0000000000402670 <+32>: add rsp,0x8
root@alix /% shutdown -h 0
nope -h 0
(* XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX *)
let to_visible (t : t) : t_visible = Obj.magic t
let of_visible (t_visible : t_visible) : t = Obj.magic t_visible
(* XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX XXX *)
open Solvuu_build.Std
let project_name = "test"
let myapp = Project.app project_name
~thread:()
~safe_string:()
~bin_annot:()
~short_paths:()
~g:()
(*
ocamlbuild \
-pkg containers \
-pkg lwt \
-pkg yojson \
-pkg conduit.lwt-unix \
-pkg nocrypto \
-pkg nocrypto.unix \
-pkg websocket.lwt \
-cflags "-w A-4-40-41-42-44" \