Dup Ver Goto 📝

My Kubuntu Setup Notes

To
171 lines, 750 words, 4846 chars Page 'Kubuntu2204a' does not exist.

This is an assorted bunch of notes I made while setting up a new laptop with kubuntu (well sold 'for parts' on eBay and nursed back to health, previously having hat Rocky but after the RHEL debacle I'm done with RH stuff...) I thought to write down everything I did during installation. Some of these things depend on personal files I have access to, but in any case it is an illustration of what I'll do to configure a system for 'fun' (that is, low security).

Health warning: some of these settings are for convenience, and on machines where security is not a major concern. A spare laptop running Linux for fun and educational value needn't have the same degree of security as a machine on which things like sensitive financial documents are stored.

Note for general readers Some of my notes and stuff are on private pages or github repos. What is here is stuff I'm happy to share.

Install

# as root

# make sudo easier -- don't do this where security matters
echo ALL ALL = NOPASSWD: ALL > /etc/sudoers.d/wideopen

# disable and stop unattended-upgrades as it can interfere with apt-get
systemctl disable unattended-upgrades
systemctl stop unattended-upgrades

Install UsualAptPackages

System Monitoring

There are a few utilities that improve on top (source: itsfoss).

  1. htop
  2. atop
  3. nmon
  4. vtop
  5. bashtop
  6. gtop
  7. glances

Install Chrome

Chrome

wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb && \
sudo dpkg -i google-chrome-stable_current_amd64.deb

Log in, get tampermonkey scripts.

Nvm

Get nvm from https://github.com/nvm-sh/nvm: install via

curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.3/install.sh | bash

Add path to point to current nvm version (else we have to run nvm before we can run node and npm)

Tmux

Get .tmux.conf: currently

setw -g mode-keys vi
bind-key -n C-Left previous-window
bind-key -n C-Right next-window
bind-key -n C-S-Left switch-client -p
bind-key -n C-S-Right switch-client -n
bind-key -n C-M-Left select-pane -L
bind-key -n C-M-Right select-pane -R
bind-key -n C-M-Up select-pane -U
bind-key -n C-M-Down select-pane -D

Get mdview from https://github.com/mapitman/mdview/

curl -L -O https://github.com/mapitman/mdview/releases/download/1.5.0/mdview_1.5.0_amd64.deb && \
sudo dpkg --install mdview_1.5.0_amd64.deb

Mpd

Put music in /data/music. Copy .mpd/conf from music-server. Create .mpd/playlists.

Settings

Copy in ssh config and mygit. Get hosts from allsup.co. In mygit/myvim run install.sh Get nvim config from version control.

Nvim

For the IDE like setup, use a separate nvim app. Clone config from my_nvim2

My stuff

Make /usr/jda, git clone cmds, then install.sh. Edit /etc/sudoers to add /usr/jda/bin to the path.

Rust

See Rust_Setup

KDE Setup

See KDE_Plasma

Python

See Python_Setup

Samba

See Samba_Setup

Dircolors

Change other writable to make it readable text (I make it red on black)

OTHER_WRITABLE 1;4;31;40 # dir that is other-writable (o+w) and not sticky

Use dircolors -p to print database to a file, then edit, then

eval "$(dircolors <filename>)"

If this is dumped in ~/.dircolors then dircolors.stuff will take care of this.

Fonts

Adobe fonts. Nerd fonts.

SSH

Enable user_allow_other in /etc/fuse.conf so that sshfs doesn't restrict to one user. This is useful when e.g. running an installer with sudo where the file is on a remote system mounted by a user via sshfs.

Profiles

Create mydef with Linux Colors and Hack Nerdfont

vim

get mygit and my_nvim2 from git repo

apache2

a2enmod rewrite

Ensure php takes priority over html: edit mods-enabled/dir.conf

        DirectoryIndex index.php index.html index.cgi index.pl index.xhtml index.htm

XCompose

Enable compose key in systemsettings (input devices→keyboard→advanced and it's near the bottom, I use right alt). Then if desired create ~/.XCompose if you want to add to the defaults. Mine is here.

22.04 Fix Zip

There is a bug in the zip that is shipped. To see if you have the bug, create a file named ö (not the umlaut: I use compose key to type this) and try to zip it:

touch ö
zip -9r o.zip ö

with stock 22.04 this results in

*** buffer overflow detected ***: terminated


zip error: Interrupted (aborting)

It does not happen if we apt source and build from source. Thus edit `/etc/apt/sources.list/ubuntu. Change the

Types: deb

to

Types: deb deb-src

then


mkdir -p ~/src # or some other place where you build stuff
cd ~/src
apt-get source zip
sudo apt-get build-dep -y zip
cd zip.3.0
make -f unix/Makefile generic_gcc
sudo cp -t /usr/bin zip zipcloak zipnote zipsplit