4
$\begingroup$

Newbie here. I'm looking for a way to record or save the autogenerated python in the info editor (shown below)

enter image description here

I'm aware of the way to copy the required lines and then save it as a python file through the text editor.

The thing is I believe these lines of code are persistent only for a session and are not found in a saved .blend file. If there is a way to store/export these lines of code, it would make the job of re-creating the scene through code very easy. TIA.

$\endgroup$
3
$\begingroup$

An Addon

There have been some attempts (notably: Macros Recorder ) to make an addon that can record the commands to a textfile. But nothing built in like you might be familiar with in programs like ZBrush, which lets you record a session from start-to-finish.

The info log panel itself

You'll find a lot of repeated commands, and some ommited commands, and some commands that won't work when purely executed from a Text Editor. So even if you get all the output saved, unfortunately, I don't think it will do what you want.

Copy them to Text Editor

You can store a massive amount of data in bpy.data.texts, which you can access from Blender Text Editor. When saved that data will persist in the .blend until you manually delete it.

With the mouse cursor inside the Info panel and when you have the desired lines selected:

  • copy them to clipboard ( Ctrl + c )
  • open Text Editor, press + on the UI to create new Text File
  • Paste ( Ctrl + v )
  • Help your future self by giving the text file a good name.
  • save the .blend

If all you want to do is get an idea about the operators you called during the modelling process, then I think those steps are the literal answer to your question. I don't recall seeing an addon that does that, so I made one.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.