#!/bin/bash # # patch 'Tausch' and 'Nextcloud' into dolphin's bookmarks # set -eu file="${1:-$HOME/.local/share/user-places.xbel}" [[ -e "$file" ]] || exit 0 if grep -q "Tausch\|Nextcloud" "$file" ; then echo "Your Dolphin seems to already contain 'Tausch' and/or 'Nextcloud'." | tee "$file.lmn" exit 0 fi id="$(grep ID "$file" | sed -E "s|^.+ID>([[:digit:]]+)/([[:digit:]]+) +