简体   繁体   中英

Laravel Installation “No such file or directory” Error on Mac

I'm totally new in Laravel. In the installation process, I'm facing with an error. I wrote it to the Laravel IRC chat, but the problem still continues. While I try to move the laravel.phar file,

mv laravel.phar /usr/local/bin/laravel

I get,

mv: rename laravel.phar to /usr/local/bin/laravel.phar: No such file or directory

that error. I also tried /usr/local/bin directory but the error was the same.

Note: The /usr/local/bin directory exists.

This seems like more a basic shell problem than specifically a Laravel problem, but "Computers as Weird" sometimes.

The mv command is either telling you it can't find laravel.phar , or it can't find /usr/local/bin . The best way to solve this problem is to make sure the file you're trying to move is there, and that the destination folder is there. Also, you'll want to do this from the command line .

What happens when you type each of the following commands?

$ ls -l laravel.phar
$ ls -l /usr/local/bin
$ ls -l .

The first checks the local directroy for the laravel.phar file.

The second checks to make sure /usr/local/bin exists and lists all the files in it

The third lists all the files in the current directory.

The output of these commands should point you towards a solution to your problem.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM