gale.org
Home > Documentation > for Users > Tutorial

What Is This Thing, Anyway?

Gale is a set of programs that lets Internet users send messages to each other. These messages can be anything from "Hi there!" to "I can't get my foobar to work, can anyone help me?" to "Anyone in Springfield want to see a movie tonight?". What sets Gale (and its ilk) apart from e-mail (and its ilk) is that Gale messages are "real-time (or "instant"). After you send a message with Gale, it usually appears on the screen of its recipient(s) within a second or two; they can then compose a reply and respond just as quickly. These messages are usually short, and are displayed in their entirety on your screen as soon as they're received.

As a result, instant messaging systems like Gale are good for quick, time-critical notifications, rapid planning, and real-time "chat". They're not good for lengthy correspondence or for messages best read at the recipient's leisure.


Fine. How do I use it?

Gale is based on a subscription model. Gale users "subscribe" to messages; as long as they're subscribed, the system will tell them when someone sends them a message. You can subscribe to messages by running the program "gsub":

% gsub
! 1999-10-23 16:05:02 gsub notice: requesting key "someone@example.com"
! 1999-10-23 16:05:23 gsub notice: generating keys, please wait...
! 1999-10-23 16:05:23 gsub notice: saving private key in "/home/someone/.gale/au
th/private/someone@example.com"
! 1999-10-23 16:05:23 gsub notice: saving signed public key in "/home/someone/.g
ale/auth/local/someone@example.com"
! 1999-10-23 16:05:23 gsub notice: done generating keys
! 1999-10-23 16:05:23 gsub notice: connected to example.com (12.34.56.78:11512)
%  


(Type the boldface text yourself; the system prints everything else.)

It takes a while to start the first time you do this; be patient, it won't take nearly as long next time. You may not get exactly the same output; if nothing else, you will see your own username and hostname instead of "someone@example.com". Don't worry about most of the "gsub notice" stuff for now, but do make sure the last line ("connected to ...") is present. If it's not, contact your system administrator.

If all went well, the gsub program has connected to the "gale server" (and indirectly to the rest of the Gale-using internet), subscribed to your messages, and gone into the background so that you can continue using the shell. When you get messages, it will display them on the terminal. (Watch out; when it does so, it can overwrite whatever you're doing. If you get a lot of Gale messages, you might not want to use the shell where you started "gsub" to do a lot of work. If you do get a message at an inopportune time, you can usually clear it away with control-L to return to your work.)

Since you need to run "gsub" to receive Gale messages, you might want to consider running it automatically when you log in (with your ".login", ".zprofile", or whatever). If you run it twice in the same terminal, the new "gsub" replaces the old one. To stop subscribing to messages, run "gsub -K". (See the gsub reference for more on using "gsub".)


Sending Messages

To show how the system works, let's send a message to yourself. You use the "gsend" program to send messages; supply it with the username and (if not the same as your own) hostname of the recipient. If your username is "someone", you might enter the following:

% gsend someone
Private message for someone@example.com in [@example.com/user/someone/]:
(End your message with EOF or a solitary dot.)
Hi there, self!  How are you?
.
Message transmitted.
------------------------------------------------------------------------------- 
[@example.com/user/someone/] from Some Body to Some Body [rcpt]
Hi there, self!  How are you?
        -- <someone@example.com> for <someone@example.com> at 10-23 16:17:03 --
%  

Make sure to type the period (".") on a line by itself after entering your message; that signals "gsend" that you've finished. As you can see, as soon gsend transmits the message, it's printed out on your screen (by the "gsub" you started earlier). Now, it's not very useful to send messages to yourself; if you know someone else who uses Gale, you can try sending messages to them and having them send messages to you. Just enter the name of the user on the "gsend" command line! (See the gsend reference for more on using "gsend".)

When a message you send is received by a different user, your gsub will receive and print a "receipt", which looks like this:

* 1999-10-23 16:50:34 received: in/present <someone@example.com> (Some Body)
                                                                                

Receipts are used to tell you that the message was successfully received. If you don't get one, it may be that the user isn't logged in, or isn't subscribed to Gale messages (hasn't run "gsub"). You don't get receipts for messages you send yourself.


Gale addresses

One of Gale's features is the ability to exchange instant messages with any other Gale user on the Internet. While you can use "gsend" to send a message to someone on your local system by specifying their username, to find someone at another site you need to know their full "gale address". A gale address is very much like an e-mail address:

User
someone

@
Domain name
example.com

In fact, for many people, their gale address is the same as their e-mail address. Take note of the address printed by the system when you sent yourself a message; it listed your own gale address when it said "Private message for (address) ...". Anyone on the Internet using Gale can use this address to send you a message, as long as you have "gsub" running!

How do you find someone else's address? Well, you can simply ask them. Or, if they send you a message first, you'll see their address at the end of the message ("-- <(address)> for ..."). If you don't have any better ideas, just try their e-mail address; it might just work. Remember, though, if they're not subscribed, they won't get your messages.


Unwashed Masses

If all went well, you should now be able to exchange messages with any Gale-using individual on the Internet. However, sometimes you may wish to address a larger community of users. You can use several gale locations on the gsend command line ("gsend someone@example.com other@example2.com"), but even this won't suffice for larger interest groups. Instead, where an e-mail user would create a mailing list or move to a newsgroup, a Gale user uses "public categories".

Public categories use the same "gale domains" that gale addresses do. Instead of a username, a public category includes a "local part" that describes a topic:

Local part
sports.baseball.mets

@
Domain
example.com

When you subscribe to Gale, in addition to receiving your own personal messages, you can also choose to listen to one or more public categories. You can use the location "new@gale.org" as a testbed; use this to subscribe to that location:

% gsub new@gale.org
! 1999-10-23 16:10:27 gsub notice: connected to example.com (12.34.56.78:11512) 
%                                                                                

You are now subscribed to your personal messages (as before) as well as the public category you specified. You can now send a message to this category:

% gsend new@gale.org
To: new@gale.org
(End your message with EOF or a solitary dot.)
Hello Gale World!
                                                                                

Now you're getting good at sending messages to yourself, aren't you? However, in this case, you also sent the message to anyone else who was subscribed to the same public category. (If you're lucky, someone else was following this tutorial at the same time!) While this may not seem useful in this case, topical public categories let you chat with open groups of like-minded people.


Category Madness

The local part of a location is "hierarchical". If you subscribe to "sports.baseball@example.com", you will also receive messages sent to "sports.baseball.mets@example.com" (but not messages sent to "sports.football@example.com"). Furthermore, you can subscribe to many public categories at once, by listing them on the gsub command line:

% gsub new@gale.org flying.bunnies@other.com spiffy@mydomain.com
! 1999-10-23 16:10:27 gsub notice: connected to example.com (12.34.56.78:11512) 
%                                                                                

You may also use "negative subscriptions" to filter out subcategories you would otherwise receive but have no interest in. For example, if you're an all-round sports nut, you might subscribe to our hypothetical "sports@example.com". But perhaps, over time, you become weary of the incessant ranting in "sports.football@example.com", but you still want to receive the rest. To turn off a location, prefix its name with a minus ("-"):

% gsub sports@example.com - sports.football@example.com
! 1999-10-23 16:10:27 gsub notice: connected to example.com (12.34.56.78:11512) 
%                                                                                

(Note the space between the minus and the negated location.)

See the documentation on categories and subscriptions for more information about how categories and subscriptions work. (For example, it's possible to send a message to more than one location at once.) You may also wish to read the gsub reference to learn how to configure gsub to subscribe to your favorite locations by default.


OK, where do I find some?

This information is all well and good, but public categories aren't useful unless you can actually find the locations that people are using. To that end, you can find directories of well-known locations, along with explanations of the various naming conventions people use and general Gale netiquette guides, at the Gale web site.


More information

Hopefully, this tutorial will help you start using Gale. To get the most out of the system, you can read the rest of the user manual. If you need to understand how to install Gale software and operate gale domains, see the administrators' guide; this material may also be useful to users who need to troubleshoot configuration problems. Finally, if you really want to get into the nuts and bolts of Gale, you can dive into the architecture guide.

Happy puffing!