Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Firefox sinhronizācija ar RAMdisku
#!/bin/sh
static=main
link=Firefox profils
volatile=/tmp/ram
IFS=
set -efu
cd ~/.mozilla/firefox
if [ ! -r $volatile ]; then
mkdir -m0700 $volatile
fi
if [ "$(readlink $link)" != "$volatile" ]; then
mv $link $static
ln -s $volatile $link
fi
if [ -e $link/.unpacked ]; then
rsync -av --delete --exclude .unpacked ./$link/ ./$static/
else
rsync -av ./$static/ ./$link/
touch $link/.unpacked
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.