I have been trying to do the Lingua Franca Project exercises, but I keep coming up against permission issues. I either don’t have permission to be in the folder or the folder is a “Read-only file system” that I cannot edit. Which is frustrating since I am the admin but Command Line doesn’t think I am. How do I work around this?
Is this on your own computer or in the learning environment? Link to course?
It’s my computer. I downloaded the zip file and unzipped it. There are also no other users (other than admin that came with MacBook default setting?).
What is the error message?
What’s the link to the lesson in the course?
It’s this one: https://www.codecademy.com/courses/learn-the-command-line/articles/command-line-offline-project
For example, there is an exercise to copy spanish.txt to the Europe folder, but my command line returns:
cp: /europe: Read-only file system
Because the system is recognizing the folder as read-only, I can’t move files in or out of it, etc.
Did you delete the file and re-download it and put it somewhere you could access it?
What code have you written so far? What happens when you type in that directory?:
ls -alt
what do the file permissions say in the first column? Something like:
drwxrwxr-x
Did you watch the project’s video for help?
I got to Task 8 and started having issues where the mv commands should move the file. Instead, it renames the file and doesn’t move it.
Here is the printout
(base) cindylinsf@Cindys-MacBook-Pro lingua-franca-project % ls -alt
total 72
drwx------@ 11 cindylinsf staff 352 Dec 11 08:59 …
drwxr-xr-x@ 10 cindylinsf staff 320 Dec 10 10:42 lingua-franca
drwxr-xr-x 3 cindylinsf staff 96 Dec 10 03:24 world
-rw-r–r–@ 1 cindylinsf staff 6148 Dec 10 03:23 .DS_Store
drwx------@ 7 cindylinsf staff 224 Dec 10 03:23 .
-rw-rw-r–@ 1 cindylinsf staff 9151 Oct 5 2020 tasks.html
-rw-rw-r–@ 1 cindylinsf staff 16043 Oct 5 2020 solution.html
The project video only goes over solutions. It doesn’t cover troubleshooting.
Can you please provide your code or a screenshot of the code? I don’t know all the steps in the project, but to remove a file from a directory it’s: rm filename.txt
To move a file, it’s mv filename
It also might be a good idea to delete the project zip file and re-download it and start over.
I did and I also used the exact solution in the project video, but I still got the same error. I was looking for answers and it seems like it’s a permission issue, like my original question.
I also already re-downloaded it 3x. Other than this particular project, I encounter permission issues frequently when I am using the command line. I am trying to find a way to go around it.
My question is really less about the project itself but about the permission issue. I have tried sudo but it’s not always successful. If you have suggestions on the permission issues, I would really appreciate it.
Go to your Finder app and right click on the project file folder and select “Get info”. Then a window should pop up & at the bottom there will be a “Sharing & Permissions” section w/2 columns with your name and permissions. The Privilege column next to your name should say “read & write” .
See:
To read more about the file permissions above, drwxr-xr-x
:
https://wiki.archlinux.org/title/File_permissions_and_attributes#Viewing_permissions
Thank you for sharing that. I checked and it already says read and write.
Thanks for your help though. Have a wonderful holiday.