1.\" Copyright (c) 1986, 1990 The Regents of the University of California. 2.\" All rights reserved. 3.\" 4.\" %sccs.include.redist.man% 5.\" 6.\" @(#)mset.1 4.4 (Berkeley) 03/14/91 7.\" 8.Vx 9.Vx 10.Dd 11.Dt MSET 1 12.Os BSD 4.3 13.Sh NAME 14.Nm mset 15.Nd retrieve ASCII to IBM 3270 keyboard map 16.Sh SYNOPSIS 17.Nm mset 18.Op Fl picky 19.Op Fl shell 20.Op Ar keyboardname 21.Sh DESCRIPTION 22.Nm Mset 23retrieves mapping information 24for the ASCII keyboard to IBM 3270 terminal 25special functions. 26Normally, these mappings are found 27in 28.Pa /usr/share/misc/map3270 29(see 30.Xr map3270 5 ) . 31This information is used by the 32.Xr tn3270 33command (see 34.Xr tn3270 1 ) . 35.Pp 36The default 37.Nm mset 38output can be used to store the mapping information in the process environment 39in order to avoid scanning 40.Nm map3270 41each time 42.Nm tn3270 43is invoked. 44To do this, place the following command in your 45.Pa .login 46file: 47.Pp 48.Dl set noglob; setenv MAP3270 "\(gamset\(ga"; unset noglob 49.Pp 50If the 51.Ar keyboardname 52argument is not supplied, 53.Nm mset 54attempts to determine the name of the keyboard the user is using, 55by checking the 56.Ev KEYBD 57environment variable. 58If the 59.Ev KEYBD 60environment variable is not set, then 61.Nm mset 62uses the user's terminal type from the environment variable 63.Ev TERM 64as the keyboard name. 65Normally, 66.Nm mset 67then uses the file 68.Xr map3270 5 69to find the keyboard mapping for that terminal. 70However, if the environment variable 71.Ev MAP3270 72exists and contains the entry for the specified keyboard, then that 73definition is used. 74If the value of 75.Ev MAP3270 76begins with a slash (`/') then it is assumed to be the full pathname 77of an alternate mapping file and that file is searched first. 78In any case, if the mapping for the keyboard is not found in 79the environment, nor in an alternate map file, nor in the standard map file, 80then the same search is performed for an entry for a keyboard with the name 81.Ar unknown . 82If that search also fails, 83then a default mapping 84is used. 85.Pp 86The arguments to 87.Nm mset 88are: 89.Pp 90.Tw Fl 91.Tp Fl picky 92When processing the various 93.Pa map3270 94entries (for the user's keyboard, 95and all those encountered before the one for the user's keyboard), 96.Nm mset 97normally will not complain about entries for unknown functions (like 98.Dq PFX1 ; 99the 100.Fl picky 101argument causes 102.Nm mset 103to issue warning messages about these unknown entries. 104.Tp Fl shell 105If the 106.Pa map3270 107entry is longer than the shell's 1024 environmental variable 108length limit, the default 109.Nm mset 110output cannot be used to store the mapping information in the process 111environment to avoid scanning 112.Pa map3270 113each time 114.Nm tn3270 115is invoked. 116The 117.Fl shell 118argument causes 119.Nm mset 120to generate shell commands to set the environmental variables 121.Ev MAP3270 , 122.Ev MAP3270A , 123and so on, breaking up the entry to fit within the shell environmental 124variable length limit. 125To set these variables, place the following command in your 126.Pa .login 127file: 128.Pp 129.Dl mset -shell > tmp ; source tmp ; /bin/rm tmp 130.Tp Ar keyboardname 131When searching for the 132.Pa map3270 133entry that matches the user's keyboard, 134.Nm mset 135will use 136.Ar keyboardname 137instead of determining the keyboard name from the 138.Ev KEYBD 139or 140.Ev TERM 141environmental variables. 142.Sh FILES 143.Dw /usr/share/misc/map3270 144.Di L 145.Dp Pa /usr/share/misc/map3270 146keyboard mapping for known keyboards 147.Dp 148.Sh ENVIRONMENT 149.Sh SEE ALSO 150.Xr tn3270 1 , 151.Xr map3270 5 152.Sh HISTORY 153.Nm mset 154appeared in 4.3 BSD. 155