Skip to content

Instantly share code, notes, and snippets.

@haruhi-s
haruhi-s / init.el
Created December 2, 2024 19:00
.emacs.d
;; bootstrap straight
(defvar bootstrap-version)
(let ((bootstrap-file
(expand-file-name
"straight/repos/straight.el/bootstrap.el"
(or (bound-and-true-p straight-base-dir)
user-emacs-directory)))
(bootstrap-version 7))
(unless (file-exists-p bootstrap-file)
(with-current-buffer
@haruhi-s
haruhi-s / .sbclrc
Created December 5, 2024 19:47
sbcl config
;;; The following lines added by ql:add-to-init-file:
#-quicklisp
(let ((quicklisp-init (merge-pathnames "quicklisp/setup.lisp"
(user-homedir-pathname))))
(when (probe-file quicklisp-init)
(load quicklisp-init)))
(ql:quickload '("numcl" "alexandria" "serapeum" "iterate" "trivia" "str" "metabang-bind"))
@haruhi-s
haruhi-s / sheep.cpp
Last active February 21, 2026 13:32
g++ -O2 sheep.cpp
#include <bits/stdc++.h>
#include <fcntl.h>
#include <sys/mman.h>
#include <sys/select.h>
#include <sys/stat.h>
#include <termios.h>
#include <unistd.h>
using namespace std;
struct MmapFile {