GoLand 2019.2 Help

Running Applications

GoLand enables running entire applications as well as

GoLand makes use of the settings defined in a Run/Debug Configuration. All the run configurations that exist in a project, are available in the Select Run/Debug Configuration list.

If you want to see the list of all currently running applications, select Run | Show Running List from the main menu.

Note that after you've started a run session, the icons toolwindows toolWindowRun svg icon that marks the Run tool window and in the Run/Debug Configuration Selector toggles to active run icon to indicate that the run process is active.

Using the icon in the left gutter

In the left gutter of the editor, click the Run application icon the Run Application icon and select Run <method_name> in <file_name>.

Using the icon in the left gutter

Using the context menu

Right-click the opened file or a method in the editor and select Run <method_name> in <file_name> Ctrl+Shift+F10.

Using the context menu

Using the Run/Debug configuration

  1. Open the Run/Debug Configuration dialog:

    • Select Run | Edit Configurations from the main menu.

    • With the Navigation bar visible (View | Appearance | Navigation Bar), choose Edit Configurations from the run/debug configuration selector.

    • Press Shift+Alt+F10, then press 0 or select the configuration from the popup and press F4.

  2. In the Run/Debug Configuration dialog, click the Add New Configuration icon (the Add New Configuration icon) on the toolbar or press Alt+Insert. The list shows the default run/debug configurations. Select the desired configuration type (for example, Go build).

    The fields that appear in the right-hand pane display the default settings for the selected configuration type.

  3. In the Name field, type the configuration name.

  4. In the Files field, add the name of the file that you want to run (for example, main.go).

  5. Specify additional parameters depending on the configuration type. For example, if you want your code to run with sudo privileges, select the Run with sudo checkbox.

  6. Apply the changes and close the dialog.

  7. Click the Run <configuration_name> button The Run button.

Rerun an application

You can re-run an application if its tab is still opened in the Run window. The program re-runs with the initial settings.

  1. In the Run window, select the tab where the desired application is opened.

  2. In the toolbar, click the Rerun button rerunConsole, or press Ctrl+F5.

  3. In the notification dialog, click Stop and rerun.

Rerun an application

Stop an application

In the toolbar, click click the Stop button icons actions suspend svg on the toolbar, or press Ctrl+F2. Also, the Stop button is available in the Run tool window.

Stop an application

View running applications

You can list all running applications by selecting Run | Show Running List. If no applications are active, the command is greyed out.

View running applications
Last modified: 29 October 2019