File: mgtdoc.asc

package info (click to toggle)
mgt 2.31-7
  • links: PTS
  • area: main
  • in suites: bullseye, buster, sid, stretch
  • size: 460 kB
  • ctags: 582
  • sloc: ansic: 4,852; sh: 411; pascal: 329; makefile: 88; csh: 3
file content (528 lines) | stat: -rw-r--r-- 19,514 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528



   9 July 1993                                                         MGT(6)



   NAME
     mgt - game record display/editor for the oriental game of go

   SYNOPSIS
     mgt [-m filename] [-s] [-t] [files]

   DESCRIPTION
     Go is an ancient oriental strategy game based on the capturing of terri-
     tory.  The players alternate putting stones on the board, trying to sur-
     round as many empty intersections as possible.

     Mgt allows the user to examine Go game tree files created through the
     Macintosh(tm) programs Smart-Go (tm) or Go Explorer (tm). Mgt also has
     basic Go game tree editing capabilities and may be used to create or
     edit game tree files.  The on-line material provided by a rather exten-
     sive and growing database allows many hours of instructional enjoyment
     of various studies and tutorials concerning the game of Go.

     Mailgo is a utility which manages E-mail Go games using mgt as the Go
     board editor.  It is included in the mgt package.

     The mgt program was originally developed to be a companion for the
     series, "From My Go Teacher", archived bsdserver.ucsf.edu for ftp.  Also
     available is the Internet GO Board communications program, 'go', also by
     Greg Hale, which connects up two terminals in real-time anywhere in the
     world, and the clients for the Internet Go Server.

   COMMAND LINE OPTIONS

     -m filename
             Invoke a set of options used by the mailgo program for managing
             email games.  If a filename is specified for loading (see
             below), the game record is loaded, and mgt automatically moves
             to the end of the main variation of the game record.  The game
             can be modified without confirmation.  If the game record has
             been modified, it will be automatically saved, on exit, to the
             filename specified after the -m and mgt will return success
             (zero).  If the game record has not been modified, or has not
             been allowed to be saved, then mgt will return failure
             (nonzero).

     -s      Change save format used to write save files.  The default save
             format is the long format Smart-Go file.  Using this option
             results in short format Smart-Go files.

     -t      Invoke tutor mode where you select variations by playing on the
             board.  The key for making a move has special behavior in this
             mode.  See the section on the "space or 0" keyboard command for
             a description.

     files   These are the files to be loaded.  The Unix and IBM version sup-
             port wildcards.  If no file is specified, mgt loads a blank
             board.  If you attempt to modify a file that was loaded, mgt


                                                                            1






   MGT(6)                                                         9 July 1993


             will prompt for confirmation the first time.

   OPERATION
     Mgt can be used to view and edit game records, or as an electronic game
     board for a two person game.  There are many keyboard commands which
     execute the various editing and display functions.

     >       Step down the game tree to the next move.  Stop at the end of a
             variation and do not visit other variations.

     <       Move back up the game tree.  (Previous move)

      .      Go to the next node using a tree traversal which will visit all
             nodes.  Sometimes the order of traversal can be confusing.

     ,       Go to the previous node -- the opposite of "." forward movement.

     e       Go to end of the current variation.

     b       Go to beginning of the game tree.

     }       Go forward like the "." command until a comment.

     {       Go backwards like the "," command until a comment.

     g       Go to a specified node.  Type in the desired node number.

     ]       Move forward until there is a variation branch in the game tree.

     [       Move backwards until there is a variation branch in the game
             tree.

     k and i Scroll the game tree variation window up and down.  A - at the
             top of the variation window, and a + at the bottom indicate that
             more variations are available.

     j and u Scroll comment window up and down.  A - at the top of the com-
             ment, and a + at the bottom indicate that more comments are
             available.

     #       Load new file.  Will prompt for confirmation if the current file
             has been modified.

     r       Load previous file.  (Reverse through the file list)

     f       Load next file.  (Forward through the file list)

     w       Write out Smart-Go file.  Will prompt for a filename.  The spe-
             cial filename * will save with the current name (which appears
             in the upper right corner).

     space or 0
             Make a move.  The current player turn is indicated by the > <
             around the captured stones on the lower right.  Normally, this


   2






   9 July 1993                                                         MGT(6)


             adds the move to the game tree and moves to a new node.  In
             tutor mode, it checks the various game continuations.  If one of
             them contains the move you made, it moves to that variation.  If
             not, it prints an error message.  The game tree cannot be modi-
             fied in tutor mode.

     p       Pass.  Enter a pass move.

     o       Other player.  Changes whose turn it is, adding a token in the
             game tree to force the change whenever this node is visited.  If
             the player is forced by such a token, the current player turn is
             indicated by } { characters on the lower right.

     t       Toggle stone color.  Changes whose turn it is without adding any
             tokens in the game tree.  This will not work if the game tree
             has a PLayer token (generated by the o key) at the current node.

     z       Set/unset black stones.

     x       Set/unset white stones.

     q or ESC.
             Quit.  q will prompt for confirmation.  ESC will not prompt for
             confirmation.

     v       Create a variation below the current node.  The variation will
             initially contain a null node.  You must move to that variation
             to make a move in it.  If the "v" command is invoked at a node
             which is at the end of a variation, variation "A" is created
             with a null node.  Subsequent invocations of the "v" command
             will create the "B", "C"... variations.

     !       Cut tree.  Moves the current node and everything below it to a
             temporary holding buffer.  (Moves your location back to the
             parent of the node you are one when you invoke it.)

     ^       Paste tree.  Pastes the temporary holding buffer in after the
             current node.  Usually the  opposite of cutting the tree.

     c       Edit the current comment. The editor has two models of opera-
             tion.  The default model has been vaguely designed after emacs.
             That means that the editor commands are either 'control-key'  or
             'escape-key'.  The controls are configurable through an environ-
             ment variable.  The notation "^key" is used to indicate control
             keys, and "]key" is used to indicate keys which should be pre-
             ceeded by the escape character.

             On some terminals, instead of ESC-key, you can press Alt-key or
             Meta-key.  (On the IBM version, you can use the Alt key.) Under
             VMS, the ESC key does not work.  VMS users may need to redefine
             the edit keys.

             The second edit model was vaguely designed after vi.  That means
             that the editor has a command mode for cursor movement, etc. and


                                                                            3






   MGT(6)                                                         9 July 1993


             an insert mode for inserting text.  The vi model editor starts
             in insert mode.  The ESC key changes mode from insert mode to
             command mode.  If pressed in command mode, the ESC key exits the
             comment editor and saves the comment.  The letters below are
             typed in command mode to obtain the specified function. To leave
             command mode and enter insert mode, you must use the function
             which is listed as the insert mode command.  This defaults to
             'R'.   To select the vi like mode of operation, put _ASCEDVI in
             your MGT environment variable.

             Defaults are:
                        Command                emacs   vi
                 cursor up    (previous line)  ^P      k
                 cursor down  (next line)      ^N      j
                 page up      (prev page)      ]p      ^B
                 page down    (next page)      ]n      ^F
                 cursor left  (back)           ^B      h
                 cursor right (forward)        ^F      l
                 beginning of line             ^A      0
                 end of line                   ^E      $
                 beginning of comment          ]<      H
                 end of comment                ]>      L
                 delete one character          ^D      x
                 delete to end of line (kill)  ^K      D
                 toggle insert mode            ^I      R
                 save comment                  ]z      w
                 exit, don't save comment      ^W      q

             Pressing c on a comment larger than the 120 lines allocated for
             comments will cause the extra to be lost.  Also, on terminals
             which generate IBM PC arrow key codes, the arrow keys will
             correctly move the cursor within the comment editor.  The arrow
             keys only work in the emacs based model.

     d       Delete node.  Deletes the current node, replacing it with its
             child.  If the current node has no child, then clear the proper-
             ties of the current node.

     n       Name the current node.  You will be prompted for the name.

     s       Score the game.  After selecting this, move the cursor around
             and remove the dead groups with 0 or space.  You can undo one
             (and only one) kill with the u key.  Pressing return will score
             the game and print the (Japanese) score in the comment area.  If
             you missed some dead groups, continue removing them.  Press q
             when you wish to exit scoring mode.  You will be prompted to
             either keep the score information as a comment for the current
             node or restore the old comment.

     Ctrl-I  Enter info mode.  In this mode, the various informational pro-
             perties of the current file are displayed and may be edited.  To
             edit an item, press the letter associated with it, and enter the
             new text.  This letter must be entered in upper case.  To see a
             list of letters, press ?. The comment window scrolling keys can


   4






   9 July 1993                                                         MGT(6)


             be used to scroll the info display.  The supported info proper-
             ties are: Size, Handicap, playerBlack, bLackrank, playerWhite,
             whIterank, Gamename, Event, rouNd, Date, Place, Time, Result,
             gameComment, sOurce, User, Komi.  The capital letters in this
             list indicate which letter selects that info property.

     Ctrl-T  Toggle tutor mode.  (See the section on space or 0 for explana-
             tion.)

     Ctrl-W  Toggle the format used for writing Smart-Go files between long
             and short.

     Ctrl-L  Refresh the screen.

     Ctrl-F  Save the current screen to a file.

     ?       Display a help screen.

     12346789
             Move the cursor around.  Assumes standard numeric keypad orien-
             tation.

   ENVIRONMENT SETTINGS
     All of the characters used for the commands and the display are confi-
     gurable via environment variables.  For the ascii interface, use:

     setenv MGT '_ASCCOM:q><.,eb}{][gwzxv\!lm#^cdn
                         spotrfLWTFI012346789kiju&
                 _ASCCHAR:#O:+-.+|-++++
                 _ASCINV _ASCED:PNpnBFAE<>DKIzO'
            (command should appear all on one line with a
             single space separating _ASC... from the
             previous string.)


     to get the default characters.  (This is csh syntax.  For other shells,
     the syntax will be different.) Place this line in your .cshrc so the
     alternate characters are always in effect.

     The _ASCCOM string allows you to change the keyboard commands.  Upper
     case letters stand for control characters.

     The _ASCCHAR string specifies the display characters.  For example, to
     use @ for black stones, change the # to @ in the _ASCCHAR string.  You
     need only include one of the two declarations ("_ASCCOM:" or
     "_ASCCHAR:") if you only want to change the commands or characters but
     not both.

     To set the default display type to inverse video, use _ASCINV in the MGT
     environment variable.

     To set the comment editor commands, use _ASCED in the MGT environment
     variable.



                                                                            5






   MGT(6)                                                         9 July 1993


     For the _ASCED environment variable setting in the emacs based editor
     model, control keys are specified with a capital letter, and ESC keys
     are anything which is not a capital letter.  This is the key string for
     the defaults: PNpnBFAE<>DKIzO. Note that ^V, ^O, ^C and ^Z are poor
     characters to use for anything if you have berkeley unix because the
     berkeley tty drivers interpret these characters.  The ^V character is
     the quoting character which quotes the following character.  You will
     need to press it twice for mgt to see it.  The other characters have to
     be quoted by first pressing ^V or mgt will not recognize your keypress.
     You cannot use ^H or ^? for anything because the editor always inter-
     prets these as destructive backspace.

     For the _ASCED environment variable setting in the vi based editor
     model, no special processing is done on the characters.  In order to
     specify control keys, you must place actual control characters into your
     environment string.  The default string has two control commands (^B and
     ^F) defined.  This is the default: kj^B^Fhl0$HLxDRwq.  The vi based edi-
     tor model may be selected be including _ASCEDVI in the environment vari-
     able.

     If you wish to include control characters in your string, you can do
     this most easily by editing a file which sets the environment.  Vi can
     insert most of the control characters directly.

     In all cases, when you set your own keys, you must set all of the keys,
     and they must appear in the correct order.  If you give assign the same
     key to different functions, then an arbitrary one will be used by mgt
     and the other functions will be unavailable.  If multiple contradictory
     specifications occur in the mgt environment variable, the last that
     appear will be used by the program. Any option not specified will assume
     the default values identified above.

     With the IBM version, the same effects may be achieved under DOS 4.0 or
     DOS 5.0 with a SET command placed in the AUTOEXEC.BAT file.  Under pre-
     vious DOS versions, quotes were interpreted literally and "|", ">" and
     "<" characters have special meanings and thus cannot be put into
     environment variables with the SET command.

     Under VMS, the command is just MGT = "_ASCCHAR:..."

   COMMENT FORMATTING
     Comments are expected to consist of long lines, each of which is one
     paragraph.  A single long line will be formatted to fit the display.
     Line breaks will be ignored if they are preceeded by a space, but will
     be respected otherwise.

   DISPLAYS
     All displays have in common the purpose of displaying a go tree.








   6






   9 July 1993                                                         MGT(6)


   ASCII display:
       A B C D E F G H  S T
      +---------------  ---+   -Suppose this is the second
    19|. . . # . . . .  . .|19| line of the comment.  Since
    18|. O O # # # O .  . .|18| there is some more of the
    17|. # # O O O O .  . .|17| comment above us unseen,
    16|. # O + . . . .  . .|16| the - appears to the left
    15|. # O . O . . .  . .|15| of 'Suppose'.
    14|. . # O . . . .  . .|14|
    13|. . # . . . . .  . .|13|
    12|. . . . . . . .  . .|12|
    11|. . . . . . . .  . .|11| And here, when there is
    10|. . . + . . . .  . .|10| more of the comment
     9|. . . . . . . .  . .| 9| below, the '+'
     8|. . . . . . . .  . .| 8|+appears to our left.
     7|. . . . . . . .  . .| 7|
     6|. . . . . . . .  . .| 6|   Node #173: Name
     5|. . . . . . . .  . .| 5|-B: variation 1 hit 'B' to see
     4|. . . + . . . .  . .| 4| C: variation 2 hit 'C'
     3|. . . . . . . .  . .| 3| D: variation 3 etc...
     2|. . . . . . . .  . .| 2| E: variation 4
     1|. . . . . . . .  . .| 1|+F: variation 5
      +---------------  ---+    ? for help    read   long
       A B C D E F G H  S T
    Black #11 at 'D19'               #: 0      > O: 0 <


     The bottom line indicates that Black has just made move #11.  On the
     bottom right, the angle brackets around the white stone indicate that it
     is White's turn.  Above that, the word "read" indicates that the
     Smart-Go file hasn't been modified, and "long" indicates that the
     default save format is the long format.  "Read" will change to "edit" if
     you modify the file, and it will say "tutor" if you enter tutor mode.

   FILES
     wrapmgt - prepare short format Smart-Go files for mailing

     mailgo - email go game management

     mgt2short - script to convert Smart-Go files to short format

     RULES - an introduction to the game in Smart-Go format.

     The From My Go Teacher tutorial lessons, and many professional game
     records all available at bsdserver.ucsf.edu

     Internet go, a program to play go over internet, available on
     bsdserver.ucsf.edu

     Smart-Go.def, the Smart-Go format definition.






                                                                            7






   MGT(6)                                                         9 July 1993


   BUGS

     Comment editing is limited to 120 screen lines.

     Most, but not all, of the Smart-Go properties are supported.

     Send bug reports to "adrian@bsdserver.ucsf.edu" or
     "hale@scam.Berkeley.EDU"


   AUTHORS
     Greg Hale

     Jeff Boscole

     Adrian Mariano (adrian@bsdserver.ucsf.edu)

     Mike Dobbins (mdobbins@asns.tredydev.unisys.com)


   SEE ALSO
     rec.games.go - a newsgroup on the game
     Graded go problems for beginners, vol 1-4, Ishi Press
     In the Beginning, Ishi Press.
     The Treasure Chest Enigma, Ishi Press.































   8