-1

I have to finish the program on which I worked six months. This is my very first program.

I designed with PyCharm and I have a database and several module.

How can I run my program without using PyCharm?

Baltazarg
  • 27
  • 1
  • 6
  • I think you are just asking "[how to run a .py file](https://www.google.ca/search?client=safari&rls=en&q=how+to+run+a+.py+file&ie=UTF-8&oe=UTF-8&gfe_rd=cr&ei=nWtUWI-vFION8Qfqy7jACg)" which have answers on the internet already, no need to ask on SO. – Tadhg McDonald-Jensen Dec 16 '16 at 22:34
  • i have many py file plus a database (SQLite) that make a single program. – Baltazarg Dec 16 '16 at 22:42
  • Also, all of my code is in virtual environment. I understand how to run my code in PyCharm but really dont have any idea of how to run it outside of PyCharm. – Baltazarg Dec 16 '16 at 22:47
  • 2
    `python filename.py` from the shell. – Barmar Dec 16 '16 at 22:58
  • I try in the terminal : « python the_name_of_my_main_programme.py ». – Baltazarg Dec 17 '16 at 00:09
  • And the terminal search for the money module inside the folder where is my main program. What can i do for that ? – Baltazarg Dec 17 '16 at 00:11
  • @Baltazarg please give us more information about how you run it in PyCharm in a manner that works and we **may** be able to help, currently your question doesn't give us anything to go on so there is no way we can help. – Tadhg McDonald-Jensen Dec 17 '16 at 01:36

1 Answers1

1

Based on the fact that you are working on this project for the last 6 months, my guess is that you were running it through PyCharm. In most cases when you run your project through PyCharm you can see that on PyCharm "Run" console the first line logged is something like that:

/path/to/setup/bin/python<version>   path/to/your_project/file_contains_main.py --argumnent1=value1 --argumnent2=value2...

Scenario 1

If you see something like that, then you can copy your project in a system that has python installed and run the same file_contains_main.py as below:

python path/to/your_project/file_contains_main.py --argumnent1=value1 --argumnent2=value2...

Some more details for Windows here and for Linux here.

Scenario 2

If you do not see the command above logged in PyCharm then you may find this solution more appropriate.

Community
  • 1
  • 1
afxentios
  • 2,502
  • 2
  • 21
  • 24
  • Thank's a lot. Now i am ok and it's working well. I really appreciate your help. It's was my very fist time with Python. And did have any idea of how to do that. And your help me catch the fact that i have to use the word python3 instead of python. Thank's again. – Baltazarg Dec 17 '16 at 17:25
  • Happy to help, and welcome to Stack Overflow. If this answer helped you solve your issue, please mark it as accepted :) – afxentios Dec 17 '16 at 17:34
  • 1
    Just a word to say : with the explanation of afxentios tree hour later. i done a shell script to lunch my application. – Baltazarg Dec 17 '16 at 20:18
  • Now i have a icon for my application and everything is working fine. Thanks again – Baltazarg Dec 17 '16 at 20:19