commit 5704bd7ff4067e0ae0ed51f9f87a36f739fca28c Author: Padreug Date: Sun Jun 28 06:48:06 2026 +0200 chore: project scaffold — license, gitignore, build meta, issue templates Co-Authored-By: Claude Opus 4.8 diff --git a/.git-blame-ignore-revs b/.git-blame-ignore-revs new file mode 100644 index 0000000..85f51bf --- /dev/null +++ b/.git-blame-ignore-revs @@ -0,0 +1,4 @@ +# Migrations / mass-reformats — keep `git blame` readable across these. + +# Mass-format with nixfmt (RFC 166). Replaced nixpkgs-fmt. +bf03fd06d11cad2e349749082615c7a993d596f2 diff --git a/.github/ISSUE_TEMPLATE/bug.yml b/.github/ISSUE_TEMPLATE/bug.yml new file mode 100644 index 0000000..ae5d17d --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug.yml @@ -0,0 +1,23 @@ +name: Bug +description: Report a problem +labels: [bug] +body: + - type: markdown + attributes: + value: | + Remember: Omarchy is an open source gift, not a product you bought from a vendor + + - type: input + id: system-details + attributes: + label: System details + placeholder: e.g. AMD 9950X, NVIDIA 5090, Omarchy 2.1.0 + validations: + required: true + + - type: textarea + id: steps + attributes: + label: What's wrong? + validations: + required: true diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 0000000..3ba13e0 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1 @@ +blank_issues_enabled: false diff --git a/.github/ISSUE_TEMPLATE/documentation.yml b/.github/ISSUE_TEMPLATE/documentation.yml new file mode 100644 index 0000000..33edaea --- /dev/null +++ b/.github/ISSUE_TEMPLATE/documentation.yml @@ -0,0 +1,15 @@ +name: Documentation +description: New pages or changes to existing +labels: [documentation] +body: + - type: markdown + attributes: + value: | + Remember: Omarchy is an open source gift, not a product you bought from a vendor + + - type: textarea + id: steps + attributes: + label: What correction or addition do we need? + validations: + required: true diff --git a/.github/ISSUE_TEMPLATE/enhancement.yml b/.github/ISSUE_TEMPLATE/enhancement.yml new file mode 100644 index 0000000..b640c39 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/enhancement.yml @@ -0,0 +1,15 @@ +name: Enhancement +description: Feature or change +labels: [enhancement] +body: + - type: markdown + attributes: + value: | + Remember: Omarchy is an open source gift, not a product you bought from a vendor + + - type: textarea + id: steps + attributes: + label: What do you need? + validations: + required: true diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..50dca1d --- /dev/null +++ b/.gitignore @@ -0,0 +1,138 @@ +# Reference directories +./omarchy_ref/* +./omarchy/ + +# Nix build outputs +result +result-* +*.drv + +# ISO and disk images +*.iso +*.qcow2 +*.img +*.vdi +*.vmdk + +# Build artifacts +*.o +*.so +*.a +*.out +build/ +dist/ +target/ + +# Temporary files +*.tmp +*.temp +*.swp +*.swo +*~ +.#* +\#*# + +# System files +.DS_Store +Thumbs.db +desktop.ini + +# Editor and IDE files +.vscode/ +.idea/ +*.iml +.project +.classpath +.settings/ +*.sublime-* + +# Vim +*.vim +.vim/ +Session.vim +.netrwhist + +# Emacs +*~ +\#*\# +/.emacs.desktop +/.emacs.desktop.lock +*.elc +auto-save-list +tramp +.\#* + +# Backup files +*.bak +*.backup +*.old + +# Log files +*.log +logs/ +*.log.* + +# Cache directories +.cache/ +cache/ +__pycache__/ +*.pyc + +# Environment files +.env +.env.local +.env.*.local + +# SSH keys and secrets +*.key +*.pem +id_rsa +id_rsa.pub +# secrets/ tracks sops-encrypted yaml files (declared in .sops.yaml). +# Plaintext leaks are gated by the pre-commit secret scanner; the +# generic *.key / *.pem rules above still keep raw key material out. +secrets/* +!secrets/*.yaml +!secrets/*.example +!secrets/README.md + +# Large media files +*.mp4 +*.avi +*.mov +*.mkv +*.zip +*.tar.gz +*.tar.xz +*.7z +*.rar + +# Node modules (if any JavaScript projects) +node_modules/ + +# Python virtual environments +venv/ +.venv/ +env/ +.env/ + +# Rust +Cargo.lock + +# Go +vendor/ +go.sum + +# Claude Code +.claude/ + +# Hardware configuration (system-specific). +# Tracked per-host at hosts//hardware-configuration.nix. A stray +# root-level file — e.g. nixos-generate-config writing to /etc/nixos — +# is ignored (root-anchored) so it isn't committed by accident; move it +# into your host directory instead. +/hardware-configuration.nix + +# Nix direnv +.direnv/ +.envrc \ No newline at end of file diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..f12cfa7 --- /dev/null +++ b/LICENSE @@ -0,0 +1,20 @@ +Copyright (c) David Heinemeier Hansson + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..eaa92e6 --- /dev/null +++ b/Makefile @@ -0,0 +1,92 @@ +# Top-level Makefile for nixos-dev-setup / omni. +# +# Wraps nixos-rebuild + cachix + flake update so common operations are +# one command instead of one paragraph. Adapted from mitchellh's +# Makefile but trimmed: +# +# - No vm/bootstrap targets — those are handled by `dev-env-bootstrap` +# for the dev box and by `dev-deploy` for the fleet. +# - No darwin/wsl targets — we don't run those (yet). +# - HOST defaults to `hostname` so `make switch` Just Works on the +# box you're sitting at. +# +# Override anything via env or args: +# +# make switch HOST=host1 +# make cache CACHE=aiolabs-nix +# make build FLAKE=/path/to/some/flake + +HOST ?= $(shell hostname) +CACHE ?= aiolabs-nix +FLAKE ?= . + +# Always allow unfree — most of our hosts need at least one unfree +# package (e.g. claude-code, vscode). Set in env so child processes +# inherit it (cachix push uses nix-store under the hood). +NIXPKGS_ALLOW_UNFREE := 1 +export NIXPKGS_ALLOW_UNFREE + +.PHONY: help +help: + @echo "Usage: make [HOST=] [CACHE=] [FLAKE=]" + @echo "" + @echo "Targets:" + @echo " switch nixos-rebuild switch on the local host" + @echo " test nixos-rebuild test (no boot entry change)" + @echo " build nix build the host's toplevel (no switch)" + @echo " update nix flake update" + @echo " cache push the host's closure to \$$CACHE" + @echo " check nix flake check" + @echo " clean nix-collect-garbage -d (system + user)" + @echo " fmt nixfmt every .nix file in the tree" + @echo " shellcheck shellcheck every .sh file in the tree" + @echo "" + @echo "Variables (current values):" + @echo " HOST = $(HOST)" + @echo " CACHE = $(CACHE)" + @echo " FLAKE = $(FLAKE)" + +.PHONY: switch +switch: + sudo nixos-rebuild switch --flake $(FLAKE)#$(HOST) + +.PHONY: test +test: + sudo nixos-rebuild test --flake $(FLAKE)#$(HOST) + +.PHONY: build +build: + nix build $(FLAKE)#nixosConfigurations.$(HOST).config.system.build.toplevel + +.PHONY: update +update: + nix flake update --flake $(FLAKE) + +# Push the local host's closure to the cache. Requires `cachix` and +# `jq` on PATH and a configured authtoken (`cachix authtoken `). +.PHONY: cache +cache: + nix build $(FLAKE)#nixosConfigurations.$(HOST).config.system.build.toplevel --json \ + | jq -r '.[].outputs | to_entries[].value' \ + | cachix push $(CACHE) + +.PHONY: check +check: + nix flake check $(FLAKE) + +.PHONY: clean +clean: + sudo nix-collect-garbage -d + nix-collect-garbage -d + +# Format every .nix file. Requires nixfmt on PATH (in nixpkgs). +.PHONY: fmt +fmt: + @find . -name '*.nix' -not -path './.git/*' -print0 \ + | xargs -0 -r nixfmt + +# Lint every .sh file. Requires shellcheck on PATH (in nixpkgs). +.PHONY: shellcheck +shellcheck: + @find . -name '*.sh' -not -path './.git/*' -print0 \ + | xargs -0 -r shellcheck