Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to run PyCharm in Ubuntu - "Run in Terminal" or "Run"?

When I double-click on pycharm.sh, Ubuntu lets me choose between "Run in Terminal" and "Run". What is the difference between these options?

like image 450
AlexC Avatar asked Nov 21 '14 14:11

AlexC


People also ask

Can you run PyCharm in terminal?

PyCharm includes an embedded terminal emulator for working with your command-line shell from inside the IDE. Use it to run Git commands, set file permissions, and perform other command-line tasks without switching to a dedicated terminal application.

How do I start PyCharm in Linux?

Run the PyCharm app from the Applications directory, Launchpad, or Spotlight. Run the pycharm.sh shell script in the installation directory under bin. You can also use the desktop shortcut, if it was created during installation.

How do I open PyCharm in Ubuntu without terminal?

2 Answers. PyCharm (like Intellij Idea and other JetBrain products) have a built in function to create desktop icon : Tools > Create desktop Entry. Once done you will find PyCharm in your Ubuntu Dash.

How do I run PyCharm as root in Ubuntu?

At the right top hand side click the "setting" icon, and click "Add local". In the browser option choose the python-sudo.sh script we have created previously. This will give PyCharm the privilege to run a python script as root.


2 Answers

To make it a bit more user-friendly: After you've unpacked it, go into the directory, and run bin/pycharm.sh. Once it opens, it either offers you to create a desktop entry, or if it doesn't, you can ask it to do so by going to the Tools menu and selecting Create Desktop Entry...

Then close PyCharm, and in the future you can just click on the created menu entry. (or copy it onto your Desktop)

To answer the specifics between Run and Run in Terminal: It's essentially the same, but "Run in Terminal" actually opens a terminal window first and shows you console output of the program. Chances are you don't want that :)

(Unless you are trying to debug an application, you usually do not need to see the output of it.)

like image 121
sysconfig Avatar answered Oct 17 '22 13:10

sysconfig


The question is already answered, Updating answer to add the PyCharm bin directory to $PATH var, so that pycharm editor can be opened from anywhere(path) in terminal.

Edit the bashrc file,

nano .bashrc

Add following line at the end of bashrc file

export PATH="<path-to-unpacked-pycharm-installation-directory>/bin:$PATH"

Now you can open pycharm from anywhere in terminal

pycharm.sh

like image 14
Sachin G. Avatar answered Oct 17 '22 14:10

Sachin G.