Skip to content

Instantly share code, notes, and snippets.

View phanirithvij's full-sized avatar
💫
you spin my head right round ..

Phani Rithvij phanirithvij

💫
you spin my head right round ..
  • 15:54 (UTC +05:30)
View GitHub Profile
@getchoo
getchoo / pacman-vm.nix
Created September 23, 2024 22:23
nix build -f pacman-vm.nix config.system.build.vm && ./result/bin/run-nixos-vm
/*
Once in the VM, you will also need to setup pacman's keyring, which you can do with the following:
```
curl -Lo archlinux-keyring.tar.zst https://archlinux.org/packages/core/any/archlinux-keyring/download
tar -xf archlinux-keyring.tar.zst
sudo pacman-key --init
sudo pacman-key --populate --populate-from usr/share/pacman/keyrings/
```
*/
@roberth
roberth / minimod.nix
Last active March 11, 2025 00:52
Simple and quick module system alternative + thoughts and tasks
/*
minimod: A stripped down module system
TODO Comparison:
- [ ] Come up with a benchmark "logic" using plain old functions and let bindings
- [ ] Write the benchmark for the module system
- [ ] Write the benchmark for POP?
- [ ] Qualitative comparison of extensibility in the context of composable
Nixpkgs packaging logic
TODO Fine-tuning:
use std::io;
use std::io::Write;
use std::fs::File;
use std::process::Command;
#[derive(Debug, Clone, Copy)]
enum DataType {
Int,
Ptr,
Bool,
@corlaez
corlaez / README.md
Last active March 18, 2025 15:33
Hexagonal Architecture and Modular Implementation

Hexagonal Architecture

Conceptualized by Alistair Cockburn. Also known as "Ports and Adapters".

In a nutshell:

Application Driver -> Primary Adapter -> Primary Port -> Use Case -> Secondary Port -> Secondary Adapter -> External System/Side Effect
@nothub
nothub / info.txt
Last active February 20, 2023 13:40
updated asciiquarium
This project has moved to: https://github.com/nothub/asciiquarium
@ppoffice
ppoffice / README.md
Last active April 16, 2025 04:30
Install Visual Studio Code (actually code-server) on Android
  1. Install Termux, an Android terminal emulator that provides a Linux execution environment and various tools.

  2. Update system packages in Termux:

    $ pkg update -y
@kostix
kostix / get-fixed-volume-mounts.go
Created July 9, 2020 19:51
Getting the list of fixed volumes and their mounts
package main
import (
"errors"
"log"
"strings"
"syscall"
"unsafe"
)
@onlurking
onlurking / programming-as-theory-building.md
Last active March 28, 2025 02:18
Programming as Theory Building - Peter Naur

Programming as Theory Building

Peter Naur

Peter Naur's classic 1985 essay "Programming as Theory Building" argues that a program is not its source code. A program is a shared mental construct (he uses the word theory) that lives in the minds of the people who work on it. If you lose the people, you lose the program. The code is merely a written representation of the program, and it's lossy, so you can't reconstruct

@makew0rld
makew0rld / go-build-all.sh
Last active April 26, 2024 09:51
Cross compile for all possible Golang targets. This script will always be updated, because it uses the `go` command to see what can be built.
#!/usr/bin/env bash
# Based on https://gist.github.com/eduncan911/68775dba9d3c028181e4
# but improved to use the `go` command so it never goes out of date.
type setopt >/dev/null 2>&1
contains() {
# Source: https://stackoverflow.com/a/8063398/7361270
[[ $1 =~ (^|[[:space:]])$2($|[[:space:]]) ]]
@Zeinok
Zeinok / wine-breeze-dark-theme.md
Last active April 12, 2025 07:27
Breeze Dark theme for Wine

Made possible with this reddit post.

Install

wine regedit wine-breeze-dark.reg

Uninstall (Reset Wine color scheme)

wine regedit wine-reset-theme.reg