BUILDING A GOPHER Abbie J. Basile Miami University Libraries, 8/94 abbie@watson.lib.muohio.edu Creating a Gopher, like using a Gopher, does not require advanced knowledge of computing. However, advanced planning as to the Gopher's structure and general content will make the task easier. Before any Gopher menus are created, it might be wise to map out a directory, which will be the basis for your Gopher's menu structure. This handout will cover the three basic parts of Gopher construction: I. Pointing to remote resources using a .links file II. Finding .links information III. Creating meaningful menu labels for local files using a .cap file I. POINTING TO A REMOTE RESOURCE By using a .links file, you can create connections to resources available on the Internet. A .links file contains the following information: Name=I Have a Dream - MLK (this line will appear on the Gopher menu) Type=0 (one of several types, see Gopher Types sheet) Port=70 (70=the default, but it depends on the resource) Path=/subj/history/civil/mlk (directory location on the remote computer) Host=moon.lib.acme.edu (full internet address of remote computer) You can create a .links file in any Gopher directory in which you want to include pointers to remote resources. You can have a single .links file in a directory which contains links for several resources. For example, here is only PART of the .links file from my gopher's History directory: Name=Electronic Sources for West European History & Culture, Welch Type=0 Port=70 Path=ftp:dewey.lib.ncsu.edu@/pub/stacks/guides/european-guide Host=dewey.lib.ncsu.edu Name=History Info System (U Kansas - HNSOURCE) Type=8 Port=23 Path= Host=hnsource.cc.ukans.edu Name=Historical Documents Type=1 Port=3001 Path=1/.stacks/.historical Host=ucsbuxa.ucsb.edu .Links files may also contain a sixth line (Numb=) when you want to override the default alphabetical display of the Gopher menu items. For example, the following item would appear on the menu as #1, even though it begins with the letter R. Name=Rwanda News Updates Numb=1 Type=1 Port=70 Path=/rwanda Host=abc.solar.edu The following examples are .links for pointers to an entire Gopher, specific sections of a Gopher, and Telnet sites. (For .link to FTP SITES, see the following: Name=Creating Links to Other Resources Type=0 Port=70 Path=0/About_USCgopher/manual/link_info Host=cwis.usc.edu. EXAMPLES OF GOPHER/TELNET .LINKS: TOP LEVEL OF ANOTHER GOPHER-- Name=Library of Congress (LCMARVEL) Type=1 Port=70 Path= Host=marvel.loc.gov NOTE: Path= is usually left empty for .links file which are connections to the top level of another Gopher. FILE OR DIRECTORY ON ANOTHER GOPHER-- Name=Women's Studies Resources Type=1 Port=70 Path=/women Host=info.umd.edu TELNET CONNECTIONS TO OTHER SYSTEMS-- Name=ERIC Database (1983 - present) Type=8 (Telnet are type 8) Port=23 (23 is default Telnet port) Path=username=SONIA, select item 4 from Menu (can list login info) Host=info.usask.edu NOTE: Files and directories which begin with a dot (e.g., .links) are hidden from Gopher menu displays. II. FINDING .LINKS INFORMATION 1. Many Gopher-related mailing list/Usenet announcements will contain the necessary .links information in the above format. That makes life easy. ( See "Gopher Information Resources" handout.) 2. Press the = key when you are using the Gopher to display the .links info. (Note: for TurboGopher, press the i and the command keys simultaneously.) III. CREATING MEANINGFUL MENU LABELS In addition to making pointers to remote resources, you may also want your Gopher to include information which is stored on your local server. Let's say you have a file which contains contact information for subject bibliographers in your library. The name of this file is lib.contacts. The filename assigned to such files will also appear on the Gopher menu. .Cap files allow you to create a meaningful label for files - and this label will appear on the Gopher menu in place of the file's actual filename. A .cap directory can be created in any Gopher directory. It is important that the .cap files and the files which are being labelled use the SAME filename. This allows the computer to match the file to its "improved" menu label. Let's say you have a file in one of the Gopher directories called lib.contacts, but you want the menu label for this file to be "Library Subject Specialists." You would do the following: TO CREATE A GOPHER MENU LABEL FOR THE lib.contacts FILE: 1. Create a .cap subdirectory in the same directory where the file is located. 2. Create a .cap file in that .cap directory. This .cap file MUST have the SAME name as the file for which you're creating a menu label. EXAMPLE: Note: A) lib.contacts is located in the /usr/local/gopher-all/libinfo subdirectory. B) vi is the UNIX editor I use to create and edit files. C) The text in brackets are the commands you type to perform this task. LEAVE OUT the brackets when you are actually doing this process. /usr/local/gopher-all/libinfo>[mkdir .cap] (this creates a .cap directory) /usr/local/gopher-all/libinfo>[cd .cap] (this changes your working directory location to the .cap directory.) /usr/local/gopher-all/libinfo>[vi lib.contacts] (this creates a .cap file of the same name as the file I'm labelling.) Name=Library Subject Specialists (this is the text of the actual .cap file. Everything after = will appear on menu.) The following is an example of a Gopher Directory Tree. It should help you to understand the location of the various directories, subdirectories and files. DIRECTORY TREE EXAMPLE: /usr/local/gopher-all/libinfo libinfo (directory) -------> .links (file) (includes pointers to remote documents) -------> lib.contacts (file) (a text file of subject specialists' names) -------> .cap (directory) (a directory of .cap files) libinfo/.cap (directory)------> lib.contacts (a .cap file for lib.contacts file which will give it a nice menu label)