Hi Martin,

I know a few ways to do this:

1) If you've set your Mac up to load PDB files with PyMOL by default, you
can just type "open *.pdb" from the command line.

2) Instead of using OS X's open command, you can launch PyMOL directly via
"/Applications/PyMOLX11Hybrid.app/Contents/MacOS/MacPyMOL *.pdb" (you may
have to change that depending on where you have PyMOL installed).

3) From within PyMOL, you can type

from glob import glob
for f in glob.glob("*.pdb"): cmd.load(f)

and it will load them all.


There's more information to be found on the wiki (
http://www.pymolwiki.org/index.php/Launching_PyMOL), including information
on how to set up aliases so that you can just type "pymol" to launch it.
It's worth noting that "pymol -c" will launch PyMOL in batch mode without
the GUI, which may not be what you want.

Cheers,

-Michael


On Wed, Sep 1, 2010 at 9:44 AM, Martin Hediger <[email protected]> wrote:

>  Dear All
> I'm using Mac OS X and would like to start PyMOL from the command line,
> so I can open up .pdb files from a command line argument by issuing $
> pymol -c /directory/*pdb (for some reason, within pymol it seems to be
> not possible to issue 'PyMOL > *pdb').
> When I enter 'pymol' in the Terminal, the Shell freezes and I have to
> kill the process.
> What is required to do so PyMOL becomes launchable from the command line.
>
> Thanks for suggestions.
>
> Martin
>
>
> ------------------------------------------------------------------------------
> This SF.net Dev2Dev email is sponsored by:
>
> Show off your parallel programming skills.
> Enter the Intel(R) Threading Challenge 2010.
> http://p.sf.net/sfu/intel-thread-sfd
> _______________________________________________
> PyMOL-users mailing list ([email protected])
> Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users
> Archives: http://www.mail-archive.com/[email protected]
>



-- 
Michael Lerner, Ph.D.
IRTA Postdoctoral Fellow
Laboratory of Computational Biology NIH/NHLBI
5635 Fishers Lane, Room T909, MSC 9314
Rockville, MD 20852 (UPS/FedEx/Reality)
Bethesda MD 20892-9314 (USPS)
------------------------------------------------------------------------------
This SF.net Dev2Dev email is sponsored by:

Show off your parallel programming skills.
Enter the Intel(R) Threading Challenge 2010.
http://p.sf.net/sfu/intel-thread-sfd
_______________________________________________
PyMOL-users mailing list ([email protected])
Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users
Archives: http://www.mail-archive.com/[email protected]

Reply via email to