Skip to content

Instantly share code, notes, and snippets.

View alembiq's full-sized avatar

Karel alembiq

  • ALEMBIQ.net
  • Prague, CZ
View GitHub Profile
@chrisswanda
chrisswanda / Remove SSH key from GPG agent keyring.txt
Created May 12, 2020 11:59
Remove SSH key from GPG agent keyring
keys=$(gpg-connect-agent 'keyinfo --list' /bye | awk '{print $3}')
for key in $keys; do gpg-connect-agent "delete_key $key --force" /bye; done
@blurgyy
blurgyy / nixos-iso-bootstrap.sh
Last active March 27, 2025 21:38
Enable zram and larger nix store in a NixOS live ISO environment
#!/usr/bin/env bash
# Run this as root
zram_size=2G
if [[ "$#" -gt 0 ]]; then
zram_size="$1"
fi
# Enable zram swap
@sebastiancarlos
sebastiancarlos / show_notifications.bash
Last active July 23, 2024 08:43
Show notifications in your terminal
# All my gist code is licensed under the terms of the MIT license.
# Video demo: https://www.youtube.com/shorts/WVyqVkGYb4k
# Add this somewhere in ~/.bashrc
# write_message
# - write a message on the lower right corner of the terminal
function write_message () {
if [[ "$#" -eq 0 ]]; then