Compare commits
10 Commits
b4c554de0d
...
a55c531b27
| Author | SHA1 | Date | |
|---|---|---|---|
| a55c531b27 | |||
| 952de59272 | |||
| 12db811f6e | |||
| 052470509f | |||
| 7ac2af94ca | |||
| 148e95e865 | |||
| 882157ed4c | |||
| ed2cf1db47 | |||
| 0d38824f5f | |||
| 0b1c94354e |
@@ -26,11 +26,8 @@ jobs:
|
||||
apt-get install -y hugo
|
||||
|
||||
- name: Build Hugo Site
|
||||
run: hugo --minify --config hugo.toml
|
||||
run: hugo --minify --config hugo.toml -d /output
|
||||
|
||||
- name: Deploy Hugo Site
|
||||
run: docker cp /output/. gitea-runner:/output
|
||||
|
||||
- name: Deploy to Hugo Container
|
||||
run: |
|
||||
rsync -avz --delete public/ /mnt/hugo/
|
||||
env:
|
||||
HUGO_CONTAINER_PATH: /mnt/hugo/
|
||||
GITEA_RUNNER_MOUNT_PATH: ./hugo/public:/mnt/hugo
|
||||
@@ -2,4 +2,5 @@
|
||||
date = '{{ .Date }}'
|
||||
draft = true
|
||||
title = '{{ replace .File.ContentBaseName "-" " " | title }}'
|
||||
type='post'
|
||||
+++
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
+++
|
||||
date = '2023-02-01T15:31:59'
|
||||
draft = false
|
||||
title = 'URLs in Latex With Proper Linebreaks'
|
||||
type = 'post'
|
||||
tags = ['LaTeX']
|
||||
+++
|
||||
|
||||
## Problem
|
||||
While the [hyperref](https://www.ctan.org/pkg/hyperref) package provides the `\\url{}` command it doesn't handle line breaks well.
|
||||
|
||||
## Solution
|
||||
Use the package [xurl](https://www.ctan.org/pkg/xurl).
|
||||
@@ -0,0 +1,23 @@
|
||||
+++
|
||||
date = '2022-09-04T15:40:21'
|
||||
draft = false
|
||||
title = 'Automatic Updates'
|
||||
type = 'post'
|
||||
tags = ['Linux', 'Debian']
|
||||
+++
|
||||
Installing security updates is very important. Especially on a server that is not accessed on a daily basis.
|
||||
This tutorial covers the basics for setting up unattended-upgrades on any Debian-based Linux distribution.
|
||||
## Update the system
|
||||
```
|
||||
sudo apt update && sudo apt upgrade
|
||||
```
|
||||
## Install unattended-upgrades
|
||||
```
|
||||
apt install unattended-upgrades
|
||||
```
|
||||
```
|
||||
dpkg-reconfigure unattended-upgrades
|
||||
```
|
||||
|
||||
## Further Information
|
||||
<https://wiki.debian.org/UnattendedUpgrades>
|
||||
@@ -0,0 +1,63 @@
|
||||
+++
|
||||
date = '2022-11-07T13:42:02'
|
||||
draft = false
|
||||
title = 'Basic Doom Emacs Commands'
|
||||
type = 'post'
|
||||
tags = ['Emacs']
|
||||
+++
|
||||
|
||||
This is basically just a collection of various commands I discovered while learning to use Doom Emacs.
|
||||
All Sources will be listed at the bottom of this page.
|
||||
|
||||
Also. This side does not provide a lot of explanation regarding the function of the commands.
|
||||
It is just intended as a cheat sheet.
|
||||
Updates/ Changes **will** be added to this post.
|
||||
|
||||
# Navigation
|
||||
## Workspaces
|
||||
- switch between workspaces: '**SPC TAB .**'
|
||||
- load workspace: '**SPC TAB l**'
|
||||
- create new workspace: '**SPC TAB n**'
|
||||
- rename workspace: '**SPC TAB r**'
|
||||
- save workspace: '**SPC TAB s**'
|
||||
- select project for workspace: '**SPC p p**'
|
||||
### File Switching inside Workspaces
|
||||
- switch to file within current project: '**SPC SPC**'
|
||||
- '**SPC .**' provides the save functionality but can also search outside the current project
|
||||
- switch to buffer within current project: '**SPC ,**'
|
||||
- switch to a buffer outside the current project: '**SPC b B**'
|
||||
- load recently viewed file: '**SPC fr**'
|
||||
|
||||
## Finding Text
|
||||
- search all files in the current project: '**SPC sp**'
|
||||
- search inside the current buffer: '**/**' (normal Vim navigation)
|
||||
### Moving to Text
|
||||
- jump to line (faster then relative line numbers): '**gsj**'
|
||||
- '**s**' and two chars to jump to the nearest match
|
||||
- '**S**' to jump backwards
|
||||
- '**,**' or '**;**' to cycle through the matches (forwards/ backwards)
|
||||
|
||||
**NOTE:** this navigation can be combined with (almost) all of the standard Vim commands (e.g. '**vs\\<chars\\>**' visualizes all the text to the nearest match for \\<chars\\>)
|
||||
|
||||
## Source Code
|
||||
- go to definition: '**gd**'
|
||||
- list references: '**gD**'
|
||||
### Fancy Delete
|
||||
**NOTE:** all these commands should also work for 'change' ('**c**')
|
||||
- delete inside the same indent (e.g. *function* of if statement): '**dii**'
|
||||
- delete inside the same indent + line above (e.g. *complete* if statement in python): '**dik**'
|
||||
- delete inside the same indent + line above and below (e.g. *complete* if statement in java): '**dij**'
|
||||
|
||||
## Compilation Errors
|
||||
- next and previous flycheck error: '**\\]e**' and '**\\[e**'
|
||||
- list current errors: '**SPC c x**'
|
||||
|
||||
# Miscellaneous
|
||||
- compile: '**SPC p c**'
|
||||
- open [Magit](https://magit.vc/): '**SPC gg**'
|
||||
- comment/ uncomment a line: '**gcc**'
|
||||
|
||||
# Sources
|
||||
- https://github.com/doomemacs/doomemacs/
|
||||
- https://noelwelsh.com/posts/doom-emacs/
|
||||
- https://medium.com/@aria_39488/the-niceties-of-evil-in-doom-emacs-cabb46a9446b
|
||||
@@ -0,0 +1,9 @@
|
||||
+++
|
||||
date = '2022-09-04T15:51:15'
|
||||
draft = false
|
||||
title = 'Create Windows USB on Linux'
|
||||
type = 'post'
|
||||
tags = ['Linux']
|
||||
+++
|
||||
|
||||
# "USE [WOEUSB](https://github.com/WoeUSB/WoeUSB)"
|
||||
@@ -0,0 +1,12 @@
|
||||
+++
|
||||
date = '2022-09-04T16:04:09'
|
||||
draft = false
|
||||
title = 'Extract Images From PDF on Linux'
|
||||
type = 'post'
|
||||
tags = ['Linux']
|
||||
+++
|
||||
|
||||
By using the `pdfimages` command included in most Linux distributions it is easy to extract all pictures included in a PDF document.
|
||||
Instructions on how to use the command can be found [here](https://www.xpdfreader.com/pdfimages-man.html).
|
||||
|
||||
**Note:** the target directory for the extracted images must be created before executing the command, else it will just throw errors.
|
||||
@@ -0,0 +1,9 @@
|
||||
+++
|
||||
date = '2022-09-04T15:59:30'
|
||||
draft = false
|
||||
title = 'Finding Package Files With Apt Files'
|
||||
type = 'post'
|
||||
tags = ['Linux','Debian']
|
||||
+++
|
||||
|
||||
To find the files/directories related to a package on a Debian-based system, use the [apt-file](https://wiki.debian.org/apt-file) package.
|
||||
@@ -0,0 +1,11 @@
|
||||
+++
|
||||
date = '2022-09-04T15:52:50'
|
||||
draft = false
|
||||
title = 'German Quotations in LaTeX'
|
||||
type = 'post'
|
||||
tags = ['LaTeX']
|
||||
+++
|
||||
|
||||
In short: do **not** use any fancy macros and shit that can break other configurations.
|
||||
Just use the shorthands provided by the ```babel``` package.
|
||||
For a list of all the babel shorthands see https://ctan.math.washington.edu/tex-archive/macros/latex/contrib/babel-contrib/german/ngermanb.pdf
|
||||
@@ -0,0 +1,67 @@
|
||||
+++
|
||||
date = '2026-03-10T18:37:42+01:00'
|
||||
draft = false
|
||||
title = 'Modify Image Timestamp'
|
||||
type='post'
|
||||
tags = ['Linux', 'Photography']
|
||||
+++
|
||||
Some cameras don't automatically update their internal clock. This leads to images with "wrong" timestamps.
|
||||
Modifying the [file metadata](https://en.wikipedia.org/wiki/Metadata) as well as the [Exif metadata](https://en.wikipedia.org/wiki/Exif) can fix this problem.
|
||||
|
||||
## Modifying the file metadata
|
||||
```bash
|
||||
touch -m -d "<date>" "<file_name>"
|
||||
```
|
||||
- `-m` only modify the modification date
|
||||
- `-d "<date>"` use `<date>` instead of the current date
|
||||
- `<file_name>` name of the file to be modified
|
||||
|
||||
### Example Script for adding an offset
|
||||
The following command adds 20 years and 7 months while subtracting 6 days.
|
||||
```bash
|
||||
#!/bin/bash
|
||||
original_mtime=$(stat -c %y "<file_name>")
|
||||
new_mtime=$(date -d "$original_mtime +20 years +7 months -6 days" '+%Y-%m-%d %H:%M:%S')
|
||||
touch -m -d "$new_mtime" "<file_name>"
|
||||
```
|
||||
- `stat -c %y "<file_name>"` reads the current modification timestamp from the file
|
||||
- `date -d ...` calculates the new date
|
||||
|
||||
## Modifying the Exif metadata
|
||||
```bash
|
||||
exiftool -P -overwrite_original "-allDates=<date>" "<file_name>"
|
||||
```
|
||||
- `exiftool` [FOSS](https://en.wikipedia.org/wiki/Free_and_open-source_software) tool for viewing and modifying Exif data ([source](https://exiftool.org/))
|
||||
- `-P` to not overwrite the file modification time (file metadata)
|
||||
- `allDates=...` modifies the exif metadata dates
|
||||
- can be used with operators (i.e. `+=`, `-=`) for offsets
|
||||
|
||||
### Example Script for adding an offset
|
||||
The following command adds 20 years and 7 months while subtracting 6 days.
|
||||
```bash
|
||||
#!/bin/bash
|
||||
exiftool -P -overwrite_original "-allDates+=20:7:0 0:0:0" "<file_name>"
|
||||
exiftool -P -overwrite_original "-allDates-=0:0:6 0:0:0" "<file_name>"
|
||||
```
|
||||
|
||||
## Example Script for Combined Modification
|
||||
This script modifies all `.JPG` files in a given directory by adding 20 years and 7 months while subtracting 6 days.
|
||||
```bash
|
||||
#!/bin/bash
|
||||
|
||||
find "<dir_name>" -type f -iname "*.JPG" -print0 | while IFS= read -r -d '' file; do
|
||||
echo "Processing $file"
|
||||
|
||||
#update meta data
|
||||
original_mtime=$(stat -c %y "$file")
|
||||
new_mtime=$(date -d "$original_mtime +20 years +7 months -6 days" '+%Y-%m-%d %H:%M:%S')
|
||||
touch -m -d "$new_mtime" "$file"
|
||||
|
||||
#update exif data
|
||||
exiftool -P -overwrite_original "-allDates+=20:7:0 0:0:0" "$file"
|
||||
exiftool -P -overwrite_original "-allDates-=0:0:6 0:0:0" "$file"
|
||||
done
|
||||
|
||||
echo "DONE!"
|
||||
```
|
||||
- `<dir_name>` name of the directory to be modified
|
||||
@@ -0,0 +1,58 @@
|
||||
+++
|
||||
date = '2022-09-04T15:43:06'
|
||||
draft = false
|
||||
title = 'Regex Basics'
|
||||
type = 'post'
|
||||
tags = ['Misc']
|
||||
+++
|
||||
[just text:](#just-text) matches any string with the given text inside it
|
||||
[^](#^) matches string that starts with the given text
|
||||
[$](#$) matches string that ends with the given text
|
||||
[*](#*) zero or more
|
||||
[+](#+) one or more
|
||||
[?](#?) zero or one
|
||||
[{n}](#{n}) `n` occurrences
|
||||
[a|b or [ab]](#OR-operator) a or b
|
||||
[\\d](#\\d) matches a digit
|
||||
[\\w](#\\w) matches a word character (alphanumeric plus underscore)
|
||||
[\\s](#\\s) matches a whitespace character
|
||||
[.](#.) matches any character
|
||||
|
||||
## Anchors
|
||||
### just text
|
||||
`abc` matches any string that has the text _abc_ in it
|
||||
### ^
|
||||
`^abc` matches any string that starts with _abc_
|
||||
### $
|
||||
`abc$` matches any string that ends with _abc_
|
||||
### exact match
|
||||
`^abc$` matches only the exact string _abc_
|
||||
|
||||
## Quantifiers
|
||||
### *
|
||||
`abc*` matches any string containing _ab_ followed by any number of _c_ s
|
||||
### +
|
||||
`abc+` matches any string containing _ab_ followed by at least one _c_
|
||||
### ?
|
||||
`abc?` matches any string containing _ab_ followed by at the most one _c_
|
||||
### {n}
|
||||
`abc{2}` matches any string containing _ab_ followed by two _c_ s
|
||||
`abc{2,}` matches any string containing _ab_ followed by two __or more__ _c_ s
|
||||
`abc{2,5}` matches any string containing _ab_ followed by between two and five _c_ s
|
||||
|
||||
## OR operator
|
||||
`a|b` _a_ or _b_
|
||||
`[abc]` _a_ or _b_ or _c_
|
||||
|
||||
## Character classes
|
||||
### \d
|
||||
`\d` matches any character in a string that is a digit
|
||||
`\D` matches any character that __isn't__ a digit
|
||||
### \w
|
||||
`\w` matches any character in a string that is a word character
|
||||
`\W` matches any character that __isn't__ a word character
|
||||
### \s
|
||||
`\s` matches any whitespace character in a string
|
||||
`\S` matches any __non__-whitespace character
|
||||
### .
|
||||
`.` matches any character in a string
|
||||
@@ -0,0 +1,27 @@
|
||||
+++
|
||||
date = '2022-09-04T15:39:45'
|
||||
draft = false
|
||||
title = 'SSH Basics'
|
||||
type='post'
|
||||
tags = ['Misc']
|
||||
+++
|
||||
|
||||
## Generate Keypair
|
||||
```bash
|
||||
ssh-keygen
|
||||
```
|
||||
|
||||
## Remote Login with Key
|
||||
```bash
|
||||
ssh-copy-id <Host>@<Remote>
|
||||
```
|
||||
|
||||
### Disable Access via Password
|
||||
modify `/etc/ssh/sshd_config` so that it includes
|
||||
```
|
||||
PasswordAuthentication no
|
||||
```
|
||||
#### enable changes
|
||||
```
|
||||
systemctl restart ssh
|
||||
```
|
||||
@@ -0,0 +1,13 @@
|
||||
+++
|
||||
date = '2022-09-04T15:55:29'
|
||||
draft = false
|
||||
title = 'Teamviewer on Arch Linux'
|
||||
type = 'post'
|
||||
tags = ['Arch Linux', 'Linux', 'Misc']
|
||||
+++
|
||||
|
||||
1. install teamviewer from the AUR
|
||||
2. every time you want to run TeamViewer GUI the deamon needs to be running.
|
||||
This only works with a Display Manager (e.g. LightDM) and systemd.
|
||||
```sudo systemctl start teamviewerd```
|
||||
3. run the TeamViewer GUI
|
||||
@@ -0,0 +1,17 @@
|
||||
+++
|
||||
date = '2024-12-03T14:35:27+01:00'
|
||||
draft = false
|
||||
title = 'Tkinter in a Conda Environment'
|
||||
type = 'post'
|
||||
tags = ['Conda']
|
||||
+++
|
||||
|
||||
The default tk built shipped with conda does not have freetype support.
|
||||
|
||||
## Workaround
|
||||
The workaround proposed in [this](https://github.com/conda-forge/tk-feedstock/pull/40#issuecomment-1803067221) Github issue is:
|
||||
```
|
||||
conda install -c conda-forge tk=*=xft_*
|
||||
```
|
||||
|
||||
**Note:** in zsh the * need to be escaped
|
||||
@@ -0,0 +1,25 @@
|
||||
+++
|
||||
date = '2022-09-15T23:04:00'
|
||||
draft = false
|
||||
title = 'Using 3Dconnexion Mice on Arch Linux'
|
||||
type = 'post'
|
||||
tags = ['Arch Linux', 'Misc']
|
||||
+++
|
||||
|
||||
1. Check if the mouse is recognized by the system
|
||||
```bash
|
||||
grep 3Dconnexion /proc/bus/input/devices
|
||||
```
|
||||
1. Install open source drivers [libspnav](https://archlinux.org/packages/extra/x86_64/libspnav/) and [spacenavd](https://aur.archlinux.org/packages/spacenavd)from the AUR (propriatary drivers are very old)
|
||||
|
||||
1. test the setup by running the daemon manually (test programs like [FreeCAD](https://www.freecad.org/) might need to be restarted)
|
||||
```bash
|
||||
spacenavd -v -d
|
||||
```
|
||||
1. the daemon is provided in the form of `spacenavd.service` by the [spacenavd](https://aur.archlinux.org/packages/spacenavd) package and can be started or enabled with [systemctl](https://wiki.archlinux.org/title/Systemctl)
|
||||
|
||||
## configuration via GUI
|
||||
to view and modify the button mappings as well as the general configuration install the [spnavcfg](https://aur.archlinux.org/packages/spnavcfg) package from the AUR
|
||||
|
||||
## Notes
|
||||
This "Tutorial" is just an abbreviated version of the [3D Mouse Arch Wiki Page](https://wiki.archlinux.org/title/3D_Mouse)
|
||||
@@ -0,0 +1,12 @@
|
||||
+++
|
||||
date = '2022-09-04T15:56:51'
|
||||
draft = false
|
||||
title = 'Wireguard Keepalive'
|
||||
type = 'post'
|
||||
tags = ['Misc']
|
||||
+++
|
||||
|
||||
If one peer is behind a DynDNS you need to use the `reresolve-dns.sh` script included with the wireguard-tools package.
|
||||
Excelent [documentation in the Arch-Wiki](https://wiki.archlinux.org/title/WireGuard#Endpoint_with_changing_IP)
|
||||
|
||||
__Note__: wireguard-tools package is installed on another directory in Debian than in Arch. use [apt-file](/knowledge-base/finding-package-files-with-apt-files) to find the relevant directory.
|
||||
@@ -1,16 +1,38 @@
|
||||
baseURL = 'https://ploedige.com'
|
||||
languageCode = 'en'
|
||||
defaultContentLanguage = "en"
|
||||
languageCode = "en"
|
||||
enableEmoji = true
|
||||
|
||||
title = 'Paul W. Lödige'
|
||||
theme = "gokarna"
|
||||
|
||||
[params]
|
||||
avatarAltText = "Profile Picture"
|
||||
avatarSize = "size-xl"
|
||||
avatarURL = "/images/micro_profile.jpg"
|
||||
description = "Robotics Engineer"
|
||||
footer = "Paul W. Lödige"
|
||||
|
||||
socialIcons = [
|
||||
{name = "email", url = "mailto:paul@ploedige.com"},
|
||||
{name = "linkedin", url = "https://www.linkedin.com/in/ploedige"},
|
||||
{name = "scholar", url = "https://scholar.google.com/citations?user=b6G4zaEAAAAJ&hl"},
|
||||
{name = "github", url = "https://github.com/ploedige"},
|
||||
]
|
||||
|
||||
[menu]
|
||||
[[menu.main]]
|
||||
name = "Posts"
|
||||
url = "/posts/"
|
||||
name = "CV"
|
||||
url = "./documents/CV.pdf"
|
||||
weight = 1
|
||||
|
||||
[[menu.main]]
|
||||
name = "Tags"
|
||||
url = "/tags/"
|
||||
name = "Projects & Publications"
|
||||
url = "/projects/"
|
||||
weight = 2
|
||||
|
||||
[[menu.main]]
|
||||
name = "Knowledge Base"
|
||||
url = "/knowledge-base/"
|
||||
weight = 3
|
||||
|
||||
|
||||
Binary file not shown.
Binary file not shown.
|
After Width: | Height: | Size: 162 KiB |
@@ -0,0 +1,39 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Uploaded to: SVG Repo, www.svgrepo.com, Generator: SVG Repo Mixer Tools -->
|
||||
|
||||
<svg
|
||||
aria-label="Google Scholar"
|
||||
role="img"
|
||||
viewBox="0 0 512 512"
|
||||
version="1.1"
|
||||
id="svg1"
|
||||
sodipodi:docname="scholar.svg"
|
||||
inkscape:version="1.4 (e7c3feb100, 2024-10-09)"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:svg="http://www.w3.org/2000/svg">
|
||||
<defs
|
||||
id="defs1" />
|
||||
<sodipodi:namedview
|
||||
id="namedview1"
|
||||
pagecolor="#505050"
|
||||
bordercolor="#ffffff"
|
||||
borderopacity="1"
|
||||
inkscape:showpageshadow="0"
|
||||
inkscape:pageopacity="0"
|
||||
inkscape:pagecheckerboard="1"
|
||||
inkscape:deskcolor="#505050"
|
||||
inkscape:zoom="2.3398438"
|
||||
inkscape:cx="256"
|
||||
inkscape:cy="119.23873"
|
||||
inkscape:window-width="2546"
|
||||
inkscape:window-height="1402"
|
||||
inkscape:window-x="1085"
|
||||
inkscape:window-y="269"
|
||||
inkscape:window-maximized="1"
|
||||
inkscape:current-layer="svg1" />
|
||||
<path
|
||||
id="rect1"
|
||||
d="M 76.800781 0 C 34.25358 0 0 34.25358 0 76.800781 L 0 435.19922 C 0 477.74642 34.25358 512 76.800781 512 L 435.19922 512 C 477.74642 512 512 477.74642 512 435.19922 L 512 76.800781 C 512 34.25358 477.74642 0 435.19922 0 L 76.800781 0 z M 213 111 L 393 111 L 377 127 L 377 152 C 380 153 382 157 382 160 L 382 263 C 381 274 361 276 359 263 L 359 160 C 359 157 361 153 364 151 L 365 135 L 320 173 C 324 188 328 199 326 216 C 322 240 302 250 287 267 C 280 279 285 289 308 307 C 329 324 343 343 339 378 C 330 413 287 433 249 432 C 220 432 161 423 157 378 C 157 337 217 312 260 311 C 249 299 246 290 253 272 C 216 269 180 250 175 205 L 106 205 L 213 111 z M 243.15039 152.15625 C 239.88745 152.04688 236.5 152.3125 233 153 C 184 165 210 262 271 252 C 313.1875 239.8125 292.09448 153.79688 243.15039 152.15625 z M 266 325 C 230 325 195 348 195 373 C 194 399 232 412 276 403 C 327 388 326 338 266 325 z " />
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 2.0 KiB |
+1
-1
Submodule themes/gokarna updated: b6c8394818...09992f3c43
Reference in New Issue
Block a user