Helpful Pegasus Commands

You can access your Pegasus account using a remote access program called Putty . You won't have to use Putty to log in to Pegasus too often. But sometimes things aren't acting correctly and its good to be able to look in first hand on the files you think you are dealing with. Here are some basic commands that allow you to control Pegasus. Capitalization is important!

Setting up your web site:
homepagesetup : This command sets up your abaility to host a web site on Pegasus. It creates a new directory called "public_html" and creates a default home page called "home.html"

Viewing Files:
ls : simply lists all files in a directory.
ls -l : longer version of ls. It lists all files as well as the file information, like file size and last date changed and permissions.
ls *.html : lists all html files. The * acts as a wildcard character.
li -l *.jpg : long version of list that lists all jpg files. The * acts as a wildcard character.

Moving around directories:
pwd : display current directory.
cd : Brings you back to your home directory.
cd public_html : takes you to the public_html directory providing that directory is a subdirectory of the current one. (hint - try ls and see if public_html shows up first.)
cd .. : takes you on directory level back up towards topmost one.

Editing Files
pico filename : Pico is a text-only editor. It allows you to edit a file named filename. If the file does not exist it will be created for you.

The commands for Pico can be found at the bottom of the editing screen, but the ones you will use the most are
ctrl^O (save the file) and
ctrl^X (exit the Pico program)
ctrl^v (page down)
ctrl^y (page up)

Note: remember to save your file every ten or fifteen minutes of working so you don't lose anything if something goes wrong.