Search code examples
phpstorm

Upload files from external library?


I've added my cms as an external library in PhpStorm:

enter image description here

I just wanted to know if there is an option to upload (deploy) these files too? I always have to switch to my cms and open it itself as a project to be able to upload its files.

I've found nothing in the documentation also.


Solution

  • If it's not part of the project root/outside of the project -- then no.

    But you can make it part of the project by:

    • adding it as Additional Content Root (Settings/Preferences | Directories) -- it will be listed as additional node in the Project View panel (similar to actual project's main folder)
    • or just symlink it (e.g. a subfolder inside the project root that is symlink to outside folder).

    Please note that in both cases such folder becomes part of the project so the search routine will take those files into consideration as well as other functionalities (find usages; look for errors in a code; TODO's etc.). You may also accidentally edit your CMS core files and IDE will not tell you anything (in case of External Library it will notify you about this).