strages Posted May 15, 2014 Share Posted May 15, 2014 Dear community, I know how to set my env variable I know how to setup houdini with the commandline etc etc However why do external editors not work with Houdini. I configured sublime text "subl". Even tried pycharm (which is nice), however this blinks and then the opened file has suddenly disppeared. When i push the external editor button, it opens sublime text, with my code in a tmp file like hfs23423-231.tmp.cmd after which i can edit it. However I expect it to stream and live update the edited code back to houdini when pressing cmd-s! who knows what's wrong? Quote Link to comment Share on other sites More sharing options...
strages Posted May 15, 2014 Author Share Posted May 15, 2014 just to clarify cmd-s is ctrl-s - by saving the file. Quote Link to comment Share on other sites More sharing options...
strages Posted May 18, 2014 Author Share Posted May 18, 2014 no body is answering.. Don't know, but i would think this would interest a great bunch of people. Writing python code within Houdini kind of sucks. Being able to do this with an external editor is a big improvement... soo.. Quote Link to comment Share on other sites More sharing options...
magneto Posted May 18, 2014 Share Posted May 18, 2014 (edited) I don't think there is real time editing like you want. If you launch the external editor, Houdini is waiting for that editor to be saved and/or closed to become interactive again. With some clever tricks, you might get it working but python is not the only code, you need to think of VEX too. With Python I know you can have the SOP for example to read from a file on disk, but that would still have to reload. So you could add a Reload button or use the Apply button in the Type properties dialog if you don't mind that. I think the best bet is for SESI to add an advanced editor control like this: http://www.actiprosoftware.com/products/controls/wpf/syntaxeditor It's pretty cheap and you get full source code, but not sure if they would be willing to use a .net control (Winforms, or WPF). It's the most advanced editor control I know of and can support any custom language. It's basically Visual Studio's editor control riding the bike (steroids) If they added this, it would be 100x more fun to write code and expressions. Edited May 18, 2014 by magneto Quote Link to comment Share on other sites More sharing options...
strages Posted May 18, 2014 Author Share Posted May 18, 2014 first thanks for your answer;) If you launch the external editor, Houdini is waiting for that editor to be saved and/or closed to become interactive again. second, although live streaming would be awesome, it was not what i thought it should do. The thing above on which i quote you is exactly the behaviour i expected, but does not happen at mine :S this is what happens: i push alt-e > it opens the external editor (sublime text 3) > it has the code in it i can edit this, but when i save nothing happens or updates within houdini looks good the link Quote Link to comment Share on other sites More sharing options...
strages Posted May 25, 2014 Author Share Posted May 25, 2014 ? Quote Link to comment Share on other sites More sharing options...
Memo Posted May 31, 2014 Share Posted May 31, 2014 Just wondering if you got anywhere with this? Is it possible to hack / mod houdini for it to work properly? I've got my houdini setup with Sublime Text (and this great VEX package for it) but currently the only way I've found it works is: - select your code field in houdini (e.g. wrangle snippet) - press alt-e to open the code window - click on the 'external editor' button on the code window - edit in sublime - close the window and save on exit - click apply in the code window, and only then does it apply. Obviously this is ridiculously unusable. It's easier to just copy paste from sublime into the snippet field! (Which is what i'm currently doing). Surely it can't be too difficult to hack this in to work properly? Quote Link to comment Share on other sites More sharing options...
Alexey Vanzhula Posted June 1, 2014 Share Posted June 1, 2014 (edited) Not so difficult. for me it is: 1. focus code field 2. alt+e twice 3. edit code 4. ctrl+w+enter 5. click on accept button in internal editor strages It doesn`t work with sublime 3, but it works with sublime 2 Edited June 1, 2014 by Alexey Vanzhula Quote Link to comment Share on other sites More sharing options...
Guest mantragora Posted June 1, 2014 Share Posted June 1, 2014 You got bad workflow guys. In your code field you should just put: import FooModule as mantragora reload(mantragora) mantragora.Tools.Foo_Tool() and the rest of the magic happens in your external editor all the time. The script is stored in "scripts/python" folder and you don't have to mess with code field anymore. Quote Link to comment Share on other sites More sharing options...
Alexey Vanzhula Posted June 1, 2014 Share Posted June 1, 2014 You got bad workflow guys. In your code field you should just put: import FooModule as mantragora reload(mantragora) mantragora.Tools.Foo_Tool() and the rest of the magic happens in your external editor all the time. The script is stored in "scripts/python" folder and you don't have to mess with code field anymore. what about 5-10 lines of python expression. i need to create file with module for this? Quote Link to comment Share on other sites More sharing options...
Guest mantragora Posted June 1, 2014 Share Posted June 1, 2014 what about 5-10 lines of python expression. i need to create file with module for this? Original title of this topic mentions editing python "scripts" , not expresions. For 5-10 lines of code I wouldn't even bother with external editor. 1 Quote Link to comment Share on other sites More sharing options...
Alexey Vanzhula Posted June 1, 2014 Share Posted June 1, 2014 And you are right. reloading module is a fastest way Quote Link to comment Share on other sites More sharing options...
ayidi Posted February 4, 2015 Share Posted February 4, 2015 Just wondering if you got anywhere with this? Is it possible to hack / mod houdini for it to work properly? I've got my houdini setup with Sublime Text (and this great VEX package for it) but currently the only way I've found it works is: - select your code field in houdini (e.g. wrangle snippet) - press alt-e to open the code window - click on the 'external editor' button on the code window - edit in sublime - close the window and save on exit - click apply in the code window, and only then does it apply. Obviously this is ridiculously unusable. It's easier to just copy paste from sublime into the snippet field! (Which is what i'm currently doing). Surely it can't be too difficult to hack this in to work properly? I created a plugin that does exactly what you want: https://github.com/ArthurYidi/Houdini-External-Editor Check it out! Quote Link to comment Share on other sites More sharing options...
schiho Posted February 13, 2015 Share Posted February 13, 2015 Hi Arthur, i didn't check it out , possible to provide a video as well? Quote Link to comment Share on other sites More sharing options...
ayidi Posted February 13, 2015 Share Posted February 13, 2015 Hi Arthur, i didn't check it out , possible to provide a video as well? 1 Quote Link to comment Share on other sites More sharing options...
kubabuk Posted March 9, 2015 Share Posted March 9, 2015 For Sublime fans, you should also check out SubTunel which allows to control various scripting contexts (Node, HDAs, shelftools) entirely from Sublime. https://github.com/kubaroth/SubTunnel 1 Quote Link to comment Share on other sites More sharing options...
magneto Posted March 9, 2015 Share Posted March 9, 2015 For Sublime fans, you should also check out SubTunel which allows to control various scripting contexts (Node, HDAs, shelftools) entirely from Sublime. https://github.com/kubaroth/SubTunnel It would be nice if someone integrated inside a Houdini pane using qt Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.