r/learnprogramming • u/Lil_Torta1 • 2d ago
STRUGGLING to download from github
I am pretty much completely new to programming, coding, etc. I was trying to download an in-game map for The Isle so I found one on GitHub. Having used it one other time, I was thinking yes I got this. I got to the point where I have the zip file on my computer but I've been trying for over an hour to execute this command after using cmd.
python -m pip install -r requirements.txt
I keep getting the "no such file or directory" error. I've looked up every question I could think of, but nothing is answering my questions. If someone has downloaded this exact desktop map: https://github.com/hartwin-journey/The-Isle-Overlay/blob/main/README.md
PLEASE help me out, I'm at my wits end.
3
1
u/WystanH 1d ago
I have the zip file on my computer
So not git clone, you just clicked download?
You have the extra step of unzipping that into a directory. Then, from a command line in that directory, try that command.
Note, you should see that requirements.txt in the directory. Indeed, the structure will be identical to what you see on github. If you're not seeing that, you're in the wrong spot.
1
u/1Secret_Daikon 1d ago
pro tip
update your shell PS1 prompt so that the pwd is included in the prompt text so you always know which pwd you are in
if it says "file not found" its not lying. The file does not exist at the path you provided it. When you tell it "requirements.txt" you are telling it that the file should be in the current directory and it clearly is not. Beacuse you are in the wrong directory OR the file was not actually in the thing you extracted. I 100% guarantee that you did not even check what directory you are in or the ls of the files in the pwd
1
u/Naetharu 9h ago
To unpack this a bit OP there are two methods you can use:
Your method is downloading it manually, which gives you a zip file. You can then unzip the file, and open a terminal in the new folder and run your command.
The more common way is to use Git itself to handle the download. The command is "git clone" followed by the path you get if you click the copy to clipboard button next to where the file download is in Github.
Either will result in the same files being downloaded, but the latter is better in most cases, as it connects you to the repo and makes it easy to then push changes back up and otherwise work on that software without having to fiddle around with extra configuration.
To run your install you just need to make sure that your shell is pointing to the folder that contains the requirements.txt file.
So either (1) you forgot to unzip the file and are trying to run it in the zipped format, or (2) you have your shell pointing to the wrong location.
The easiest way to be sure you are in the right location is just to open the folder in file explorer and right click => open command prompt. Or if you are in Linux then there will be the same (Gnome it would be right click => Open in Terminal).
In windows there is also a neat little shortcut where you can place your cursor in the address bar of file explorer and simply type "cmd" and press return and it will launch a terminal pointing to that folder.
0
u/FitMatch7966 2d ago
did you read past that line in the readme which says "If that does not work...."
Try py instead
2
17
u/Key-Library218 2d ago
ah the classic first github experience. you extracted the zip right the cmd is probably sitting in the wrong folder. when you open cmd it usually starts in your user directory like C:\Users\YourName but the requirements.txt is inside the folder you just unzipped
you need to navigate there first. type cd and then the path to where you put the files. easiest trick is to open the folder in file explorer then click the address bar at the top and type cmd and hit enter, opens terminal right in that spot
then try the pip install command again and it should work fine. that error just means python cant find the file because you are not in same directory