This help file describes ftp interaction, and the Ftp Menu.
Abstract
The FTP menu allows quick access to files on a remote ftp server, useful
for those that work on many different systems. Files downloaded and opened
in Alpha with the help of the FTP menu are automatically uploaded again
when they are saved. The idea is that the user can have the appearance of
editing files on a remote site. To set this up, all that is needed is the
name of the site, and a valid username and password.
The FTP menu works together with the three ftp clients Interarchy,
Fetch and NetFinder, and with Alpha can actually access ftp servers without
the help of any external client by using the ftp package contained in the
tcllib distribution.
NOTE: If you actually wish to keep the master copies
of some files on your local machine and have them mirrored on a remote
site, then this can be done either through HTML mode's Upload Home Page facility, or for any fileset by activating the Fileset Ftp Mirror package. In this case you will not be using the FTP menu directly, and
this documentation will not be that useful -- it is aimed at situations
where the master copies of files are on a remote system.
Activating the FTP menu
The FTP menu is activated in the dialog
Alpha ↣ Global Setup ↣ Menus
(click here to display the Menus Preferences dialog).
Check the checkbox Ftp Menu among the global menus.
If using Alpha, you must choose either Interarchy, Fetch, or
NetFinder as your ftp helper application. You can select the menu item
Alpha ↣ Global Setup ↣ Helper Applications to set/change your helper app as
necessary.
Click here to display the Helper Applications Preferences panel.
Alpha can act as ftp client itself. To do this, select Use Tcl
Service For Ftp in the WWW pane of the dialog found by selecting Alpha ↣ Preferences ↣ Global Preferences ↣ WWW
and no external helper application is necessary.
Click here to display the WWW Preferences panel.
Basic usage
The first you need to do is to get a list of the files at a remote site. This
can be done by using the menu item Browse Remote…. A dialog is now opened
where you fill in the host, path (optional), user id, and password.
Your ftp client (Interarchy, Fetch, or NetFinder) will now get a listing of the files at the remote site. The list is
displayed in a list dialog.
Selecting a file in the dialog will download it and open it for editing
in Alpha. Once you save the changes, Alpha tells your ftp client to
upload the file.
Selecting a directory in the list (indicated by a trailing / in the
name) will get the listing of that directory and display it in a new
list dialog.
Selecting '..' in the list will get a listing of the parent directory.
A menu item with your remote machine is added to the FTP menu. Selecting
this menu item will display the file list again. This allows you to quickly
download another file from the same place.
Cache
Alpha saves the directory listing in a cache to be able to quickly display
them again without having to download them every time. Whenever new files are
added to the remote site the cache becomes out of date. You can clear the
cache by selecting Flush Cache from the FTP menu. The cache is also flushed
when you quit Alpha. This forces the directory listing to be downloaded
again. If you don't want to use a cache at all, uncheck Use Cache in the
Ftp Utilities submenu.
Mount points
The point where you start browsing a remote site is called a mount point.
There are two types of mount points: temporary and permanent.
Temporary mount points are mount points which only exist during the
current session with Alpha. Whenever you use Browse Remote… to browse a
new site a temporary mount point is created. All temporary mount points
are listed at the bottom of the FTP menu for quick access.
Permanent mount points are mount points which are saved between sessions
with Alpha. You create a new permanent mount point by using
Ftp Utilities ↣ Add Mount Point…. You can
later remove it using Ftp Utilities ↣ Remove Mount Point…. The permanent mount
points are listed in the FTP menu just above the temporary ones.
You can always make a temporary mount point permanent by using the menu item
Ftp Utilities ↣ Make Permanent….
Ftp filesets
An ftp fileset in a set of files in a remote directory, which will be put in a
submenu in the Fileset menu. Selecting a file in the Fileset menu will
download and open it for editing in Alpha.
You create a new ftp fileset by using Create Fileset in the FTP menu or by
using New Fileset… in the Fileset menu and choosing the type ftp.
First you specify a name for the fileset, which will be the name of the
submenu in the Fileset menu, and information about the host, userid etc.
Then you are asked to specify a pattern which determines which files to
include in the fileset, e.g. you may only wish to include all .html
files. This pattern must be entered as a regular expression. Some
examples how to specify the pattern:
.*
all files
.*\.html
all .html files
.*\.[ch]
all .c files and all .h files
You are finally asked if you want to save the fileset. Doing so will
keep it available next time you run Alpha.
Now the listing of the files in the fileset is downloaded and the fileset is
inserted in the menu.
Passwords and Security
Here are a few considerations regarding security you should be aware of:
All passwords which are saved between sessions are saved as plain text in
Alpha's preferences folder. Thus, only give your password when defining
permanent mount points or filesets if nobody else has access to your computer.
If you attempt to open a remote site or file for a mount point or fileset that
has no password, you will be prompted to enter it in a separate dialog. This
password will be remembered until Alpha is quit, or until you select the menu
item Ftp Utilities ↣ Forget Temp Passwords. No temporary passwords are
saved between editing sessions.
Ftp Menu Items
This section lists all menu items in the FTP menu giving a short description
of their functionality.
Edit any previously saved mount point. After editing a mount point, you are
offered the list of all saved mount points again to select another to edit if
desired.
Lets you set default ftp mount point values, including host, directory,
username, and password. Any or all of these values can be set, and will be
used in the initial login dialog. (If you are adding several mount points
at once, the login dialog will remember the values from last one added in this
editing session.)
If checked, all directory listings are stored in a cache. Otherwise, the
remote site is accessed whenever obtaining a listing for a mount point, or to
reload a remote file which has since been closed.
Deletes all files in the cache. The cache is also flushed whenever you quit
Alpha. Note that if you have any currently open remote files, it will only be
possible to save them after flushing the cache by using the Save As At menu
item.
Flush the cache of all temporary passwords remembered this session, those that
Alpha has specifically prompted you for in a separate dialog when attempting
to open a remote site or file.
Please report any problem or bug you encounter in
Alpha's Bug Tracker.
If Alpha launches Fetch from the FTP menu, Fetch occasionally get stuck after
displaying its sign-on dialog. If this happens you have to switch to Fetch
and dismiss this dialog before Fetch continues working. To avoid this problem
completely uncheck "Show sign-on dialog at startup" in Fetch's Misc preference
dialog.
License and Disclaimer
Copyright (c) 2001-2019, the Alpha Community.
All rights reserved.
The Ftp Menu package is free software and distributed under
the terms of the new BSD license:
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.
Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
Neither the name of the Alpha Community nor the names of its contributors
may be used to endorse or promote products derived from this software
without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE ALPHA COMMUNITY BE
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.