From: John Stone (johns_at_ks.uiuc.edu)
Date: Thu Jan 25 2007 - 02:01:12 CST

Hi,
  Try replacing the ~ character with the rest of your fully qualified
pathname. You'll also want to source the script manually, to force
load it regardless whether the normal version has been loaded already.
I'd add a "puts" command in there to make it easy to see that you're using
your modified version rather than the standard one. Give that a try
and see if it works for you.

  John Stone
  vmd_at_ks.uiuc.edu

On Wed, Jan 24, 2007 at 12:54:51PM +0100, Himanshu Khandelia wrote:
> Can anyone please advise me how to alter the membrane.tcl script to use it
> from my own user-defined directory location ? I tried to make the
> following changes in the section of the script where I thought the
> directory locations were specified. But this did not work.
>
> ################
> # set package WD and files
> global env
> if ([info exists env(MEMBRANEDIR)]) {
> # set psffile $env(MEMBRANEDIR)/${lipid}_box.psf
> # set pdbfile $env(MEMBRANEDIR)/${lipid}_box.pdb
> # set topfile $env(MEMBRANEDIR)/top_all27_prot_lipid.inp
> set pdbfile ~/${lipid}_box.pdb
> set psffile ~/${lipid}_box.psf
> set topfile ~/top_all27_prot_lipid.inp
> } else {
> # set psffile [file normalize [file dirname [info
> script]]]/${lipid}_box.psf
> # set pdbfile [file normalize [file dirname [info
> script]]]/${lipid}_box.pdb
> # set topfile $env(MEMBRANEDIR)/top_all27_prot_lipid.inp
> set pdbfile ~/${lipid}_box.pdb
> set psffile ~/${lipid}_box.psf
> set topfile ~/top_all27_prot_lipid.inp
> }
> set tempfile temp
> ################
>
> P.S: I was not able to modify the topology file or the membrane.tcl script
> in its original location
> (/usr/local/lib/vmd/plugins/noarch/tcl/membrane1.0/) because of permission
> problems.
>
> Thank you very much for the help,
>
> -Himanshu

-- 
NIH Resource for Macromolecular Modeling and Bioinformatics
Beckman Institute for Advanced Science and Technology
University of Illinois, 405 N. Mathews Ave, Urbana, IL 61801
Email: johns_at_ks.uiuc.edu                 Phone: 217-244-3349
  WWW: http://www.ks.uiuc.edu/~johns/      Fax: 217-244-6078