mirror of
https://github.com/pgrondek/config.git
synced 2024-11-22 12:03:43 +00:00
Add sanitaze download folder
This commit is contained in:
parent
0c748153db
commit
ffefda6bb3
19
sanitaze-folders.sh
Executable file
19
sanitaze-folders.sh
Executable file
@ -0,0 +1,19 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
if [ -d "${HOME}/Pobrane" ]
|
||||||
|
then
|
||||||
|
mkdir -p "${HOME}/Downloads"
|
||||||
|
mv ${HOME}/Pobrane/* "${HOME}/Downloads"
|
||||||
|
echo "Moved all download srom ${HOME}/Pobrane to ${HOME}/Downloads"
|
||||||
|
rmdir "${HOME}/Pobrane"
|
||||||
|
ln -s "${HOME}/Downloads" "${HOME}/Pobrane"
|
||||||
|
echo "Symlinked ${HOME}/Pobrane to ${HOME}/Downloads"
|
||||||
|
else
|
||||||
|
if [ -L "${HOME}/Pobrane" ]
|
||||||
|
then
|
||||||
|
echo "Nothing to do ${HOME}/Pobrane is already symlink"
|
||||||
|
else
|
||||||
|
ln -s "${HOME}/Downloads" "${HOME}/Pobrane"
|
||||||
|
echo "Symlinked ${HOME}/Pobrane to ${HOME}/Downloads"
|
||||||
|
fi
|
||||||
|
fi
|
Loading…
Reference in New Issue
Block a user