Skip to content

Instantly share code, notes, and snippets.

@kepano
kepano / obsidian-web-clipper.js
Last active June 1, 2024 22:19
Obsidian Web Clipper Bookmarklet to save articles and pages from the web (for Safari, Chrome, Firefox, and mobile browsers)
javascript: Promise.all([import('https://unpkg.com/turndown@6.0.0?module'), import('https://unpkg.com/@tehshrike/readability@0.2.0'), ]).then(async ([{
default: Turndown
}, {
default: Readability
}]) => {
/* Optional vault name */
const vault = "";
/* Optional folder name such as "Clippings/" */
@yorickdowne
yorickdowne / README.md
Last active May 25, 2024 08:31
Ubuntu Desktop 20.04 with mirrored ZFS boot drive

Ubuntu 24.04

From the comments: "These exact instructions are not working on Ubuntu 24.04. Ubuntu has changed the naming of ZFS partitions, partition 2 and 3 are switched around, and the boot/efi folder is now different."

I don't have my dual-disk test system any longer, and so can't adjust these steps myself.

Overview

Ubuntu Desktop 20.04 supports a single ZFS boot drive out of the box. I wanted a ZFS mirror, without going through an entirely manual setup of Ubuntu as described by OpenZFS in their instructions for Ubuntu 20.04 and instructions for Ubuntu 22.04

@GrumpyChunks
GrumpyChunks / fixpopclock.sh
Last active April 15, 2023 12:24
Fix for Pop_OS not correctly using the 24 hour clock when the locale is set to a timezone that should default to a 24 hours clock
#!/bin/bash
sudo sed -i "/\[org\/gnome\/desktop\/interface\]/a\clock-format=\'24h\'" /etc/gdm3/greeter.dconf-defaults
gsettings set org.gtk.Settings.FileChooser clock-format 24h
gsettings set org.gnome.desktop.interface clock-format 24h
@andersevenrud
andersevenrud / alacritty-tmux-vim_truecolor.md
Last active May 31, 2024 07:00
True Color (24-bit) and italics with alacritty + tmux + vim (neovim)

True Color (24-bit) and italics with alacritty + tmux + vim (neovim)

This should make True Color (24-bit) and italics work in your tmux session and vim/neovim when using Alacritty (and should be compatible with any other terminal emulator, including Kitty).

Testing colors

Running this script should look the same in tmux as without.

curl -s https://gist.githubusercontent.com/lifepillar/09a44b8cf0f9397465614e622979107f/raw/24-bit-color.sh >24-bit-color.sh
@MHM5000
MHM5000 / BSG-Watch-order.md
Last active August 13, 2023 10:47
Battlestar Galactica watch order

Source 1 Source 2

به ترتیب ساخت و پخش

Production Order

The show's production order is probably the best viewing order as well, since this is the order the series originally aired in and is what most people viewed the series in. This also best protects later spoilers and crucial plot revelations.

@0xmachos
0xmachos / multi_pihole.md
Created June 15, 2018 12:44
How to configure two Pi-holes on the same network

Multiple Pi-holes

In this scenario we are configuring two Pi-holes running on the same network. pihole0 is the main DNS server while pihole1 is the secondary.

  • pihole0
    • 192.168.1.4
    • http://pi.hole0/admin/
  • pihole1
    • 192.168.1.5
  • http://pi.hole1/admin/