BlackStartx / PyCharm-Blender-Plugin

A PyCharm Plugin that simplify the development of Blender Add-On inside the PyCharm IDE.
MIT License
151 stars 12 forks source link

'exe' dependency for adding instance #10

Open daidalos42 opened 2 years ago

daidalos42 commented 2 years ago

Hello BlackStartx,

tried to get your plugin working in osx, unfortunately it didn't work. Found in the …/scr/main/java/data/BlenderExeFileChooserDescriptor.java that it only takes *.exe as instance. Would it be possible to comment out the dependency to see if it also runs on the mac version of blender? Unfortunately I don't know java to be able to do something with the source code myself…

Thanks, it would be great to hear from you. daidalos42

BlackStartx commented 2 years ago

Hi Daidalos~

First of all thanks for sharing this out and sorry for the issue! The project started as a personal tool and so it's not cross-platform safe.

I will dig in to this and develop a fix as soon as I'm back home, meanwhile may I ask what extension does Blender have on osx?

Thanks in advance!

daidalos42 commented 2 years ago

Thank you for reaching out to this issue.

MacOS takes *.app as executable but that is just a folder pointing further down to a unix file without extension. Here is a example of the full unix path.

…/Applications/Blender.app/Contents/MacOS/Blender

Maybe to just add 'app' will be sufficient, could work out of the file open dialog. Starting from the GUI is double click to execute the Blender.app 'folder'. To start Blender from within a terminal session you need to paste the full path from above.

Hope this is understandable.

Although this was just a personal project from you it adds a great functionality to connect Blender and PyCharm. Thank you for taking the effort and decide to make it public.

BlackStartx commented 2 years ago

Interesting, thanks for the info!

I will share here a version in a week with the .app extension added in to the list. Meanwhile you may try to set the path manually by pasting it in to the field to see if it works.

Let's see itf that works! ^-^

daidalos42 commented 2 years ago

Worked!

Pasted the full path, blender started on hitting run. Full standard path:

/Applications/Blender.app/Contents/MacOS

Thank you for the advice.

rip2019 commented 1 year ago

/Applications/Blender.app/Contents/MacOS/Blender Do not forget /Blender after MacOS

louhy commented 1 month ago

It's a problem for Linux also. Blender's executable has no extension. But unlike the OP I do know Java... is this repo still supported? If I can get this working sufficiently on Linux maybe I could do a pull request to fix it, if it would be accepted. (And assuming I can get the plugin to work at all.)

I was able to get it to accept the correct path by skipping the file selector and just pasting in the full path to the binary into the text field.

For a Flatpak install on Linux this is a likely path: /var/lib/flatpak/app/org.blender.Blender/current/active/files/blender/blender

But there are other possibilities, including apparently using Steam to install it. I would just open up file selection to any location and any extension, including no extension.

BlackStartx commented 1 month ago

Hi Louhy~ 🌺

I'm currently in vacation, so the 2024.2 version is paused for the moment. I'll be back working on it from tomorrow! 👍🏻

There has been a lot of changes in IntelliJ SDK Plugins for 2024.2 and I'm currently migrating stuff, sorry if this is taking longer than other versions.

Anyway, if you wanna make a PR it's just fine~ ^-^ (I'll make sure to implent it in 2024.2 too)

louhy commented 1 month ago

That's cool, no rush at all, the paste workaround worked. Thanks for the efforts supporting this!