Skip to content

Instantly share code, notes, and snippets.

@technoscavenger
technoscavenger / init.el
Created June 3, 2026 05:19
SLIME init.el
;;; -*- lexical-binding: t -*-
(custom-set-variables
;; custom-set-variables was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
'(package-selected-packages '(slime)))
(custom-set-faces
;; custom-set-faces was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
@technoscavenger
technoscavenger / .emacs
Created May 28, 2026 15:22
.emacs for SLY SBCL
;;; -*- lexical-binding: t -*-
(custom-set-variables
;; custom-set-variables was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
'(package-selected-packages '(sly)))
(custom-set-faces
;; custom-set-faces was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
@technoscavenger
technoscavenger / init.el
Last active May 27, 2026 03:46
SBCL init.el on Windows 10
(require 'package)
(add-to-list 'package-archives '("melpa" . "https://melpa.org/packages/") t)
(setq sly-lisp-implementations
'((sbcl ("c:/Program Files/Steel Bank Common Lisp/sbcl.exe"))))
(setq sly-default-lisp 'sbcl)
(require 'sly)
@technoscavenger
technoscavenger / build.zig
Created January 27, 2026 20:02
Build.zig for Hello Window
const std = @import("std");
// Although this function looks imperative, it does not perform the build
// directly and instead it mutates the build graph (`b`) that will be then
// executed by an external runner. The functions in `std.Build` implement a DSL
// for defining build steps and express dependencies between them, allowing the
// build runner to parallelize the build automatically (and the cache system to
// know when a step doesn't need to be re-run).
pub fn build(b: *std.Build) void {
// Standard target options allow the person running `zig build` to choose
@technoscavenger
technoscavenger / main.zig
Last active January 27, 2026 20:00
Hello Window using Zig lang
pub const UNICODE = true;
const win32 = @import("win32").everything;
const L = win32.L;
const HWND = win32.HWND;
pub export fn wWinMain(
hInstance: win32.HINSTANCE,
_: ?win32.HINSTANCE,
pCmdLine: [*:0]u16,
nCmdShow: u32,
@technoscavenger
technoscavenger / qt-console.cpp
Created September 22, 2025 01:55
Qt Console app
#include <QCoreApplication>
#include <QTextStream>
int main(int argc, char *argv[])
{
QCoreApplication a(argc, argv);
QTextStream(stdout) << "Hello, world\n";
return a.exec();
}
@technoscavenger
technoscavenger / highlight-sample.html
Created September 10, 2025 06:18
highlight sample code
<pre><code class="language-bash">netsh advfirewall firewall add rule name="RPC Endpoint Mapper" dir=in action=allow protocol=TCP localport=135
</code></pre>
@technoscavenger
technoscavenger / highlight-blogger.html
Last active September 10, 2025 06:15
Highlight.js Blogger modification
<link href='https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.11.1/styles/default.min.css' rel='stylesheet'/>
<script src='https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.11.1/highlight.min.js'/>
<script type='text/javascript'>
hljs.configure({cssSelector: &quot;code&quot;});
hljs.highlightAll();
</script>
<script type='text/javascript'>
//<![CDATA[
@technoscavenger
technoscavenger / _etc_netplan_01-netcfg.yaml
Created May 8, 2025 03:07
netplan yaml for configuring bridge and tap0
network:
version: 2
renderer: networkd
ethernets:
ens33:
dhcp4: no
dhcp6: no
tap0:
optional: true
bridges:
@technoscavenger
technoscavenger / tap0.service
Created May 8, 2025 03:00
systemd unit for creating tap0
[Unit]
Description=Create TAP interface tap0
Before=network-pre.target
Wants=network-pre.target
DefaultDependencies=no
[Service]
Type=oneshot
ExecStart=/sbin/ip tuntap add dev tap0 mode tap user u1
ExecStartPost=/sbin/ip link set tap0 up