home *** CD-ROM | disk | FTP | other *** search
- cd /home/rlm/src/ungeek/
- diff -c /home/rlm/src/ungeek/ungeek1.1 /home/rlm/src/ungeek/ungeek
- *** /home/rlm/src/ungeek/ungeek1.1 Tue Feb 1 05:55:15 1994
- --- /home/rlm/src/ungeek/ungeek Tue Feb 1 05:55:02 1994
- ***************
- *** 7,13 ****
- # Send comments, corrections, and bugs to <rlm@helen.surfcty.com> or
- # <rlm@netcom.com>.
- #
- ! # This is version 1 of ungeek for v1.0.1 of the Geek code.
- #
- #
- # Abstract:
- --- 7,13 ----
- # Send comments, corrections, and bugs to <rlm@helen.surfcty.com> or
- # <rlm@netcom.com>.
- #
- ! # This is $Revision: 1.2 $ of ungeek for v1.0.1 of the Geek code.
- #
- #
- # Abstract:
- ***************
- *** 66,72 ****
- --- 66,83 ----
- # tastes.
- #
- #
- + # Revisions:
- #
- + # $Log: ungeek,v $
- + # Revision 1.2 1994/02/01 13:55:02 rlm
- + # Make slash forms with null right hand sides pass valid_code. Minor
- + # fixes. Support null geek code ranges (forms like !d(), for instance).
- + # Fix a bug in the dress attribute that confused dress_strength into
- + # thinking that -d+ was really d+++... off to infinity. Add RCS
- + # headers.
- + #
- + #
- + #
- # Copyright notice:
- #
- # The Geek Code is copyright 1993 by Robert A. Hayden. All rights reserved.
- ***************
- *** 81,90 ****
- sub computer_strength
- {
- $_=$_[0];
- ! if($_ eq "no modifier")
- {
- print "
- ! Computers are a tool, nothing more. I use it when it serves
- my purpose.\n";
- }
- elsif ($_ eq "+")
- --- 92,101 ----
- sub computer_strength
- {
- $_=$_[0];
- ! if($_ eq "")
- {
- print "
- ! Computers are a tool, nothing more. I use one when it serves
- my purpose.\n";
- }
- elsif ($_ eq "+")
- ***************
- *** 159,164 ****
- --- 170,192 ----
- print "
- I dress a lot like those in WalMart ads.\n";
- }
- + elsif ($_ eq "d?")
- + {
- + print "
- + I have no idea what I am wearing right now, let alone
- + what I wore yesterday.\n";
- + }
- + elsif ($_ eq "!d")
- + {
- + print "
- + No clothing. Quite a fashion statement, don't you think?\n";
- + }
- + elsif ($_ eq "-d+")
- + {
- + print "
- + I wear the same clothes all the time, no matter the
- + occasion, often forgetting to do laundry between wearings.\n";
- + }
- elsif ($_ eq "+")
- {
- print "
- ***************
- *** 201,223 ****
- the last time I washed them. Fortunately, all the management here
- smokes, and they can't find what they can't smell.\n";
- }
- - elsif ($_ eq "d?")
- - {
- - print "
- - I have no idea what I am wearing right now, let alone
- - what I wore yesterday.\n";
- - }
- - elsif ($_ eq "!d")
- - {
- - print "
- - No clothing. Quite a fashion statement, don't you think?\n";
- - }
- - elsif ($_ eq "-d+")
- - {
- - print "
- - I wear the same clothes all the time, no matter the
- - occasion, often forgetting to do laundry between wearings.\n";
- - }
- else
- {
- print "
- --- 229,234 ----
- ***************
- *** 347,353 ****
- print "
- I *think* I have friends.\n";
- }
- ! elsif ($_ eq "f*")
- {
- print "
- Everyone is my friend.\n";
- --- 358,364 ----
- print "
- I *think* I have friends.\n";
- }
- ! elsif ($_ eq "*")
- {
- print "
- Everyone is my friend.\n";
- ***************
- *** 599,605 ****
- {
- print "
- I eat only the cheap things - even with artificial meat and
- ! vegetables.";
- }
- elsif ($_ eq "---")
- {
- --- 610,616 ----
- {
- print "
- I eat only the cheap things - even with artificial meat and
- ! vegetables.\n";
- }
- elsif ($_ eq "---")
- {
- ***************
- *** 615,621 ****
- sub nutrition_parse
- {
- $_ = $_[0];
- ! if (/n(\++|-+|\*|)/o) { &nutrition_strength($1);}
- elsif (/!n/) { &nutrition_strength("!n");}
- else { &nutrition_strength("huh?");}
- }
- --- 626,632 ----
- sub nutrition_parse
- {
- $_ = $_[0];
- ! if (/n(\++|-+|\*)/o) { &nutrition_strength($1);}
- elsif (/!n/) { &nutrition_strength("!n");}
- else { &nutrition_strength("huh?");}
- }
- ***************
- *** 703,709 ****
- elsif ($_ eq "+++")
- {
- print "
- ! I worship E. Gary Gygax.\n";
- }
- elsif ($_ eq "-")
- {
- --- 714,720 ----
- elsif ($_ eq "+++")
- {
- print "
- ! I worship E. Gary Gygax.\n";
- }
- elsif ($_ eq "-")
- {
- ***************
- *** 731,737 ****
- sub height_strength
- {
- $_ = $_[0];
- ! if ($_ eq "+")
- {
- print "
- I'm a little taller than most.\n";
- --- 742,753 ----
- sub height_strength
- {
- $_ = $_[0];
- ! if ($_ eq "")
- ! {
- ! print "
- ! I'm a geek of about average height.\n";
- ! }
- ! elsif ($_ eq "+")
- {
- print "
- I'm a little taller than most.\n";
- ***************
- *** 772,778 ****
- sub width_strength
- {
- $_ = $_[0];
- ! if ($_ eq "+")
- {
- print "
- I'm a little rounder than most.\n";
- --- 788,799 ----
- sub width_strength
- {
- $_ = $_[0];
- ! if ($_ eq "")
- ! {
- ! print "
- ! I'm a geek of average weight.\n";
- ! }
- ! elsif ($_ eq "+")
- {
- print "
- I'm a little rounder than most.\n";
- ***************
- *** 813,829 ****
- {
- $_ = $_[0];
- s/s//;
- ! if ($_ eq "")
- ! {
- ! print "
- ! I'm an average geek.\n";
- ! }
- ! else
- ! {
- ! @s=split(/\//o);
- ! &height_strength($s[0]);
- ! &width_strength($s[1]);
- ! }
- }
-
- sub star_trek_strength
- --- 834,842 ----
- {
- $_ = $_[0];
- s/s//;
- ! @s=split(/\//o);
- ! &height_strength($s[0]);
- ! &width_strength($s[1]);
- }
-
- sub star_trek_strength
- ***************
- *** 861,867 ****
- print "
- Maybe it is just me, but I have no idea what the big deal
- with Star Trek is. Perhaps I'm missing something but I just
- ! think it is bad drama.";
- }
- elsif ($_ eq "--")
- {
- --- 874,880 ----
- print "
- Maybe it is just me, but I have no idea what the big deal
- with Star Trek is. Perhaps I'm missing something but I just
- ! think it is bad drama.\n";
- }
- elsif ($_ eq "--")
- {
- ***************
- *** 1113,1122 ****
- sub sex_parse
- {
- $_ = $_[0];
- ! if (/[xy](\++|-+|\*+|)/o) { &sex_strength($1);}
- ! elsif (/![xy]/) { &sex_strength("!x");}
- ! elsif (/[xy]?/) { &sex_strength("x?");}
- ! else { &sex_strength("huh?");}
- }
-
- sub valid_code
- --- 1126,1135 ----
- sub sex_parse
- {
- $_ = $_[0];
- ! if (/![xy]/) { &sex_strength("!x");}
- ! elsif (/[xy]\?/) { &sex_strength("x?");}
- ! elsif (/^[xy](\++|-+|\*+)/o) { &sex_strength($1);}
- ! else { &sex_strength("huh?");}
- }
-
- sub valid_code
- ***************
- *** 1151,1158 ****
- #
- # still have leftovers, so try to eat right hand forms
- #
- ! s/^(\/[-*+]+)+//;
- ! s/^\([-*+]+\)//;
- s/^@//;
- #
- # anything left over means invalid form
- --- 1164,1171 ----
- #
- # still have leftovers, so try to eat right hand forms
- #
- ! s/^(\/[-*+]*)+//;
- ! s/^\([-*+]*\)//;
- s/^@//;
- #
- # anything left over means invalid form
- ***************
- *** 1173,1179 ****
- $_=$_[0];
- if (&valid_code($_))
- {
- - # print "after regexp, \$_ = '$_'\n";
- $original_code=$_;
- if (/c/o)
- {
- --- 1186,1191 ----
- ***************
- *** 1413,1419 ****
- print "\tI range from...\n";
- &shape_parse($_);
- print ("\n\t... to ...\n");
- ! &shape_strength($1);
- }
- else
- {
- --- 1425,1431 ----
- print "\tI range from...\n";
- &shape_parse($_);
- print ("\n\t... to ...\n");
- ! &shape_parse($1);
- }
- else
- {
- ***************
- *** 1561,1567 ****
- {
- print " and of ";
- }
- ! if ($_ eq "at") { print "all trades" ;}
- elsif ($_ eq "b") { print "business"; }
- elsif ($_ eq "cs") { print "computer science"; }
- elsif ($_ eq "m") { print "math";}
- --- 1573,1579 ----
- {
- print " and of ";
- }
- ! if ($_ eq "at") { print "all trades" ;}
- elsif ($_ eq "b") { print "business"; }
- elsif ($_ eq "cs") { print "computer science"; }
- elsif ($_ eq "m") { print "math";}
- ***************
- *** 1571,1577 ****
- elsif ($_ eq "t") { print "theater";}
- elsif ($_ eq "o") { print "other";}
- elsif ($_ eq "u") { print "undecided";}
- ! else { print "unknown";}
- $first = 0;
- }
- print ".\n\n";
- --- 1583,1589 ----
- elsif ($_ eq "t") { print "theater";}
- elsif ($_ eq "o") { print "other";}
- elsif ($_ eq "u") { print "undecided";}
- ! else { print "unknown";}
- $first = 0;
- }
- print ".\n\n";
- ***************
- *** 1602,1604 ****
- --- 1614,1621 ----
- }
- }
-
- + #
- + # local variables:
- + # mode: perl
- + # end:
- + #
-
- Diff exited abnormally with code 1 at Tue Feb 1 05:55:45
-
-