On 14/11/2022 16:27, Srdjan Todorovic wrote:
On Mon, 14 Nov 2022 at 15:17, Bev Nicolson lumos@gmx.co.uk wrote:
Yes, it is possible to run a command within a folder. In fact, aren't we doing that any time we run commands on the command line? We always have a current working directory (folder). Usually it is in your /home/<username> but can be anywhere. All step 4 asks you to do is to run that python script from within the folder that contains your extracted Twitter data.
This is where I get stuck. I think I've got the location but Terminal says it can't find it and I've tried several times. (And humour me here. Is that what it means by running a script in a folder? Typing in the folder location then asking the script to run?)
So your question boils down to "how to run a script in linux?" If you Google this exact phrase "how to run a script in linux", it will show you a bunch of steps at the top of the search results, below the search bar, but above all the search results. I'm not sure how to replicate this here as I'm not sure if we can send screenshots in these emails.
- Open the terminal. Go to the directory where you want to run your script.
- Make the script executable with command chmod +x <fileName>.
- Run the script using ./<fileName>.
Best wishes, Srdj
I can see this should be really straight forward but it's not making it so. It cannot find the file though I'm sure, as far as I can be, that I'm entering the right location. And I have googled and will keep at it but I am mightily puzzled.
Bev