Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
When you don't supply the height for -size when using the caption command and just the width, the height is automatically determined for your image/text which is great and really glad it's capable of doing this, but what if I want to find out what the height from the caption command will be without having to write the image to disk but to memory instead so that I can use the height for something else?
Your bash command has bad syntax. It must end with an output filename (which could be "info:"). Within the command, you can "+write info:" at any time.
To capture the single-line output from a bash command, use backtick, like this: