1

I was working on a backend, and decided to make a git repository for the whole app. After cloning into my home directory, this is the list of commands:

~$ mv PartySpotBackend /PartySpot
mv: cannot move 'PartySpotBackend' to '/PartySpot': Permission denied
~$ sudo !!
sudo mv PartySpotBackend /PartySpot
~$ ls
node_modules PartySpot tmp
~$ cd PartySpot/
~/PartySpot$ ls
LICENCE README.md
~/PartySpot$ ls -a
. .. .git .gitignore LICENCE README.md

The entire PartySpotBackend/ directory seems to have disappeared. Is there any possible way to recover or find it? This is on Ubuntu Server.

1 Answer 1

0

You have moved the directory into / as /PartySpot, not into ~/PartySpot.

You were at your home directory ~ i.e. /home/$USER/ while sending the file and you have sent it to /PartySpot (under root directory /), not the ~/PartySpot directory in your home directory.

As you have used sudo mv PartySpotBackend /PartySpot, the destination /PartySpot starts with / meaning its an absolute path.

In a nutshell, look at /PartySpot.

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.