← dev

Random references

FFI

Source

Interface that allows code written in one language to call code written in another language

It sits between a program and a library, and handles, at runtime, the differences in ABI and marshalling of data between function calls


Audio


CLI

Remember to turn the term into a raw term

man cfmakeraw

Modify output style with CSI commands, ie:

CSI_CLEAR_ALL "\x1B[0J"
CSI_HIDE_CURSOR "\x1B[?25l"
CSI_SHOW_CURSOR "\x1B[?25h"
CSI_MOVE_TO_TOP_LEFT "\x1B[H"

Some UI Characters:

// ======================= //
// ┌─┬─┐  ╔═╦═╗
// ├─┼─┤  ╠═╬═╣
// │ │ │  ║ ║ ║
// └─┴─┘  ╚═╩═╝
// Reference: https://www.unicode.org/charts/PDF/U2500.pdf
//           0    1    2    3    4    5    6    7    8    9    A    B    C    D    E    F
// U+250x    ─    ━    │    ┃    ┄    ┅    ┆    ┇    ┈    ┉    ┊    ┋    ┌    ┍    ┎    ┏
// U+251x    ┐    ┑    ┒    ┓    └    ┕    ┖    ┗    ┘    ┙    ┚    ┛    ├    ┝    ┞    ┟
// U+252x    ┠    ┡    ┢    ┣    ┤    ┥    ┦    ┧    ┨    ┩    ┪    ┫    ┬    ┭    ┮    ┯
// U+253x    ┰    ┱    ┲    ┳    ┴    ┵    ┶    ┷    ┸    ┹    ┺    ┻    ┼    ┽    ┾    ┿
// U+254x    ╀    ╁    ╂    ╃    ╄    ╅    ╆    ╇    ╈    ╉    ╊    ╋    ╌    ╍    ╎    ╏
// U+255x    ═    ║    ╒    ╓    ╔    ╕    ╖    ╗    ╘    ╙    ╚    ╛    ╜    ╝    ╞    ╟
// U+256x    ╠    ╡    ╢    ╣    ╤    ╥    ╦    ╧    ╨    ╩    ╪    ╫    ╬    ╭    ╮    ╯
// U+257x    ╰    ╱    ╲    ╳    ╴    ╵    ╶    ╷    ╸    ╹    ╺    ╻    ╼    ╽    ╾    ╿
// ======================= //

Latency

Latency Numbers Programmer Should Know


Virtualization

Base components

Clients using libvirt

Linux Hypervisor Setup (libvirt/qemu/kvm)

(same in text)


Vim tricks

Manipulate a file in binary

:%!xxd
// to revert
:%!xxd -r