GoLand 2024.2 Help

Share code with GitHub gists

Gists let you share code snippets, entire files, or even applications. You can also use gists to save and share console output when running, debugging, or testing your code.

Each gist is a repository that can be cloned or forked by other people.

Create a gist

  1. Select a code fragment in the editor, or files and folders in the Project tool window. To save console output to a gist, right-click anywhere in the tool window or tab that contains that output.

  2. From the context menu of the selection, choose Create Gist.

  3. In the Create Gist dialog, specify the name for your gist under Filename, and enter a description of the code you are going to publish.

  4. Select the Secret option to create a secret gist. Secret gists are not searchable and do not show up in Discover. They can only be used for your own purposes, as you cannot share them.

    If you want to create a public gist, make sure this option is deselected. Public gists are searchable, and they show up in Discover where people can browse newly appearing gists. Use public gists if you want other people to be able to find and see your code.

  5. If you want to open the newly created gist in your default browser, select the Open in browser option and click OK.

Last modified: 07 May 2024