Extracting scripts from these tutorials: Difference between revisions

From CASA Guides
Jump to navigationJump to search
No edit summary
Line 8: Line 8:


# in bash
# in bash
ftp ftp.eg.bucknell.edu
ftp ftp.cv.nrao.edu
# log in anonymously with e-mail as password
# log in anonymously with e-mail as password
cd pub/jgallimo
cd NRAO-staff/jgallimo
get extractCASAscript.py
get extractCASAscript.py
</source>
</source>
Line 18: Line 18:
<source lang="bash">
<source lang="bash">
# in bash
# in bash
wget ftp://ftp.eg.bucknell.edu:/pub/jgallimo/extractCASAscript.py
wget ftp://ftp.cv.nrao.edu:/NRAO-staff/jgallimo/extractCASAscript.py
</source>
</source>



Revision as of 12:58, 30 October 2009

Hopefully the scripts contained in this cookbook are (a) useful and (b) work. They were however developed with CASA still a work in progress, and so scripts may break as commands, arguments, and keywords change. We developed this script extractor to allow us to easily extract scripts from these pages and run them. Feel free to try it!

How to Get the Script Extractor

Download the script extraction code.

# in bash
ftp ftp.cv.nrao.edu
# log in anonymously with e-mail as password
cd NRAO-staff/jgallimo
get extractCASAscript.py

If you have wget installed, this may be faster.

# in bash
wget ftp://ftp.cv.nrao.edu:/NRAO-staff/jgallimo/extractCASAscript.py

How to Use the Script Extractor

Make your newly acquired python script executable.

# in bash
chmod u+x extractCASAscript.py

To run it, issue the python script name and give the URL as the argument. For example:

# in bash
extractCASAscript.py http://casaguides.nrao.edu/index.php?title=Example:_Calibrating_a_VLA_continuum_survey


This command will automatically generate a script called "ExampleCalibratingaVLAcontinuumsurvey.py"

--Jgallimo 14:36, 30 October 2009 (UTC)