Merge pull request #152463 from panicgh/tbb
tor-browser-bundle-bin: Keep files when store path has not changed
This commit is contained in:
commit
c1792db42d
|
@ -297,10 +297,17 @@ stdenv.mkDerivation rec {
|
|||
cp -u --no-preserve=mode,owner "$TBB_IN_STORE/TorBrowser/Data/Browser/profile.default/bookmarks.html" \
|
||||
"\$HOME/TorBrowser/Data/Browser/profile.default/bookmarks.html"
|
||||
|
||||
# Clear out some files that tend to capture store references but are
|
||||
# easily generated by firefox at startup.
|
||||
rm -f "\$HOME/TorBrowser/Data/Browser/profile.default"/{addonStartup.json.lz4,compatibility.ini,extensions.ini,extensions.json}
|
||||
rm -f "\$HOME/TorBrowser/Data/Browser/profile.default"/startupCache/*
|
||||
# Clear some files if the last known store path is different from the new one
|
||||
: "\''${KNOWN_STORE_PATH:=\$HOME/known-store-path}"
|
||||
if ! [ "\$KNOWN_STORE_PATH" -ef $out ]; then
|
||||
echo "Cleanup files with outdated store references"
|
||||
ln -Tsf $out "\$KNOWN_STORE_PATH"
|
||||
|
||||
# Clear out some files that tend to capture store references but are
|
||||
# easily generated by firefox at startup.
|
||||
rm -f "\$HOME/TorBrowser/Data/Browser/profile.default"/{addonStartup.json.lz4,compatibility.ini,extensions.ini,extensions.json}
|
||||
rm -f "\$HOME/TorBrowser/Data/Browser/profile.default"/startupCache/*
|
||||
fi
|
||||
|
||||
# XDG
|
||||
: "\''${XDG_RUNTIME_DIR:=/run/user/\$(id -u)}"
|
||||
|
|
Loading…
Reference in a new issue