Python Forum
Methods of running a script on Linux distro
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Methods of running a script on Linux distro
#4
(Aug-21-2018, 05:12 PM)heras Wrote: Normally you would chmod +x script.py to make it executable without having to specify python on the command line explicitly.

I have the script.py on my desktop. I am in: ~/Desktop: directory and when I type: sudo chmod +x script.py. It gives the error:

Output:
rob@linux038:~/Desktop$ sudo chmod +x script.py [sudo] password for rob: chmod: cannot access 'script.py': No such file or directory
So I tried:

rob@linux038:~/Desktop$ sudo chmod +x script
rob@linux038:~/Desktop$

So it worked?? I am not sure, lol how do I check if the link was created any idea?
Reply


Messages In This Thread
RE: Methods of running a script on Linux distro - by Vysero - Aug-21-2018, 05:46 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  No Internet connection when running a Python script basil_555 8 689 Mar-11-2024, 11:02 AM
Last Post: snippsat
Question Running Python script through Task Scheduler? Winfried 8 567 Mar-10-2024, 07:24 PM
Last Post: Winfried
  Is possible to run the python command to call python script on linux? cuten222 6 799 Jan-30-2024, 09:05 PM
Last Post: DeaD_EyE
  Help Running Python Script in Mac OS emojistickers 0 367 Nov-20-2023, 01:58 PM
Last Post: emojistickers
  Trying to make a board with turtle, nothing happens when running script Quascia 3 708 Nov-01-2023, 03:11 PM
Last Post: deanhystad
  Python script running under windows over nssm.exe JaroslavZ 0 735 May-12-2023, 09:22 AM
Last Post: JaroslavZ
  Running script with subprocess in another directory paul18fr 1 3,885 Jan-20-2023, 02:33 PM
Last Post: paul18fr
  Running 3rd party libs on Steam Deck (Arch Linux) with restricted access metulburr 0 1,890 Jan-07-2023, 10:41 PM
Last Post: metulburr
  [SOLVED] [Linux] Script in cron stops after first run in loop Winfried 2 944 Nov-16-2022, 07:58 PM
Last Post: Winfried
  How to compile a Python script for a Windows / Linux executable? netanelst 2 1,357 May-24-2022, 07:02 AM
Last Post: netanelst

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020