How do I use phalcon-devtools\ide\phpstorm in phpstorm?

后端 未结 4 1401
一整个雨季
一整个雨季 2021-01-31 10:49

I am trying to integrate the Phalcon developer tools with phpstorm. There is a video here, but I am unable to view it due to my location.

I can\'t find any other usable

4条回答
  •  挽巷
    挽巷 (楼主)
    2021-01-31 11:49

    Here are the steps.

    • Make sure you have the phalcon-devtools installed Instructions
    • Create a project using phalcon-devtools (unless you already have a project)
    • Launch PHPStorm and create the project there (unless you already did that).
    • Click File-Settings (Ctrl+Alt+S) (or PHPStorm-Preferences for Mac)
    • Click the second option "Command Line Tool Support"
    • Click the + icon and a new popup comes up. Make sure you have "Custom Framework" selected
    • In the new popup type:

      Framework: Phalcon

      Tool path: /Applications/MAMP/htdocs/phalcon-tools/ide/phpstorm/phalcon.sh

      Alias: phalcon

      Description: Phalcon Developer Tools

    This assumes that your phalcon-tools have been installed under:

    /Applications/MAMP/htdocs/phalcon-tools/
    

    Also if you use a Windows environment, you should use phalcon.bat instead of phalcon.sh (see Tool Path line above)

    • Click Apply and then OK.
    • Click Tools - Run Command (Ctrl+Shift+X)
    • In the Commands output window, type:

      phalcon commands

    You should be able to see output. If there is an error check your path. Type any of the phalcon-tools commands to generate components for your project.

    • In PHPStorm you should see in the project explorer "External Libraries". Right mouse click and select "Configure PHP Include Paths"
    • In the new dialog click the + and navigate to the /Applications/MAMP/htdocs/phalcon-tools/ide/phpstorm/0.5.0 folder and click OK.

    Now as you type code, the relevant helper popup will appear with all the relevant functions.

    2012-09-07: There is a beta implementation of the Phalcon PHPStorm support for 0.5.0 here. In the upcoming weeks the code will become part of the framework and included with the 0.5.0 version.

提交回复
热议问题