a wip collection of notes and tips on random things i end up needing to do with my system. i expand it as i encounter new tasks, and hopefully i can consult it instead of looking things up next time.

ssh

config file

put the config file in ~/.ssh/config. now, hosts can be referenced simply by a short name, and all port and user configuration can be managed from this file.

example

Host host-name
  Hostname x.x.x.x
  User user
  IdentityFile ~/.ssh/id_rsa

variations

ssh tunnels with config: https://starkandwayne.com/blog/setting-up-an-ssh-tunnel-with-ssh-config/

ed25519 key

much of this information taken from upgrade your ssh keys

why?

in summary, > DSA and RSA 1024 bit are deprecated now > Increase resistance to brute-force password cracking

generating the new key

ssh-keygen -o -a 100 -t ed25519

this will generate the key to ~/.ssh/id_ed25519

everything else is pretty much the exact same!

restrict to command

in authorized keys, the command option can be used to restrict the user to a single command

desktop

kde

compositor:

  • Compositor can be toggled with Shift+Alt+F12 by default

kwin:

  • KWin can be restarted with `kwin –replace &`, sometimes it's `kwin_x11` instead

  • sometimes fonts in titlebars break, no fix is known other than resetting X

  • compositor can be sped up in Display Settings > Compositor

xdg

default browser

setting default browser using xdg commands (also applies to generally setting default applications)

to set the default browser to Firefox:

xdg-settings set default-web-browser firefox.desktop

to get the current default browser

# get the default web browser
xdg-settings get default-web-browser

laptop

battery

powertop

wip write this section

cpu scaling

using the auto-cpufreq tool https://ol.reddit.com/r/linux/comments/ejxx9f/github_autocpufreq_automatic_cpu_speed_power/ https://github.com/AdnanHodzic/auto-cpufreq (blog post) https://foolcontrol.org/?p=3124 https://ol.reddit.com/r/linux/comments/ejxx9f/github_autocpufreq_automatic_cpu_speed_power/fd4y36k/

dev

vim

run command and append input

:r !command example:

emacs

see emacs

org-mode

see org-mode

git

gitignore whitelisting

information on gitignore whitelisting patterns.

global gitignore

towrite

wine

32-bit wineprefix

  • Use wine like this: WINEPREFIX="$HOME/.wine32" WINEARCH=win32 wine

configurations

xna games
  1. set up a 32-bit prefix

  2. enable wine-mono when prompted

  3. install winetricks packages: dotnet48, xna40

tinc

DigitalOcean tutorial on basic TINC configuration

productivity

calendar

Calendar can be synchronized and accessed through the Khal terminal calendar program | configuration instructions Khal requires vdirsyncer to be set up to read from CalDAV calendars. Google Calendar provides a CalDAV API that needs to be enabled to access calendars through this protocol to allow syncing.

email

TOWRTE

unix

users

add user to group

on arch:

sudo gpasswd -a xdrie docker

on ubuntu:

sudo usermod -aG docker xdrie

cron

edit crontab

edit crontab for a particular user. to edit the system wide crontab, use sudo.

crontab -e

fields

this stackoverflow post explains the format of crontab entries.