Changeset 7869e48 for examples/owlconf.erik
- Timestamp:
- Jan 12, 2013, 1:43:13 PM (13 years ago)
- Children:
- e3a0d71, 4485285
- Parents:
- 4626016
- git-author:
- Jason Gross <jgross@mit.edu> (01/12/13 13:13:18)
- git-committer:
- Jason Gross <jgross@mit.edu> (01/12/13 13:43:13)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
examples/owlconf.erik
rd7cc50b r7869e48 1 ### The owlconf config file -*- perl -*- 1 ### The owlconf config file -*- perl -*- 2 2 ### 3 3 ### !!!!!WARNING!!!!! !!!!!WARNING!!!!! !!!!!WARNING!!!!! !!!!!WARNING!!!!! 4 ### This is an example file intended to demonstrate how to use 4 ### This is an example file intended to demonstrate how to use 5 5 ### various features of owl. Some of the key bindings, in particular, 6 6 ### are more for examples than things you may actually want to use. … … 30 30 ### The message attributes may be dereferenced with $m->attribute 31 31 ### 32 ### 32 ### 33 33 34 34 # tokens for sepbar are: … … 122 122 } 123 123 124 # Load in things which don't belong in an owlconf 124 # Load in things which don't belong in an owlconf 125 125 # that people might use as an example... 126 126 sub personal_startup { … … 231 231 sepbartokens_add("<$sender"); 232 232 sepbartokens_trim(">$sender"); 233 } 233 } 234 234 } elsif ($m->is_mail) { 235 235 mail_add_message($m); … … 249 249 my ($b) = @_; 250 250 $b=~s/^/ /g; 251 $b=~s/\n/\n /g; 251 $b=~s/\n/\n /g; 252 252 return $b; 253 253 } … … 282 282 } 283 283 284 if (!$m->is_zephyr && !$m->is_aim) { 284 if (!$m->is_zephyr && !$m->is_aim) { 285 285 return "Unknown message type: ".$m->type."\n"; 286 286 } … … 308 308 309 309 if ($m->is_zephyr) { 310 $out = sprintf "[mit,%s,%s] / %s / %s", lc($m->class), 310 $out = sprintf "[mit,%s,%s] / %s / %s", lc($m->class), 311 311 lc($m->instance), $m->time, lc($m->host); 312 312 if ($m->opcode ne "") {$out.=" op:".$m->opcode;} … … 322 322 } 323 323 } 324 $out.="\n"; 324 $out.="\n"; 325 325 } else { 326 326 $out = sprintf "[%s] / %s\n", lc($m->type), $m->time; 327 327 $out.= " \@bold($sender)> "; 328 $out.="\n"; 328 $out.="\n"; 329 329 } 330 330 … … 380 380 } 381 381 382 if (!$m->is_zephyr && !$m->is_aim) { 382 if (!$m->is_zephyr && !$m->is_aim) { 383 383 return "Unknown message type: ".$m->type."\n"; 384 384 } … … 402 402 } 403 403 return "$out\n"; 404 404 405 405 } elsif ($m->is_zephyr && $m->is_mail) { 406 406 my $body = $m->body; … … 414 414 my $channel = ""; 415 415 my $body = $m->body; 416 416 417 417 if ($m->is_zephyr) { 418 418 my $inst = $m->instance; … … 459 459 } 460 460 for my $w (@words) { 461 if (($outline ne "") 461 if (($outline ne "") 462 462 && (length($outline)+length($w) > $width-$unindent)) { 463 463 $out .= $outline."\n"; … … 472 472 $outline .= $w; 473 473 } 474 $out .= $outline . "\n"; 475 } 474 $out .= $outline . "\n"; 475 }
Note: See TracChangeset
for help on using the changeset viewer.