PhpStorm 7.1.0 Web Help

To share your code snippets, you can create gists right from PhpStorm.

Note

Creation of gists in PhpStorm requires that the following preconditions are fulfilled:

  1. The GitHub bundled plugin is enabled.
  2. You have an account on GitHub remote storage, and this GitHub account is registered in PhpStorm.
To create a git gist
  1. In the editor, open the file that contains the snippet to be shared.
  2. Select the code snippet to be shared. If no selection is made, the gist will contain the entire file.
  3. Click the right mouse button anywhere in the editor and choose Create gist on the context menu.
  4. In the Create Gist dialog box, that opens, provide a brief description of the gist to be created and configure the gist's visibility.
    • By default, the new gist will be public, that is, visible for all registered users with your login displayed as owner. To accept this default behaviour, just click OK.
    • To create a private gist that will be available for you only, select the Private check box.
    • To make the gist available for all registered users without displaying your login, select the Anonymous check box.
    • To have the gist opened in the default PhpStorm browser so you can edit it right now, select the Open in browser check box. When you click OK, the https://gist.github.com/ page, that opens, shows the new gist with the selection or the entire contents of the current file. By default, the gist is named after the file the gist originates from. To update the code snippet, if necessary, click Edit.
    • If you do not want to open the gist right now, clear the Open in browser check box. PhpStorm displays the URL address of the gist so you you can access it later.

See Also

Reference:

Version Control:

Web Resources: