Giter VIP home page Giter VIP logo

Comments (9)

JacquesLucke avatar JacquesLucke commented on August 11, 2024

Yeah, the code back then was much uglier than now because I just started learning typescript. Should be better now. :)

Thanks for the provided fix. Is it not possible to select the actual binary when you are asked to select the executable?

Will blender always be packaged like that or is this path different for different people?

Can command line arguments be passed to "open" that are forwarded to the application? I'm not sure how well that works in the task system of vs code. Would be nice if you could try that. I guess if it works, using "open" is the preferable solution because it makes less assumptions about the system.

from blender_vscode.

JacquesLucke avatar JacquesLucke commented on August 11, 2024

Or we could check if the selected file ends with .app, and if yes, /Contents/MacOS/blender can be added to the path.

Looks like this path is always the same: https://developer.apple.com/library/archive/documentation/CoreFoundation/Conceptual/CFBundles/BundleTypes/BundleTypes.html#//apple_ref/doc/uid/10000123i-CH101-SW1

from blender_vscode.

simsod avatar simsod commented on August 11, 2024

in Finder you can right click and do "Show package contents", but that is not available in the open-dialog from vscode atleast.

AFAIK blender is always packaged in a .app when released to OSX, and the path is always blender.app/Contents/MacOS/blender

not sure how it is launched when compiling/debugging the blender sourcecode itself though, I havent dived that far into blender :)

since osx 10.6 you can pass arguments to the 'open' command using --args but I don´t think that is used very widely.

I recently helped solve a bug with machin3tools (for 2.8) regarding osx compatibility (he got the path wrong when reading keymaps inside his plugin) he used this code to solve the issue:

keymappath = os.path.join(bpy.utils.preset_paths(subdir='keyconfig')[0],'blender_27x.py')
inside blender that code returns the blender.app/Content/Resources/.... folder.

yeah your comment from 44secs ago seems like a good solution

from blender_vscode.

JacquesLucke avatar JacquesLucke commented on August 11, 2024

https://wiki.blender.org/wiki/Building_Blender/Mac

The last screenshot there indicates that Blender is packaged in the same way when Blender is build from source code.

from blender_vscode.

JacquesLucke avatar JacquesLucke commented on August 11, 2024

Can you check if the provided fix works, please?

from blender_vscode.

simsod avatar simsod commented on August 11, 2024

Works like a charm!

btw, do you really need the ms-vscode.cpptools as an extension dependency?
Its only used for some use-cases which you barely "support" right now right?

from blender_vscode.

JacquesLucke avatar JacquesLucke commented on August 11, 2024

Thanks.

No, I don't really need it right now... Added it before I was sure which features I will support for now.
Does it cause trouble for you?

from blender_vscode.

simsod avatar simsod commented on August 11, 2024

nah, well, since its a dependency you have to install it in order to activate the blender-vscode plugin
Which seems unnecessary if you aren´t doing any cpp development but I guess it´s fine :)

from blender_vscode.

JacquesLucke avatar JacquesLucke commented on August 11, 2024

True, I'll probably add this dependency back soon anyway, so not sure if I should remove it now.
Will decide before I publish the next version.

from blender_vscode.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.