Skip to content

Instantly share code, notes, and snippets.

View plembo's full-sized avatar

Phil Lembo plembo

View GitHub Profile
@plembo
plembo / useicsp.md
Last active March 2, 2025 21:11
icsp ics to tsv converter in bash

icsp: a ICS to TSV converter

Alexandre Lotte, the author of icsp describes it as a "Small, fast and simple command-line tool to conver calendar exports (.ics files) into TSV/CSV files for easy analysis and usage in broader use-cases."

And so it is.

I had accidentally imported a holiday calendar into my default Proton Calendar, when I realized two very horrible things: (1) I had no backup; and (2) no one really provides tools for removing entries from calendars in bulk. Later, I would add "Proton Calendar doesn't have a versioning system". But then, no one else does either.

I was screwed.

A few minutes (OK, about a half hour) of searching the Internet, and I found icsp: which turned out to be everything its author wrote that it is.

@plembo
plembo / customvivaldidesk.md
Last active December 16, 2024 19:01
Customizing Vivaldi for Desktop

Custom settings for Vivaldi browser on the desktop

This is a relatively short list for a reason: at least as of version 7, Vivaldi's default settings are reasonably secure, private AND ergonomic. Note that the settings available for the mobile versions of Vivaldi differ considerably from those in the desktop versions.

Also keep in mind that I'm currently using four extensions with Vivaldi on my desktops: uBlock Origin Lite, Bitwarden password manager, Raindrop bookmark manager, and Dark Reader to apply dark mode to web pages.

Only my changes to the defaults appear below.

  • General > Homepage > Specific Page > your favorite homepage
  • General > Startup with > Homepage
@plembo
plembo / onenonrootpodman.md
Last active January 17, 2025 19:57
One non-root podman user to rule them all

One (non-root) podman account to rule them all

NOTE: This was written while I was experimenting with using podman in lieu of docker, something I've finally returned to. Not all docker images are compatible with podman, and some still require root even under podman. Approach with fear and trembling (and a willingness to do your own research).

Going rootless is one of the main reasons for switching to podman. But if you're running shared services on server for internal users and don't want a separate account for each app, creating a special (non-privileged) account for all pods may be the answer.

This work was done on Ubuntu 22.04 LTS using the shipping Ubuntu package for podman (podman-3.4.4+ds1-1ubuntu1).

Prerequisites

Install podman and enable the podman.socket service (I'm using the version in my distro's official repository):

@plembo
plembo / autopodonreboot.md
Last active November 9, 2024 19:02
Automatically start pod on reboot

Auto start podman containers on reboot as systemd services

NOTE: This was written while I was experimenting with using podman in lieu of docker, something I'm now looking at again. Not all docker images work with podman, so be prepared to struggle with the system and to engage in many fruitless Internet searches.

Intro

OK, so who knew podman containers won't automatically start on reboot? Yeah. Me neither.

Found out after a family member complained about getting a 500 error when trying to reach a PiGallery2 instance I had set up on the home server.

Fixing this is easy, as detailed in Pratham Patel's "How to Autostart Podman Containers?" over on Linux Handbook: A systemd servic

@plembo
plembo / bravesettings.md
Last active January 31, 2025 21:18
My preferred settings for the Brave browser

Settings Changes for Brave Browser

These settings choices follow the advice on Privacy Guides for Brave, except where they don't. And yes, these were my personal preferences: no judgement if someone disagrees. NOTE: I no longer use Brave.

Brave Shields are disabled in favor of uBlock Origin Lite for tracker and ad blocking.

Here is my modified list of changes beyond Brave's defaults:

Appearance

  • Appearance > Brave colors - Dark
  • Appearance > Theme - Classic
@plembo
plembo / fixdockautohide.md
Last active August 21, 2024 16:51
fix dock will not reappear after auto-hide ubuntu 22.04 desktop

Fix dock won't reappear after auto-hide

Running Ubuntu 22.04 LTS with Ubuntu Desktop on X11.

Problem

After setting dock (dash to dock extension) to auto-hide, it won't reappear if any app is full screen.

Solution

Turn off "require-pressure-to-show" in dconf settings for dock.

  1. Open dconf-editor and go to org > gnome > shell > exensions > dash-to-dock
@plembo
plembo / fixphantomdisplayubu.md
Last active February 18, 2025 15:45
phantom unknown display in ubuntu with nvidia

Workaround for "Phantom Unknown Display"

UPDATE: According to the Ubuntu bug history cited below, this problem was fixed with an update of ubuntu-drivers-common on September 10, 2024. After removing the workaround udev rule and verifying the package was updated on my system, I confirmed that the troublesome behavior didn't return for me. That said, at least one other person has advised that they're still experiencing it even with the workaround.

Got bit by Ubuntu Linux bug #2060268 on the latest kernel update for 22.04 LTS (6.8.0-40-generic).

As in the bug report (and many forum posts across the Internet) this appears to be due to a collision between the simpledrm kernel module and NVIDIA drivers. The symptom is a nonexistent display device being assigned as card0. The practical effect is to throw off any previous configuration of the display system (display 1 becoming display 2, display 2 becoming display 3). As a result, customization

@plembo
plembo / chromeandroidsettings.md
Last active December 16, 2024 19:03
Google Chrome on Android settings

Google Chrome on Android settings

My preferred settings for Google Chrome on Android:

Updated for version 127.0.6533.64

You and Google

  • DO NOT turn on sync, or Disable

Basics

  • Search engine: Your Favorite Search Engine
  • Google Password Manager: Settings - Disable all
@plembo
plembo / chromesetchecklist.md
Last active December 16, 2024 19:04
Google Chrome desktop settings checklist

Google Chrome desktop settings

Following are my preferred settings for Google Chrome desktop (Updated for version 127.0.6533.88):

You and Google

  • User Profile: No change
  • Sync and Google Services: Disable all

Autofill and passwords

  • Google Password Manager: Settings - Disable all
@plembo
plembo / tpmsecbootwinkvm.md
Last active April 25, 2024 14:37
KVM libvirt qemu tpm secure boot Windows install

TPM and Secure Boot for Windows 11 guests on KVM

The latest KVM on Ubuntu Desktop 22.04 supports both TPM2.0 and Secure Boot for Windows 11 guests. To use it you'll need to make sure the ovmf package is installed.

If using Virtual Machine Manager (VMM, or virt-manager) to install Windows 11 from a Microsoft iso, be sure to check "Customize configuration before install" before clicking on the "Finish" button. While VMM will automatically detect the operating system version and customize many things, including TPM, it will not choose the correct setting for Secure Boot.

When you get to the VM's configuration screen in VMM, you'll find that a TPM vNone device has already been added. Setting up Secure Boot properly will require manually selecting the correct firmware. To do that:

  1. Select Overview