love-IDEA-plugin icon indicating copy to clipboard operation
love-IDEA-plugin copied to clipboard

Run love scripts from IntelliJ

Open rickmeister opened this issue 8 years ago • 1 comments

Not really an issue, but maybe you should point this out to new Idea users.

To be able to run love applications from the IDE you can select "Edit Configurations..." from the "Run"-menu. Click the '+' sign and select "Lua Script"

Edit script name to "main.lua", and uncheck "Use Module SDK". In the text field next to the checkbox enter the path to your love executable (/usr/bin/love on linux, don't know where it's located on lesser OS;es). In the "Interpreter Options" field just enter a single '.'

Now you can run Löve scripts from inside the IDE, and it just makes life so much easier :)

rickmeister avatar Jan 16 '17 06:01 rickmeister

another option:

Program: C:\path_to_your_love_folder\love.exe Working directory: . Parameters: type_your_project_working_dir here

D0NM avatar Jul 23 '18 06:07 D0NM

For anyone wondering how to do it with Intellij in 2022 (on Windows), it's a bit different but it works too.

Make sure you have EmmyLua installed. After clicking the "+" button, choose Lua Application. For "Program" you choose your love.exe (you can find it usually in "C:/Program Files/LOVE"). Working directory is your src folder. For "Entry File" you write "main.lua" (without the quotation marks). And for "Parameters", as @rickmeister said, you need to put a single dot "." (without the quotation marks).

You should now be able to run love2d programs from your Intellij 2022.

Thanks @rickmeister for your tips.

igorr0driguez avatar Jan 20 '23 18:01 igorr0driguez