This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM archlinux:latest | |
ARG USER | |
# make sure pacman works, also install basic packages: sudo, dbus, systemd | |
RUN curl -s "https://archlinux.org/mirrorlist/?country=DE&country=AT&country=CH&protocol=https&use_mirror_status=on&sort=rate" | sed -e 's/^#Server/Server/' -e '/^#/d' | tee /etc/pacman.d/mirrorlist && \ | |
curl -L https://pkgbuild.com/~morganamilo/pacman-static/x86_64/bin/pacman-static -o /tmp/pacman-static && chmod +x /tmp/pacman-static && pacman-key --init && pacman-key --populate archlinux && \ | |
/tmp/pacman-static -Sy archlinux-keyring pacman-contrib sudo dbus systemd --noconfirm && \ | |
curl -s "https://archlinux.org/mirrorlist/?country=DE&country=AT&country=CH&protocol=https&use_mirror_status=on" | sed -e 's/^#Server/Server/' -e '/^#/d' | rankmirrors -n 5 - | tee /etc/pacman.d/mirrorlist && \ | |
pacman -Syu --noconfirm |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# for new image tags check: https://gitlab.com/islandoftex/images/texlive/container_registry/573747 | |
FROM registry.gitlab.com/islandoftex/images/texlive:TL2024-2025-01-26-full-doc | |
# create a non-root user | |
ARG USERNAME=vscode | |
ARG USER_UID=1000 | |
ARG USER_GID=$USER_UID | |
RUN apt-get update && \ | |
apt-get install -y man sudo openssh-client neovim inkscape zsh tmux && \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# /// script | |
# dependencies = [ | |
# "requests>=2.31.0", | |
# "lxml>=4.9.4", | |
# "pyperclip>=1.8.2", | |
# ] | |
# /// | |
# Inspired by https://maxbarrass.com/blog/2020/04/10/downloading-files-from-rss-with-jdownloader-packegizer%F0%9F%92%BB%F0%9F%92%A5%F0%9F%98%8D | |
# archive link: https://archive.is/rP7Qg |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This one-liner revives an old Arch Linux install where `pacman -Syu` is not working by: | |
# 1. Updating mirror list for DE, AT, CH sorted by rate - ensures access to active and fast mirrors. | |
# 2. Downloading and running static pacman, initializing and populating pacman keyring - re-establishes basic package management capabilities. | |
# 3. Updating archlinux-keyring and pacman-contrib - ensures keyring and essential tools are up-to-date. | |
# 4. Reranking mirror list with the top 5 fastest servers - this is why we needed pacman-contrib. | |
# 5. Running `sudo pacman -Syu --noconfirm` - brings the system to the latest package versions. | |
curl -s "https://archlinux.org/mirrorlist/?country=DE&country=AT&country=CH&protocol=https&use_mirror_status=on&sort=rate" | sed -e 's/^#Server/Server/' -e '/^#/d' | sudo tee /etc/pacman.d/mirrorlist && \ | |
curl -L https://pkgbuild.com/~morganamilo/pacman-static/x86_64/bin/pacman-static -o /tmp/pacman-static && \ | |
chmod +x /tmp/pacman-static && \ | |
sudo pacman-key --init && \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
config, | |
pkgs, | |
options, | |
... | |
}: let | |
hostname = "oatman-pc"; # to alllow per-machine config | |
in { | |
networking.hostName = hostname; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Check if an argument is provided | |
if ($args.Count -eq 0) { | |
Write-Host "No video file provided. Usage: .\script.ps1 [video file]" | |
exit | |
} | |
# Assign the first argument as the input file | |
$inputFile = $args[0] | |
# Check if the file exists |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ######## | |
# # bash # | |
# ######## | |
# pattern="ATLauncher-.*" | |
# repo="Alistair1231/ATLauncher-Offline" | |
# # remove old files | |
# rm -f description.txt && rm -f ATLauncher-*.jar | |
# # get the files | |
# curl -s "https://api.github.com/repos/$repo/releases/latest" | grep -oP '"browser_download_url":\s*"\K[^"]+' | grep -E "$pattern" | wget -q --show-progress -i - |
How to install tikz-uml package on Windows
- console: https://tex.stackexchange.com/questions/69483/create-a-local-texmf-tree-in-miktex
- or gui: https://miktex.org/howto/miktex-console
How to install tikz-uml package on Linux
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# just copy/paste into powershell and edit variables before pressing enter. | |
$user="user"; ` | |
$server="example.com"; ` | |
$port=22; ` | |
$file="id_rsa"; ` | |
type $env:USERPROFILE\.ssh\$file.pub | ssh $user@$server -p $port "mkdir -p ~/.ssh && cat >> .ssh/authorized_keys" |
NewerOlder