IntelliJ IDEA 12.1.0 Web Help

Suppressing deployment (that is, uploading, downloading, and synchronization) for files or folders with sources ensures that the sources are protected against accidental update. When applied to non-sources, it saves system resources because huge amounts of media, caches, or temporal files are no longer copied hither and thither.

You may need to suppress deployment in the following cases:

  1. You are going to work with externally created and uploaded source code. To process these remote sources in IntelliJ IDEA, you have to download them and arrange them in a project. However, there are some sources that you should not update at all. On the other hand, the folders on the remote host also may contain huge amounts of media, caches, temporal files, that you actually do not need in your work.
  2. You have already downloaded the data from the server and arranged them in a IntelliJ IDEA project. However, for this or that reason, you need to have some files or folders on the server protected against deployment, for example, to prevent accidental overwriting.
  3. The local copy of an application contains both source code and other data that you do not need to upload. Besides, you want to protect some sources against overwriting by mistake. In this case, you can suppress deployment for all files and folders that should not be uploaded.

There are two ways to exclude folders from deployment:

Separate files can be protected against deployment only through excluding them by name.

Note

In either case, the exclusion is applied recursively. This means that if the path to a folder is explicitly marked as excluded or the folder name matches the pattern, the contents of all its subfolders, if any, are also protected against deployment.

In this section:

To exclude a folder on server from deployment after project creation, do one of the following:
  • Choose the required folder right in the Remote Host tool window:
    1. On the main menu, choose Tools | Deployment | Browse Remote Host or View | Tool Windows | Remote Host .
    2. In the Remote Host tool window that opens, select the relevant server configuration from the drop-down box.
    3. Select the folder to exclude and choose Exclude Path on the context menu of the selection.
  • Add the required folder to the list of excluded paths:
    1. Open the project settings and click Deployment or choose Tools | Deployment | Configuration on the main menu.
    2. In the Deployment dialog box, switch to the Excluded Paths tab. The tab shows list of previously excluded local and remote folders.
    3. Click the Add deployment path button. An empty line is added to the list.
    4. Click the Browse button browseButton.png. The Select remote excluded path dialog box that opens shows the data on the host accessed through the selected server configuration. Select the required folder.
    5. When you OK, you return to the Excluded Paths tab, where the selected remote folder is added to the list.
To exclude a local folder from deployment
  1. Do one of the following:
  2. In the Deployment dialog box, switch to the Excluded Paths tab. The tab shows list of previously excluded local and remote folders.
  3. Click the Add local path button. In the empty line that is added to the list, specify the location of the folder to be protected against deployment. Type the path manually or click the Browse button browseButton.png and choose the required folder in the dialog that opens.
To have files or folders excluded by name
  1. Do one of the following:
  2. In the Options dialog box that opens, specify the patterns that define the names of these files and folders in the Exclude items by name text box. Use semicolons as delimiters. Wildcards are welcome.

    The exclusion is applied recursively. This means that if a matching folder has subfolders, the contents of these subfolders are not deployed either.

    additional settings:
To get an excluded file or folder involved in deployment again
  • Select the file or folder to return to deployment and choose Remove Path from Excluded on the context menu of the selection.

See Also

Language and Framework-Specific Guidelines:

Reference:

Web Resources: