|
HanOS 0.1.2.261108
Target for a production-grade OS
|
HanOS targets x86-64 and is written in C. The filesystem, pipes, terminal, and block driver run as userspace servers. The servers communicate over a small IPC layer.
Current features:
ls, cat, wc, pwd, rm, echo, edit, dmesg, usb, and lspci.tetris, 2048, and snake from the shell.A local build needs an x86_64-elf cross toolchain plus:
nasm, xorriso, perl, curl, git, build-essentialmtools, gdisk (sgdisk), e2fsprogs for release/hdd.imgqemu-system-x86 for make runClone Limine, then build and run:
make run-hdd boots the disk image. It needs mtools and sgdisk.
The CI does not install a cross toolchain. It defines x86_64-elf-gcc as gcc -fno-pie on Ubuntu 24.04 and builds with the host compiler.
See 3rdparty/musl/README.md for the musl build.
Programs live in the initrd and on the ext2 data partition. The shell looks in /bin and then /data/bin, so a name runs from any directory. The live USB image and make run-hdd use the same layout.
tetris: stack the falling pieces and clear lines.2048: merge equal tiles and reach 2048.snake: eat the $ food, grow, and avoid the walls and your tail.| Game | Keys |
|---|---|
tetris | A/D or arrows move; W/Up rotate; S/Down soft drop; Space hard drop; P pause; Q quit |
2048 | W/A/S/D or arrows move; R restart; Q quit |
snake | W/A/S/D or arrows turn; P pause; Q quit |
ls, cat, wc, pwd, rm, echo, editdmesg [keyword...], usb, lspcihelp, hanshTested physical machines:
QEMU covers BIOS and UEFI boot, AHCI disks, and EHCI/xHCI USB storage.
Known limits:
See attic/2026/2026-10-22-gen75-edp-and-edid-en.md for the graphics work. See attic/2026/2026-10-18-haswell-usb2-ports-en.md for the USB work.
Three GitHub Actions workflows live in .github/workflows/:
build.yml runs on every push and pull request on ubuntu-24.04. It installs the build tools and QEMU, defines x86_64-elf-gcc as gcc -fno-pie, builds the kernel, userspace, cdrom.iso and release/hdd.img, then boots the ISO under QEMU 8.2 with TCG. scripts/ci-boot-test.sh waits for the shell and the boot markers name "hansh" or name "bash", MK: selftest PASS, MK: misc PASS and MK: signalfd PASS. A missing marker or a panic, exception or corrupt line fails the job. A passing run prints the serial log.doxygen-pages.yml runs on a push to mainline, generates the Doxygen HTML and deploys it to GitHub Pages.main.yml regenerates the line-count badge on the image-data branch.Hosted runners have no /dev/kvm, so the boot test uses TCG. Local make run uses KVM.
doxygen Doxyfile generates the HTML docs.