Offset 1, 3 lines modified | Offset 1, 3 lines modified | ||
1 | -rw-r--r--···0········0········0········4·2023-08-27·22:55:58.000000·debian-binary | 1 | -rw-r--r--···0········0········0········4·2023-08-27·22:55:58.000000·debian-binary |
2 | -rw-r--r--···0········0········0······668·2023-08-27·22:55:58.000000·control.tar.xz | 2 | -rw-r--r--···0········0········0······668·2023-08-27·22:55:58.000000·control.tar.xz |
3 | -rw-r--r--···0········0········0····1 | 3 | -rw-r--r--···0········0········0····15924·2023-08-27·22:55:58.000000·data.tar.xz |
Offset 1, 17 lines modified | Offset 1, 17 lines modified | ||
1 | drwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./ | 1 | drwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./ |
2 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/ | 2 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/ |
3 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/ | 3 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/ |
4 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/ | 4 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/ |
5 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/ | 5 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/ |
6 | -rw-r--r--···0·root·········(0)·root·········(0)····2 | 6 | -rw-r--r--···0·root·········(0)·root·········(0)····24116·2023-08-27·22:55:58.000000·./usr/share/man/man3/editline.3 |
7 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man5/ | 7 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man5/ |
8 | -rw-r--r--···0·root·········(0)·root·········(0)····· | 8 | -rw-r--r--···0·root·········(0)·root·········(0)·····7143·2023-08-27·22:55:58.000000·./usr/share/man/man5/editrc.5 |
9 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man7/ | 9 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man7/ |
10 | -rw-r--r--···0·root·········(0)·root·········(0)····33 | 10 | -rw-r--r--···0·root·········(0)·root·········(0)····33733·2023-08-27·22:55:58.000000·./usr/share/man/man7/editline.7 |
11 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_deletestr.3·->·editline.3 | 11 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_deletestr.3·->·editline.3 |
12 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_end.3·->·editline.3 | 12 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_end.3·->·editline.3 |
13 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_get.3·->·editline.3 | 13 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_get.3·->·editline.3 |
14 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_getc.3·->·editline.3 | 14 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_getc.3·->·editline.3 |
15 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_gets.3·->·editline.3 | 15 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_gets.3·->·editline.3 |
16 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_init.3·->·editline.3 | 16 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_init.3·->·editline.3 |
17 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_init_fd.3·->·editline.3 | 17 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_init_fd.3·->·editline.3 |
Offset 1, 1172 lines modified | Offset 1, 1020 lines modified | ||
1 | . | 1 | .\"» $NetBSD:·editline.3,v·1.101·2021/08/15·10:12:54·wiz·Exp·$ |
2 | .\" | ||
3 | .\"·Copyright·(c)·1997-2014·The·NetBSD·Foundation,·Inc. | ||
4 | .\"·All·rights·reserved. | ||
5 | .\" | ||
6 | .\"·This·file·was·contributed·to·The·NetBSD·Foundation·by·Luke·Mewburn. | ||
7 | .\" | ||
8 | .\"·Redistribution·and·use·in·source·and·binary·forms,·with·or·without | ||
9 | .\"·modification,·are·permitted·provided·that·the·following·conditions | ||
10 | .\"·are·met: | ||
11 | .\"·1.·Redistributions·of·source·code·must·retain·the·above·copyright | ||
12 | .\"····notice,·this·list·of·conditions·and·the·following·disclaimer. | ||
13 | .\"·2.·Redistributions·in·binary·form·must·reproduce·the·above·copyright | ||
14 | .\"····notice,·this·list·of·conditions·and·the·following·disclaimer·in·the | ||
15 | .\"····documentation·and/or·other·materials·provided·with·the·distribution. | ||
16 | .\" | ||
17 | .\"·THIS·SOFTWARE·IS·PROVIDED·BY·THE·NETBSD·FOUNDATION,·INC.·AND·CONTRIBUTORS | ||
18 | .\"·``AS·IS''·AND·ANY·EXPRESS·OR·IMPLIED·WARRANTIES,·INCLUDING,·BUT·NOT·LIMITED | ||
19 | .\"·TO,·THE·IMPLIED·WARRANTIES·OF·MERCHANTABILITY·AND·FITNESS·FOR·A·PARTICULAR | ||
20 | .\"·PURPOSE·ARE·DISCLAIMED.··IN·NO·EVENT·SHALL·THE·FOUNDATION·OR·CONTRIBUTORS | ||
21 | .\"·BE·LIABLE·FOR·ANY·DIRECT,·INDIRECT,·INCIDENTAL,·SPECIAL,·EXEMPLARY,·OR | ||
22 | .\"·CONSEQUENTIAL·DAMAGES·(INCLUDING,·BUT·NOT·LIMITED·TO,·PROCUREMENT·OF | ||
23 | .\"·SUBSTITUTE·GOODS·OR·SERVICES;·LOSS·OF·USE,·DATA,·OR·PROFITS;·OR·BUSINESS | ||
24 | .\"·INTERRUPTION)·HOWEVER·CAUSED·AND·ON·ANY·THEORY·OF·LIABILITY,·WHETHER·IN | ||
25 | .\"·CONTRACT,·STRICT·LIABILITY,·OR·TORT·(INCLUDING·NEGLIGENCE·OR·OTHERWISE) | ||
26 | .\"·ARISING·IN·ANY·WAY·OUT·OF·THE·USE·OF·THIS·SOFTWARE,·EVEN·IF·ADVISED·OF·THE | ||
27 | .\"·POSSIBILITY·OF·SUCH·DAMAGE. | ||
28 | .\" | ||
29 | .Dd·August·15,·2021 | ||
30 | .Dt·EDITLINE·3 | ||
31 | .Os | ||
2 | .S | 32 | .Sh·NAME |
3 | \fBeditline\fP, | ||
4 | \fBel_init\fP, | ||
5 | \fBel_init_fd\fP, | ||
6 | \fBel_end\fP, | ||
7 | \fBel_reset\fP, | ||
8 | \fBel_gets\fP, | ||
9 | \fBel_wgets\fP, | ||
10 | \fBel_getc\fP, | ||
11 | \fBel_wgetc\fP, | ||
12 | \fBel_push\fP, | ||
13 | \fBel_wpush\fP, | ||
14 | \fBel_parse\fP, | ||
15 | \fBel_wparse\fP, | ||
16 | \fBel_set\fP, | ||
17 | \fBel_wset\fP, | ||
18 | \fBel_get\fP, | ||
19 | \fBel_wget\fP, | ||
20 | \fBel_source\fP, | ||
21 | \fBel_resize\fP, | ||
22 | \fBel_cursor\fP, | ||
23 | \fBel_line\fP, | ||
24 | \fBel_wline\fP, | ||
25 | \fBel_insertstr\fP, | ||
26 | \fBel_winsertstr\fP, | ||
27 | \fBel_deletestr\fP, | ||
28 | \fBel_wdeletestr\fP, | ||
29 | \fBhistory_init\fP, | ||
30 | \fBhistory_winit\fP, | ||
31 | \fBhistory_end\fP, | ||
32 | \fBhistory_wend\fP, | ||
33 | \fBhistory\fP, | ||
34 | \fBhistory_w\fP, | ||
35 | \fBtok_init\fP, | ||
36 | \fBtok_winit\fP, | ||
37 | \fBtok_end\fP, | ||
38 | \fBtok_wend\fP, | ||
39 | \fBtok_reset\fP, | ||
40 | \fBtok_wreset\fP, | ||
41 | \fBtok_line\fP, | ||
42 | \fBtok_wline\fP, | ||
43 | \fBtok_str\fP, | ||
44 | 33 | .Nm·editline·, | |
34 | .Nm·el_init·, | ||
35 | .Nm·el_init_fd·, | ||
36 | .Nm·el_end·, | ||
37 | .Nm·el_reset·, | ||
38 | .Nm·el_gets·, | ||
39 | .Nm·el_wgets·, | ||
40 | .Nm·el_getc·, | ||
41 | .Nm·el_wgetc·, | ||
42 | .Nm·el_push·, | ||
43 | .Nm·el_wpush·, | ||
44 | .Nm·el_parse·, | ||
45 | .Nm·el_wparse·, | ||
46 | .Nm·el_set·, | ||
47 | .Nm·el_wset·, | ||
48 | .Nm·el_get·, | ||
49 | .Nm·el_wget·, | ||
50 | .Nm·el_source·, | ||
51 | .Nm·el_resize·, | ||
52 | .Nm·el_cursor·, | ||
53 | .Nm·el_line·, | ||
54 | .Nm·el_wline·, | ||
55 | .Nm·el_insertstr·, | ||
56 | .Nm·el_winsertstr·, | ||
57 | .Nm·el_deletestr·, | ||
58 | .Nm·el_wdeletestr·, | ||
59 | .Nm·history_init·, | ||
60 | .Nm·history_winit·, | ||
61 | .Nm·history_end·, | ||
62 | .Nm·history_wend·, | ||
63 | .Nm·history·, | ||
64 | .Nm·history_w·, | ||
65 | .Nm·tok_init·, | ||
66 | .Nm·tok_winit·, | ||
67 | .Nm·tok_end·, | ||
68 | .Nm·tok_wend·, | ||
69 | .Nm·tok_reset·, | ||
70 | .Nm·tok_wreset·, | ||
71 | .Nm·tok_line·, | ||
72 | .Nm·tok_wline·, | ||
73 | .Nm·tok_str·, | ||
74 | .Nm·tok_wstr | ||
45 | 75 | .Nd·line·editor,·history·and·tokenization·functions | |
46 | .S | 76 | .Sh·LIBRARY |
47 | 77 | .Lb·libedit | |
48 | .S | 78 | .Sh·SYNOPSIS |
79 | .In·histedit.h | ||
80 | .Ft·EditLine·* | ||
81 | .Fn·el_init·"const·char·*prog"·"FILE·*fin"·"FILE·*fout"·"FILE·*ferr" | ||
82 | .Ft·EditLine·* | ||
83 | .Fn·el_init_fd·"const·char·*prog"·"FILE·*fin"·"FILE·*fout"·"FILE·*ferr"·"int·fdin"·"int·fdout"·"int·fderr" | ||
84 | .Ft·void | ||
85 | .Fn·el_end·"EditLine·*e" | ||
86 | .Ft·void | ||
... Open expanded diff ... |
Offset 1, 142 lines modified | Offset 1, 326 lines modified | ||
1 | . | 1 | .\"» $NetBSD:·editrc.5,v·1.34·2022/12/06·00:59:20·uwe·Exp·$ |
2 | .\" | ||
3 | .\"·Copyright·(c)·1997-2000·The·NetBSD·Foundation,·Inc. | ||
4 | .\"·All·rights·reserved. | ||
5 | .\" | ||
6 | .\"·This·file·was·contributed·to·The·NetBSD·Foundation·by·Luke·Mewburn. | ||
7 | .\" | ||
8 | .\"·Redistribution·and·use·in·source·and·binary·forms,·with·or·without | ||
9 | .\"·modification,·are·permitted·provided·that·the·following·conditions | ||
10 | .\"·are·met: | ||
11 | .\"·1.·Redistributions·of·source·code·must·retain·the·above·copyright | ||
12 | .\"····notice,·this·list·of·conditions·and·the·following·disclaimer. | ||
13 | .\"·2.·Redistributions·in·binary·form·must·reproduce·the·above·copyright | ||
14 | .\"····notice,·this·list·of·conditions·and·the·following·disclaimer·in·the | ||
15 | .\"····documentation·and/or·other·materials·provided·with·the·distribution. | ||
16 | .\" | ||
17 | .\"·THIS·SOFTWARE·IS·PROVIDED·BY·THE·NETBSD·FOUNDATION,·INC.·AND·CONTRIBUTORS | ||
18 | .\"·``AS·IS''·AND·ANY·EXPRESS·OR·IMPLIED·WARRANTIES,·INCLUDING,·BUT·NOT·LIMITED | ||
19 | .\"·TO,·THE·IMPLIED·WARRANTIES·OF·MERCHANTABILITY·AND·FITNESS·FOR·A·PARTICULAR | ||
20 | .\"·PURPOSE·ARE·DISCLAIMED.··IN·NO·EVENT·SHALL·THE·FOUNDATION·OR·CONTRIBUTORS | ||
21 | .\"·BE·LIABLE·FOR·ANY·DIRECT,·INDIRECT,·INCIDENTAL,·SPECIAL,·EXEMPLARY,·OR | ||
22 | .\"·CONSEQUENTIAL·DAMAGES·(INCLUDING,·BUT·NOT·LIMITED·TO,·PROCUREMENT·OF | ||
23 | .\"·SUBSTITUTE·GOODS·OR·SERVICES;·LOSS·OF·USE,·DATA,·OR·PROFITS;·OR·BUSINESS | ||
24 | .\"·INTERRUPTION)·HOWEVER·CAUSED·AND·ON·ANY·THEORY·OF·LIABILITY,·WHETHER·IN | ||
25 | .\"·CONTRACT,·STRICT·LIABILITY,·OR·TORT·(INCLUDING·NEGLIGENCE·OR·OTHERWISE) | ||
26 | .\"·ARISING·IN·ANY·WAY·OUT·OF·THE·USE·OF·THIS·SOFTWARE,·EVEN·IF·ADVISED·OF·THE | ||
27 | .\"·POSSIBILITY·OF·SUCH·DAMAGE. | ||
28 | .\" | ||
29 | .Dd·May·22,·2016 | ||
30 | .Dt·EDITRC·5 | ||
31 | .Os | ||
2 | .S | 32 | .Sh·NAME |
3 | 33 | .Nm·editrc | |
4 | 34 | .Nd·configuration·file·for·editline·library | |
5 | .S | 35 | .Sh·SYNOPSIS |
36 | .Nm | ||
6 | .br | ||
7 | \fBeditrc\fP | ||
8 | .S | 37 | .Sh·DESCRIPTION |
9 | The | 38 | The |
10 | 39 | .Nm | |
11 | file·defines·various·settings·to·be·used·by·the | 40 | file·defines·various·settings·to·be·used·by·the |
12 | 41 | .Xr·editline·3 | |
13 | library. | 42 | library. |
43 | .Pp | ||
14 | The·format·of·each·line·is: | 44 | The·format·of·each·line·is: |
45 | .Pp | ||
46 | .D1·Oo·Ar·prog·Ns·Ic·\&:·Oc·Ns·Ar·command·Oo·Ar·arg·...·Oc | ||
47 | .Pp | ||
48 | .Ar·command | ||
15 | is·one·of·the | 49 | is·one·of·the |
50 | .Xr·editline·3 | ||
16 | builtin·commands. | 51 | builtin·commands. |
17 | Refer·to | 52 | Refer·to |
53 | .Sx·BUILTIN·COMMANDS | ||
18 | for·more·information. | 54 | for·more·information. |
55 | .Pp | ||
56 | .Ar·prog | ||
19 | is·the·program·name·string·that·a·program·defines·when·it·calls | 57 | is·the·program·name·string·that·a·program·defines·when·it·calls |
58 | .Xr·el_init·3 | ||
20 | to·set·up | 59 | to·set·up |
60 | .Xr·editline·3·, | ||
21 | which·is·usually | 61 | which·is·usually |
62 | .Va·argv·Ns·Li·[0]·. | ||
63 | .Ar·command | ||
22 | will·be·executed·for·any·program·which·matches | 64 | will·be·executed·for·any·program·which·matches |
65 | .Ar·prog·. | ||
66 | .Pp | ||
67 | .Ar·prog | ||
23 | may·also·be·a | 68 | may·also·be·a |
69 | .Xr·regex·3 | ||
24 | style | 70 | style |
25 | regular·expression,·in·which·case | 71 | regular·expression,·in·which·case |
72 | .Ar·command | ||
26 | will·be·executed·for·any·program·that·matches·the·regular·expression. | 73 | will·be·executed·for·any·program·that·matches·the·regular·expression. |
74 | .Pp | ||
27 | If | 75 | If |
76 | .Ar·prog | ||
28 | is·absent, | 77 | is·absent, |
78 | .Ar·command | ||
29 | is·executed·for·all·programs. | 79 | is·executed·for·all·programs. |
80 | .Sh·BUILTIN·COMMANDS | ||
30 | The | 81 | The |
82 | .Nm·editline | ||
31 | library·has·some·builtin·commands,·which·affect·the·way | 83 | library·has·some·builtin·commands,·which·affect·the·way |
32 | that·the·line·editing·and·history·functions·operate. | 84 | that·the·line·editing·and·history·functions·operate. |
33 | These·are·based·on·similar·named·builtins·present·in·the | 85 | These·are·based·on·similar·named·builtins·present·in·the |
86 | .Xr·tcsh·1 | ||
34 | shell. | 87 | shell. |
88 | .Pp | ||
35 | The·following·builtin·commands·are·available: | 89 | The·following·builtin·commands·are·available: |
90 | .Bl·-tag·-width·4n | ||
91 | .It·Ic·bind·Oo·Fl·aeklrsv·Oc·Op·Ar·key·Op·Ar·command | ||
36 | Without·options·and·arguments,·list·all·bound·keys·and·macros,·and | 92 | Without·options·and·arguments,·list·all·bound·keys·and·macros,·and |
37 | the·editor·command·or·input·string·to·which·each·one·is·bound. | 93 | the·editor·command·or·input·string·to·which·each·one·is·bound. |
38 | If·only | 94 | If·only |
95 | .Ar·key | ||
39 | is·supplied,·show·the·binding·for·that·key·or·macro. | 96 | is·supplied,·show·the·binding·for·that·key·or·macro. |
40 | If | 97 | If |
98 | .Ar·key·command | ||
41 | is·supplied,·bind·the·editor | 99 | is·supplied,·bind·the·editor |
100 | .Ar·command | ||
42 | to·that·key·or·macro. | 101 | to·that·key·or·macro. |
102 | .Pp | ||
43 | The·options·are·as·follows: | 103 | The·options·are·as·follows: |
104 | .Bl·-tag·-width·4n | ||
105 | .It·Fl·a | ||
44 | List·or·change·key·bindings·in·the | 106 | List·or·change·key·bindings·in·the |
107 | .Xr·vi·1 | ||
45 | mode·alternate·(command·mode)·key·map. | 108 | mode·alternate·(command·mode)·key·map. |
109 | .It·Fl·e | ||
46 | Bind·all·keys·to·the·standard | 110 | Bind·all·keys·to·the·standard |
111 | .Tn·GNU | ||
47 | Emacs-like·bindings. | 112 | Emacs-like·bindings. |
113 | .It·Fl·k | ||
114 | .Ar·key | ||
48 | is·interpreted·as·a·symbolic·arrow·key·name,·which·may·be·one·of | 115 | is·interpreted·as·a·symbolic·arrow·key·name,·which·may·be·one·of |
116 | .Ic·up·, | ||
117 | .Ic·down·, | ||
118 | .Ic·left | ||
49 | or | 119 | or |
120 | .Ic·right·. | ||
121 | .It·Fl·l | ||
50 | List·all·editor·commands·and·a·short·description·of·each. | 122 | List·all·editor·commands·and·a·short·description·of·each. |
123 | .It·Fl·r | ||
51 | Remove·the·binding·of·the·key·or·macro | 124 | Remove·the·binding·of·the·key·or·macro |
125 | .Ar·key·. | ||
... Open expanded diff ... |
Offset 1, 1001 lines modified | Offset 1, 935 lines modified | ||
1 | . | 1 | .\"» $NetBSD:·editline.7,v·1.5·2016/05/09·21:27:55·christos·Exp·$ |
2 | .\"» $OpenBSD:·editline.7,v·1.1·2016/04/20·01:11:45·schwarze·Exp·$ | ||
3 | .\" | ||
4 | .\"·Copyright·(c)·2016·Ingo·Schwarze·<schwarze@openbsd.org> | ||
5 | .\" | ||
6 | .\"·Permission·to·use,·copy,·modify,·and·distribute·this·software·for·any | ||
7 | .\"·purpose·with·or·without·fee·is·hereby·granted,·provided·that·the·above | ||
8 | .\"·copyright·notice·and·this·permission·notice·appear·in·all·copies. | ||
9 | .\" | ||
10 | .\"·THE·SOFTWARE·IS·PROVIDED·"AS·IS"·AND·THE·AUTHOR·DISCLAIMS·ALL·WARRANTIES | ||
11 | .\"·WITH·REGARD·TO·THIS·SOFTWARE·INCLUDING·ALL·IMPLIED·WARRANTIES·OF | ||
12 | .\"·MERCHANTABILITY·AND·FITNESS.·IN·NO·EVENT·SHALL·THE·AUTHOR·BE·LIABLE·FOR | ||
13 | .\"·ANY·SPECIAL,·DIRECT,·INDIRECT,·OR·CONSEQUENTIAL·DAMAGES·OR·ANY·DAMAGES | ||
14 | .\"·WHATSOEVER·RESULTING·FROM·LOSS·OF·USE,·DATA·OR·PROFITS,·WHETHER·IN·AN | ||
15 | .\"·ACTION·OF·CONTRACT,·NEGLIGENCE·OR·OTHER·TORTIOUS·ACTION,·ARISING·OUT·OF | ||
16 | .\"·OR·IN·CONNECTION·WITH·THE·USE·OR·PERFORMANCE·OF·THIS·SOFTWARE. | ||
17 | .\" | ||
18 | .Dd·May·7,·2016 | ||
19 | .Dt·EDITLINE·7 | ||
20 | .Os | ||
2 | .S | 21 | .Sh·NAME |
3 | 22 | .Nm·editline | |
4 | 23 | .Nd·line·editing·user·interface | |
5 | .S | 24 | .Sh·DESCRIPTION |
6 | When·a·program·using·the | 25 | When·a·program·using·the |
7 | 26 | .Xr·editline·3 | |
8 | library·prompts·for·an·input·string·using·the·function | 27 | library·prompts·for·an·input·string·using·the·function |
9 | 28 | .Xr·el_wgets·3·, | |
10 | it·reads·characters·from·the·terminal. | 29 | it·reads·characters·from·the·terminal. |
11 | Invalid·input·bytes·that·do·not·form·characters·are·silently | 30 | Invalid·input·bytes·that·do·not·form·characters·are·silently |
12 | discarded. | 31 | discarded. |
13 | For·each·character·read,·one·editor·command·is·executed. | 32 | For·each·character·read,·one·editor·command·is·executed. |
14 | The·mapping·of·input·characters·to·editor·commands·depends·on·the | 33 | The·mapping·of·input·characters·to·editor·commands·depends·on·the |
15 | editing·mode. | 34 | editing·mode. |
16 | There·are·three·editing·modes:·vi·insert·mode,·vi·command·mode, | 35 | There·are·three·editing·modes:·vi·insert·mode,·vi·command·mode, |
17 | and·emacs·mode. | 36 | and·emacs·mode. |
18 | The·default·is·vi·insert·mode. | 37 | The·default·is·vi·insert·mode. |
19 | The·program·can·switch·the·default·to·emacs·mode·by·using·the | 38 | The·program·can·switch·the·default·to·emacs·mode·by·using·the |
20 | 39 | .Xr·el_set·3 | |
21 | or | 40 | or |
22 | 41 | .Xr·el_parse·3 | |
23 | functions,·and·the·user·can·switch·to·emacs·mode·either·in·the | 42 | functions,·and·the·user·can·switch·to·emacs·mode·either·in·the |
24 | 43 | .Xr·editrc·5 | |
25 | configuration·file·or·interactively·with·the | 44 | configuration·file·or·interactively·with·the |
26 | 45 | .Ic·ed-command | |
27 | editor·command,·in·all·three·cases·executing·the | 46 | editor·command,·in·all·three·cases·executing·the |
28 | 47 | .Ic·bind·Fl·e | |
29 | builtin·command. | 48 | builtin·command. |
49 | .Pp | ||
30 | If·trying·to·read·from·the·terminal·results·in·end·of·file·or·an | 50 | If·trying·to·read·from·the·terminal·results·in·end·of·file·or·an |
31 | error,·the·library·signals·end·of·file·to·the·program·and·does·not | 51 | error,·the·library·signals·end·of·file·to·the·program·and·does·not |
32 | return·a·string. | 52 | return·a·string. |
33 | .S | 53 | .Ss·Input·character·bindings |
34 | All·default·bindings·described·below·can·be·overridden·by·individual | 54 | All·default·bindings·described·below·can·be·overridden·by·individual |
35 | programs·and·can·be·changed·with·the | 55 | programs·and·can·be·changed·with·the |
36 | \fBeditrc\fP(5) | ||
37 | 56 | .Xr·editrc·5 | |
57 | .Ic·bind | ||
38 | builtin·command. | 58 | builtin·command. |
59 | .Pp | ||
39 | In·the·following·tables, | 60 | In·the·following·tables, |
40 | 61 | .Sq·Ctrl- | |
41 | indicates·a·character·with·the·bit·0x40·flipped,·and | 62 | indicates·a·character·with·the·bit·0x40·flipped,·and |
42 | 63 | .Sq·Meta- | |
43 | indicates·a·character·with·the·bit·0x80·set. | 64 | indicates·a·character·with·the·bit·0x80·set. |
44 | In·vi·insert·mode·and·in·emacs·mode,·all·Meta-characters·considered | 65 | In·vi·insert·mode·and·in·emacs·mode,·all·Meta-characters·considered |
45 | printable·by·the·current | 66 | printable·by·the·current |
46 | 67 | .Xr·locale·1 | |
47 | are·bound·to | 68 | are·bound·to |
48 | 69 | .Ic·ed-insert | |
49 | instead·of·to·the·editor·command·listed·below. | 70 | instead·of·to·the·editor·command·listed·below. |
50 | Consequently,·in·UTF-8·mode,·most·of·the·Meta-characters·are·not | 71 | Consequently,·in·UTF-8·mode,·most·of·the·Meta-characters·are·not |
51 | directly·accessible·because·their·code·points·are·occupied·by | 72 | directly·accessible·because·their·code·points·are·occupied·by |
52 | printable·Unicode·characters,·and·Meta-characters·are·usually·input | 73 | printable·Unicode·characters,·and·Meta-characters·are·usually·input |
53 | using·the | 74 | using·the |
54 | 75 | .Ic·em-meta-next | |
55 | editor·command. | 76 | editor·command. |
56 | For·example,·to·enter | 77 | For·example,·to·enter |
57 | 78 | .Sq·Meta-B | |
58 | in·order·to·call·the | 79 | in·order·to·call·the |
59 | 80 | .Ic·ed-prev-word | |
60 | editor·command·in·emacs·mode,·call | 81 | editor·command·in·emacs·mode,·call |
61 | 82 | .Ic·em-meta-next | |
62 | by·pressing·and·releasing·the·escape·key·(or·equivalently,·Ctrl-[), | 83 | by·pressing·and·releasing·the·escape·key·(or·equivalently,·Ctrl-[), |
63 | then·press·and·release·the | 84 | then·press·and·release·the |
64 | 85 | .Sq·B | |
65 | key. | 86 | key. |
66 | If·you·have·configured·a·Meta-key·on·your·keyboard,·for·example | 87 | If·you·have·configured·a·Meta-key·on·your·keyboard,·for·example |
67 | with | 88 | with |
68 | 89 | .Ql·setxkbmap·-option·altwin:left_meta_win·, | |
69 | the·Ctrl-Meta-characters·are·directly·accessible. | 90 | the·Ctrl-Meta-characters·are·directly·accessible. |
70 | For·example,·to·enter | 91 | For·example,·to·enter |
71 | 92 | .Sq·Ctrl-Meta-H | |
72 | in·order·to·call·the | 93 | in·order·to·call·the |
73 | 94 | .Ic·ed-delete-prev-word | |
74 | editor·command·in·emacs·mode,·hold·down·the·keys | 95 | editor·command·in·emacs·mode,·hold·down·the·keys |
75 | `Ctrl', | ||
76 | 96 | .Sq·Ctrl·, | |
97 | .Sq·Meta·, | ||
77 | and | 98 | and |
78 | 99 | .Sq·H | |
79 | at·the·same·time. | 100 | at·the·same·time. |
80 | Alternatively,·press·and·release·the·escape·key,·then·press·and | 101 | Alternatively,·press·and·release·the·escape·key,·then·press·and |
81 | release | 102 | release |
82 | `Ctrl-H'. | ||
103 | .Sq·Ctrl-H·. | ||
104 | .Pp | ||
83 | In·vi·input·mode,·input·characters·are·bound·to·the·following·editor | 105 | In·vi·input·mode,·input·characters·are·bound·to·the·following·editor |
84 | commands·by·default: | 106 | commands·by·default: |
107 | .Bl·-column·-offset·indent·"Ctrl-Z,·TSTP"·"ed-search-next-history" | ||
85 | It·Ctrl-D,·EOF·Ta· | 108 | .It·Ctrl-D,·EOF·Ta·Ic·vi-list-or-eof |
86 | It·Ctrl-H,·BS·Ta· | 109 | .It·Ctrl-H,·BS·Ta·Ic·vi-delete-prev-char |
87 | It·Ctrl-J,·LF·Ta· | 110 | .It·Ctrl-J,·LF·Ta·Ic·ed-newline |
88 | It·Ctrl-M,·CR·Ta· | 111 | .It·Ctrl-M,·CR·Ta·Ic·ed-newline |
89 | It·Ctrl-Q·Ta· | 112 | .It·Ctrl-Q·Ta·Ic·ed-tty-start-output |
90 | It·Ctrl-S·Ta· | 113 | .It·Ctrl-S·Ta·Ic·ed-tty-stop-output |
91 | It·Ctrl-U·Ta· | 114 | .It·Ctrl-U·Ta·Ic·vi-kill-line-prev |
92 | It·Ctrl-V·Ta· | 115 | .It·Ctrl-V·Ta·Ic·ed-quoted-insert |
93 | It·Ctrl-W·Ta· | 116 | .It·Ctrl-W·Ta·Ic·ed-delete-prev-word |
94 | It·Ctrl-[,·ESC·Ta· | 117 | .It·Ctrl-[,·ESC·Ta·Ic·vi-command-mode |
95 | It·Ctrl-\e,·QUIT·Ta· | 118 | .It·Ctrl-\e,·QUIT·Ta·Ic·ed-tty-sigquit |
96 | It·Ctrl-?,·DEL·Ta· | 119 | .It·Ctrl-?,·DEL·Ta·Ic·vi-delete-prev-char |
120 | .El | ||
121 | .Pp | ||
97 | All·other·input·characters·except·the·NUL·character·(Ctrl-@)·are | 122 | All·other·input·characters·except·the·NUL·character·(Ctrl-@)·are |
98 | bound·to | 123 | bound·to |
99 | \fBed-insert\fP. | ||
... Open expanded diff ... |
Offset 1, 3 lines modified | Offset 1, 3 lines modified | ||
1 | ?rw-r--r--···0········0········0········4·1970-01-01·00:00:00.000000·debian-binary | 1 | ?rw-r--r--···0········0········0········4·1970-01-01·00:00:00.000000·debian-binary |
2 | ?rw-r--r--···0········0········0······559·1970-01-01·00:00:00.000000·control.tar.gz | 2 | ?rw-r--r--···0········0········0······559·1970-01-01·00:00:00.000000·control.tar.gz |
3 | ?rw-r--r--···0········0········0····1 | 3 | ?rw-r--r--···0········0········0····18656·1970-01-01·00:00:00.000000·data.tar.zst |
Offset 1, 12 lines modified | Offset 1, 12 lines modified | ||
1 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/ | 1 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/ |
2 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/ | 2 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/ |
3 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/ | 3 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/ |
4 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/ | 4 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/ |
5 | -rw-r--r--···0·root·········(0)·root·········(0)····2 | 5 | -rw-r--r--···0·root·········(0)·root·········(0)····24116·2023-08-27·22:55:58.000000·./usr/share/man/man3/editline.3 |
6 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_deletestr.3·->·editline.3 | 6 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_deletestr.3·->·editline.3 |
7 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_end.3·->·editline.3 | 7 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_end.3·->·editline.3 |
8 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_get.3·->·editline.3 | 8 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_get.3·->·editline.3 |
9 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_getc.3·->·editline.3 | 9 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_getc.3·->·editline.3 |
10 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_gets.3·->·editline.3 | 10 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_gets.3·->·editline.3 |
11 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_init.3·->·editline.3 | 11 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_init.3·->·editline.3 |
12 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_init_fd.3·->·editline.3 | 12 | lrwxrwxrwx···0·root·········(0)·root·········(0)········0·2023-08-27·22:55:58.000000·./usr/share/man/man3/el_init_fd.3·->·editline.3 |
Offset 1, 1172 lines modified | Offset 1, 1020 lines modified | ||
1 | . | 1 | .\"» $NetBSD:·editline.3,v·1.101·2021/08/15·10:12:54·wiz·Exp·$ |
2 | .\" | ||
3 | .\"·Copyright·(c)·1997-2014·The·NetBSD·Foundation,·Inc. | ||
4 | .\"·All·rights·reserved. | ||
5 | .\" | ||
6 | .\"·This·file·was·contributed·to·The·NetBSD·Foundation·by·Luke·Mewburn. | ||
7 | .\" | ||
8 | .\"·Redistribution·and·use·in·source·and·binary·forms,·with·or·without | ||
9 | .\"·modification,·are·permitted·provided·that·the·following·conditions | ||
10 | .\"·are·met: | ||
11 | .\"·1.·Redistributions·of·source·code·must·retain·the·above·copyright | ||
12 | .\"····notice,·this·list·of·conditions·and·the·following·disclaimer. | ||
13 | .\"·2.·Redistributions·in·binary·form·must·reproduce·the·above·copyright | ||
14 | .\"····notice,·this·list·of·conditions·and·the·following·disclaimer·in·the | ||
15 | .\"····documentation·and/or·other·materials·provided·with·the·distribution. | ||
16 | .\" | ||
17 | .\"·THIS·SOFTWARE·IS·PROVIDED·BY·THE·NETBSD·FOUNDATION,·INC.·AND·CONTRIBUTORS | ||
18 | .\"·``AS·IS''·AND·ANY·EXPRESS·OR·IMPLIED·WARRANTIES,·INCLUDING,·BUT·NOT·LIMITED | ||
19 | .\"·TO,·THE·IMPLIED·WARRANTIES·OF·MERCHANTABILITY·AND·FITNESS·FOR·A·PARTICULAR | ||
20 | .\"·PURPOSE·ARE·DISCLAIMED.··IN·NO·EVENT·SHALL·THE·FOUNDATION·OR·CONTRIBUTORS | ||
21 | .\"·BE·LIABLE·FOR·ANY·DIRECT,·INDIRECT,·INCIDENTAL,·SPECIAL,·EXEMPLARY,·OR | ||
22 | .\"·CONSEQUENTIAL·DAMAGES·(INCLUDING,·BUT·NOT·LIMITED·TO,·PROCUREMENT·OF | ||
23 | .\"·SUBSTITUTE·GOODS·OR·SERVICES;·LOSS·OF·USE,·DATA,·OR·PROFITS;·OR·BUSINESS | ||
24 | .\"·INTERRUPTION)·HOWEVER·CAUSED·AND·ON·ANY·THEORY·OF·LIABILITY,·WHETHER·IN | ||
25 | .\"·CONTRACT,·STRICT·LIABILITY,·OR·TORT·(INCLUDING·NEGLIGENCE·OR·OTHERWISE) | ||
26 | .\"·ARISING·IN·ANY·WAY·OUT·OF·THE·USE·OF·THIS·SOFTWARE,·EVEN·IF·ADVISED·OF·THE | ||
27 | .\"·POSSIBILITY·OF·SUCH·DAMAGE. | ||
28 | .\" | ||
29 | .Dd·August·15,·2021 | ||
30 | .Dt·EDITLINE·3 | ||
31 | .Os | ||
2 | .S | 32 | .Sh·NAME |
3 | \fBeditline\fP, | ||
4 | \fBel_init\fP, | ||
5 | \fBel_init_fd\fP, | ||
6 | \fBel_end\fP, | ||
7 | \fBel_reset\fP, | ||
8 | \fBel_gets\fP, | ||
9 | \fBel_wgets\fP, | ||
10 | \fBel_getc\fP, | ||
11 | \fBel_wgetc\fP, | ||
12 | \fBel_push\fP, | ||
13 | \fBel_wpush\fP, | ||
14 | \fBel_parse\fP, | ||
15 | \fBel_wparse\fP, | ||
16 | \fBel_set\fP, | ||
17 | \fBel_wset\fP, | ||
18 | \fBel_get\fP, | ||
19 | \fBel_wget\fP, | ||
20 | \fBel_source\fP, | ||
21 | \fBel_resize\fP, | ||
22 | \fBel_cursor\fP, | ||
23 | \fBel_line\fP, | ||
24 | \fBel_wline\fP, | ||
25 | \fBel_insertstr\fP, | ||
26 | \fBel_winsertstr\fP, | ||
27 | \fBel_deletestr\fP, | ||
28 | \fBel_wdeletestr\fP, | ||
29 | \fBhistory_init\fP, | ||
30 | \fBhistory_winit\fP, | ||
31 | \fBhistory_end\fP, | ||
32 | \fBhistory_wend\fP, | ||
33 | \fBhistory\fP, | ||
34 | \fBhistory_w\fP, | ||
35 | \fBtok_init\fP, | ||
36 | \fBtok_winit\fP, | ||
37 | \fBtok_end\fP, | ||
38 | \fBtok_wend\fP, | ||
39 | \fBtok_reset\fP, | ||
40 | \fBtok_wreset\fP, | ||
41 | \fBtok_line\fP, | ||
42 | \fBtok_wline\fP, | ||
43 | \fBtok_str\fP, | ||
44 | 33 | .Nm·editline·, | |
34 | .Nm·el_init·, | ||
35 | .Nm·el_init_fd·, | ||
36 | .Nm·el_end·, | ||
37 | .Nm·el_reset·, | ||
38 | .Nm·el_gets·, | ||
39 | .Nm·el_wgets·, | ||
40 | .Nm·el_getc·, | ||
41 | .Nm·el_wgetc·, | ||
42 | .Nm·el_push·, | ||
43 | .Nm·el_wpush·, | ||
44 | .Nm·el_parse·, | ||
45 | .Nm·el_wparse·, | ||
46 | .Nm·el_set·, | ||
47 | .Nm·el_wset·, | ||
48 | .Nm·el_get·, | ||
49 | .Nm·el_wget·, | ||
50 | .Nm·el_source·, | ||
51 | .Nm·el_resize·, | ||
52 | .Nm·el_cursor·, | ||
53 | .Nm·el_line·, | ||
54 | .Nm·el_wline·, | ||
55 | .Nm·el_insertstr·, | ||
56 | .Nm·el_winsertstr·, | ||
57 | .Nm·el_deletestr·, | ||
58 | .Nm·el_wdeletestr·, | ||
59 | .Nm·history_init·, | ||
60 | .Nm·history_winit·, | ||
61 | .Nm·history_end·, | ||
62 | .Nm·history_wend·, | ||
63 | .Nm·history·, | ||
64 | .Nm·history_w·, | ||
65 | .Nm·tok_init·, | ||
66 | .Nm·tok_winit·, | ||
67 | .Nm·tok_end·, | ||
68 | .Nm·tok_wend·, | ||
69 | .Nm·tok_reset·, | ||
70 | .Nm·tok_wreset·, | ||
71 | .Nm·tok_line·, | ||
72 | .Nm·tok_wline·, | ||
73 | .Nm·tok_str·, | ||
74 | .Nm·tok_wstr | ||
45 | 75 | .Nd·line·editor,·history·and·tokenization·functions | |
46 | .S | 76 | .Sh·LIBRARY |
47 | 77 | .Lb·libedit | |
48 | .S | 78 | .Sh·SYNOPSIS |
79 | .In·histedit.h | ||
80 | .Ft·EditLine·* | ||
81 | .Fn·el_init·"const·char·*prog"·"FILE·*fin"·"FILE·*fout"·"FILE·*ferr" | ||
82 | .Ft·EditLine·* | ||
83 | .Fn·el_init_fd·"const·char·*prog"·"FILE·*fin"·"FILE·*fout"·"FILE·*ferr"·"int·fdin"·"int·fdout"·"int·fderr" | ||
84 | .Ft·void | ||
85 | .Fn·el_end·"EditLine·*e" | ||
86 | .Ft·void | ||
... Open expanded diff ... |
Offset 1, 142 lines modified | Offset 1, 326 lines modified | ||
1 | . | 1 | .\"» $NetBSD:·editrc.5,v·1.34·2022/12/06·00:59:20·uwe·Exp·$ |
2 | .\" | ||
3 | .\"·Copyright·(c)·1997-2000·The·NetBSD·Foundation,·Inc. | ||
4 | .\"·All·rights·reserved. | ||
5 | .\" | ||
6 | .\"·This·file·was·contributed·to·The·NetBSD·Foundation·by·Luke·Mewburn. | ||
7 | .\" | ||
8 | .\"·Redistribution·and·use·in·source·and·binary·forms,·with·or·without | ||
9 | .\"·modification,·are·permitted·provided·that·the·following·conditions | ||
10 | .\"·are·met: | ||
11 | .\"·1.·Redistributions·of·source·code·must·retain·the·above·copyright | ||
12 | .\"····notice,·this·list·of·conditions·and·the·following·disclaimer. | ||
13 | .\"·2.·Redistributions·in·binary·form·must·reproduce·the·above·copyright | ||
14 | .\"····notice,·this·list·of·conditions·and·the·following·disclaimer·in·the | ||
15 | .\"····documentation·and/or·other·materials·provided·with·the·distribution. | ||
16 | .\" | ||
17 | .\"·THIS·SOFTWARE·IS·PROVIDED·BY·THE·NETBSD·FOUNDATION,·INC.·AND·CONTRIBUTORS | ||
18 | .\"·``AS·IS''·AND·ANY·EXPRESS·OR·IMPLIED·WARRANTIES,·INCLUDING,·BUT·NOT·LIMITED | ||
19 | .\"·TO,·THE·IMPLIED·WARRANTIES·OF·MERCHANTABILITY·AND·FITNESS·FOR·A·PARTICULAR | ||
20 | .\"·PURPOSE·ARE·DISCLAIMED.··IN·NO·EVENT·SHALL·THE·FOUNDATION·OR·CONTRIBUTORS | ||
21 | .\"·BE·LIABLE·FOR·ANY·DIRECT,·INDIRECT,·INCIDENTAL,·SPECIAL,·EXEMPLARY,·OR | ||
22 | .\"·CONSEQUENTIAL·DAMAGES·(INCLUDING,·BUT·NOT·LIMITED·TO,·PROCUREMENT·OF | ||
23 | .\"·SUBSTITUTE·GOODS·OR·SERVICES;·LOSS·OF·USE,·DATA,·OR·PROFITS;·OR·BUSINESS | ||
24 | .\"·INTERRUPTION)·HOWEVER·CAUSED·AND·ON·ANY·THEORY·OF·LIABILITY,·WHETHER·IN | ||
25 | .\"·CONTRACT,·STRICT·LIABILITY,·OR·TORT·(INCLUDING·NEGLIGENCE·OR·OTHERWISE) | ||
26 | .\"·ARISING·IN·ANY·WAY·OUT·OF·THE·USE·OF·THIS·SOFTWARE,·EVEN·IF·ADVISED·OF·THE | ||
27 | .\"·POSSIBILITY·OF·SUCH·DAMAGE. | ||
28 | .\" | ||
29 | .Dd·May·22,·2016 | ||
30 | .Dt·EDITRC·5 | ||
31 | .Os | ||
2 | .S | 32 | .Sh·NAME |
3 | 33 | .Nm·editrc | |
4 | 34 | .Nd·configuration·file·for·editline·library | |
5 | .S | 35 | .Sh·SYNOPSIS |
36 | .Nm | ||
6 | .br | ||
7 | \fBeditrc\fP | ||
8 | .S | 37 | .Sh·DESCRIPTION |
9 | The | 38 | The |
10 | 39 | .Nm | |
11 | file·defines·various·settings·to·be·used·by·the | 40 | file·defines·various·settings·to·be·used·by·the |
12 | 41 | .Xr·editline·3 | |
13 | library. | 42 | library. |
43 | .Pp | ||
14 | The·format·of·each·line·is: | 44 | The·format·of·each·line·is: |
45 | .Pp | ||
46 | .D1·Oo·Ar·prog·Ns·Ic·\&:·Oc·Ns·Ar·command·Oo·Ar·arg·...·Oc | ||
47 | .Pp | ||
48 | .Ar·command | ||
15 | is·one·of·the | 49 | is·one·of·the |
50 | .Xr·editline·3 | ||
16 | builtin·commands. | 51 | builtin·commands. |
17 | Refer·to | 52 | Refer·to |
53 | .Sx·BUILTIN·COMMANDS | ||
18 | for·more·information. | 54 | for·more·information. |
55 | .Pp | ||
56 | .Ar·prog | ||
19 | is·the·program·name·string·that·a·program·defines·when·it·calls | 57 | is·the·program·name·string·that·a·program·defines·when·it·calls |
58 | .Xr·el_init·3 | ||
20 | to·set·up | 59 | to·set·up |
60 | .Xr·editline·3·, | ||
21 | which·is·usually | 61 | which·is·usually |
62 | .Va·argv·Ns·Li·[0]·. | ||
63 | .Ar·command | ||
22 | will·be·executed·for·any·program·which·matches | 64 | will·be·executed·for·any·program·which·matches |
65 | .Ar·prog·. | ||
66 | .Pp | ||
67 | .Ar·prog | ||
23 | may·also·be·a | 68 | may·also·be·a |
69 | .Xr·regex·3 | ||
24 | style | 70 | style |
25 | regular·expression,·in·which·case | 71 | regular·expression,·in·which·case |
72 | .Ar·command | ||
26 | will·be·executed·for·any·program·that·matches·the·regular·expression. | 73 | will·be·executed·for·any·program·that·matches·the·regular·expression. |
74 | .Pp | ||
27 | If | 75 | If |
76 | .Ar·prog | ||
28 | is·absent, | 77 | is·absent, |
78 | .Ar·command | ||
29 | is·executed·for·all·programs. | 79 | is·executed·for·all·programs. |
80 | .Sh·BUILTIN·COMMANDS | ||
30 | The | 81 | The |
82 | .Nm·editline | ||
31 | library·has·some·builtin·commands,·which·affect·the·way | 83 | library·has·some·builtin·commands,·which·affect·the·way |
32 | that·the·line·editing·and·history·functions·operate. | 84 | that·the·line·editing·and·history·functions·operate. |
33 | These·are·based·on·similar·named·builtins·present·in·the | 85 | These·are·based·on·similar·named·builtins·present·in·the |
86 | .Xr·tcsh·1 | ||
34 | shell. | 87 | shell. |
88 | .Pp | ||
35 | The·following·builtin·commands·are·available: | 89 | The·following·builtin·commands·are·available: |
90 | .Bl·-tag·-width·4n | ||
91 | .It·Ic·bind·Oo·Fl·aeklrsv·Oc·Op·Ar·key·Op·Ar·command | ||
36 | Without·options·and·arguments,·list·all·bound·keys·and·macros,·and | 92 | Without·options·and·arguments,·list·all·bound·keys·and·macros,·and |
37 | the·editor·command·or·input·string·to·which·each·one·is·bound. | 93 | the·editor·command·or·input·string·to·which·each·one·is·bound. |
38 | If·only | 94 | If·only |
95 | .Ar·key | ||
39 | is·supplied,·show·the·binding·for·that·key·or·macro. | 96 | is·supplied,·show·the·binding·for·that·key·or·macro. |
40 | If | 97 | If |
98 | .Ar·key·command | ||
41 | is·supplied,·bind·the·editor | 99 | is·supplied,·bind·the·editor |
100 | .Ar·command | ||
42 | to·that·key·or·macro. | 101 | to·that·key·or·macro. |
102 | .Pp | ||
43 | The·options·are·as·follows: | 103 | The·options·are·as·follows: |
104 | .Bl·-tag·-width·4n | ||
105 | .It·Fl·a | ||
44 | List·or·change·key·bindings·in·the | 106 | List·or·change·key·bindings·in·the |
107 | .Xr·vi·1 | ||
45 | mode·alternate·(command·mode)·key·map. | 108 | mode·alternate·(command·mode)·key·map. |
109 | .It·Fl·e | ||
46 | Bind·all·keys·to·the·standard | 110 | Bind·all·keys·to·the·standard |
111 | .Tn·GNU | ||
47 | Emacs-like·bindings. | 112 | Emacs-like·bindings. |
113 | .It·Fl·k | ||
114 | .Ar·key | ||
48 | is·interpreted·as·a·symbolic·arrow·key·name,·which·may·be·one·of | 115 | is·interpreted·as·a·symbolic·arrow·key·name,·which·may·be·one·of |
116 | .Ic·up·, | ||
117 | .Ic·down·, | ||
118 | .Ic·left | ||
49 | or | 119 | or |
120 | .Ic·right·. | ||
121 | .It·Fl·l | ||
50 | List·all·editor·commands·and·a·short·description·of·each. | 122 | List·all·editor·commands·and·a·short·description·of·each. |
123 | .It·Fl·r | ||
51 | Remove·the·binding·of·the·key·or·macro | 124 | Remove·the·binding·of·the·key·or·macro |
125 | .Ar·key·. | ||
... Open expanded diff ... |
Offset 1, 1001 lines modified | Offset 1, 935 lines modified | ||
1 | . | 1 | .\"» $NetBSD:·editline.7,v·1.5·2016/05/09·21:27:55·christos·Exp·$ |
2 | .\"» $OpenBSD:·editline.7,v·1.1·2016/04/20·01:11:45·schwarze·Exp·$ | ||
3 | .\" | ||
4 | .\"·Copyright·(c)·2016·Ingo·Schwarze·<schwarze@openbsd.org> | ||
5 | .\" | ||
6 | .\"·Permission·to·use,·copy,·modify,·and·distribute·this·software·for·any | ||
7 | .\"·purpose·with·or·without·fee·is·hereby·granted,·provided·that·the·above | ||
8 | .\"·copyright·notice·and·this·permission·notice·appear·in·all·copies. | ||
9 | .\" | ||
10 | .\"·THE·SOFTWARE·IS·PROVIDED·"AS·IS"·AND·THE·AUTHOR·DISCLAIMS·ALL·WARRANTIES | ||
11 | .\"·WITH·REGARD·TO·THIS·SOFTWARE·INCLUDING·ALL·IMPLIED·WARRANTIES·OF | ||
12 | .\"·MERCHANTABILITY·AND·FITNESS.·IN·NO·EVENT·SHALL·THE·AUTHOR·BE·LIABLE·FOR | ||
13 | .\"·ANY·SPECIAL,·DIRECT,·INDIRECT,·OR·CONSEQUENTIAL·DAMAGES·OR·ANY·DAMAGES | ||
14 | .\"·WHATSOEVER·RESULTING·FROM·LOSS·OF·USE,·DATA·OR·PROFITS,·WHETHER·IN·AN | ||
15 | .\"·ACTION·OF·CONTRACT,·NEGLIGENCE·OR·OTHER·TORTIOUS·ACTION,·ARISING·OUT·OF | ||
16 | .\"·OR·IN·CONNECTION·WITH·THE·USE·OR·PERFORMANCE·OF·THIS·SOFTWARE. | ||
17 | .\" | ||
18 | .Dd·May·7,·2016 | ||
19 | .Dt·EDITLINE·7 | ||
20 | .Os | ||
2 | .S | 21 | .Sh·NAME |
3 | 22 | .Nm·editline | |
4 | 23 | .Nd·line·editing·user·interface | |
5 | .S | 24 | .Sh·DESCRIPTION |
6 | When·a·program·using·the | 25 | When·a·program·using·the |
7 | 26 | .Xr·editline·3 | |
8 | library·prompts·for·an·input·string·using·the·function | 27 | library·prompts·for·an·input·string·using·the·function |
9 | 28 | .Xr·el_wgets·3·, | |
10 | it·reads·characters·from·the·terminal. | 29 | it·reads·characters·from·the·terminal. |
11 | Invalid·input·bytes·that·do·not·form·characters·are·silently | 30 | Invalid·input·bytes·that·do·not·form·characters·are·silently |
12 | discarded. | 31 | discarded. |
13 | For·each·character·read,·one·editor·command·is·executed. | 32 | For·each·character·read,·one·editor·command·is·executed. |
14 | The·mapping·of·input·characters·to·editor·commands·depends·on·the | 33 | The·mapping·of·input·characters·to·editor·commands·depends·on·the |
15 | editing·mode. | 34 | editing·mode. |
16 | There·are·three·editing·modes:·vi·insert·mode,·vi·command·mode, | 35 | There·are·three·editing·modes:·vi·insert·mode,·vi·command·mode, |
17 | and·emacs·mode. | 36 | and·emacs·mode. |
18 | The·default·is·vi·insert·mode. | 37 | The·default·is·vi·insert·mode. |
19 | The·program·can·switch·the·default·to·emacs·mode·by·using·the | 38 | The·program·can·switch·the·default·to·emacs·mode·by·using·the |
20 | 39 | .Xr·el_set·3 | |
21 | or | 40 | or |
22 | 41 | .Xr·el_parse·3 | |
23 | functions,·and·the·user·can·switch·to·emacs·mode·either·in·the | 42 | functions,·and·the·user·can·switch·to·emacs·mode·either·in·the |
24 | 43 | .Xr·editrc·5 | |
25 | configuration·file·or·interactively·with·the | 44 | configuration·file·or·interactively·with·the |
26 | 45 | .Ic·ed-command | |
27 | editor·command,·in·all·three·cases·executing·the | 46 | editor·command,·in·all·three·cases·executing·the |
28 | 47 | .Ic·bind·Fl·e | |
29 | builtin·command. | 48 | builtin·command. |
49 | .Pp | ||
30 | If·trying·to·read·from·the·terminal·results·in·end·of·file·or·an | 50 | If·trying·to·read·from·the·terminal·results·in·end·of·file·or·an |
31 | error,·the·library·signals·end·of·file·to·the·program·and·does·not | 51 | error,·the·library·signals·end·of·file·to·the·program·and·does·not |
32 | return·a·string. | 52 | return·a·string. |
33 | .S | 53 | .Ss·Input·character·bindings |
34 | All·default·bindings·described·below·can·be·overridden·by·individual | 54 | All·default·bindings·described·below·can·be·overridden·by·individual |
35 | programs·and·can·be·changed·with·the | 55 | programs·and·can·be·changed·with·the |
36 | \fBeditrc\fP(5) | ||
37 | 56 | .Xr·editrc·5 | |
57 | .Ic·bind | ||
38 | builtin·command. | 58 | builtin·command. |
59 | .Pp | ||
39 | In·the·following·tables, | 60 | In·the·following·tables, |
40 | 61 | .Sq·Ctrl- | |
41 | indicates·a·character·with·the·bit·0x40·flipped,·and | 62 | indicates·a·character·with·the·bit·0x40·flipped,·and |
42 | 63 | .Sq·Meta- | |
43 | indicates·a·character·with·the·bit·0x80·set. | 64 | indicates·a·character·with·the·bit·0x80·set. |
44 | In·vi·insert·mode·and·in·emacs·mode,·all·Meta-characters·considered | 65 | In·vi·insert·mode·and·in·emacs·mode,·all·Meta-characters·considered |
45 | printable·by·the·current | 66 | printable·by·the·current |
46 | 67 | .Xr·locale·1 | |
47 | are·bound·to | 68 | are·bound·to |
48 | 69 | .Ic·ed-insert | |
49 | instead·of·to·the·editor·command·listed·below. | 70 | instead·of·to·the·editor·command·listed·below. |
50 | Consequently,·in·UTF-8·mode,·most·of·the·Meta-characters·are·not | 71 | Consequently,·in·UTF-8·mode,·most·of·the·Meta-characters·are·not |
51 | directly·accessible·because·their·code·points·are·occupied·by | 72 | directly·accessible·because·their·code·points·are·occupied·by |
52 | printable·Unicode·characters,·and·Meta-characters·are·usually·input | 73 | printable·Unicode·characters,·and·Meta-characters·are·usually·input |
53 | using·the | 74 | using·the |
54 | 75 | .Ic·em-meta-next | |
55 | editor·command. | 76 | editor·command. |
56 | For·example,·to·enter | 77 | For·example,·to·enter |
57 | 78 | .Sq·Meta-B | |
58 | in·order·to·call·the | 79 | in·order·to·call·the |
59 | 80 | .Ic·ed-prev-word | |
60 | editor·command·in·emacs·mode,·call | 81 | editor·command·in·emacs·mode,·call |
61 | 82 | .Ic·em-meta-next | |
62 | by·pressing·and·releasing·the·escape·key·(or·equivalently,·Ctrl-[), | 83 | by·pressing·and·releasing·the·escape·key·(or·equivalently,·Ctrl-[), |
63 | then·press·and·release·the | 84 | then·press·and·release·the |
64 | 85 | .Sq·B | |
65 | key. | 86 | key. |
66 | If·you·have·configured·a·Meta-key·on·your·keyboard,·for·example | 87 | If·you·have·configured·a·Meta-key·on·your·keyboard,·for·example |
67 | with | 88 | with |
68 | 89 | .Ql·setxkbmap·-option·altwin:left_meta_win·, | |
69 | the·Ctrl-Meta-characters·are·directly·accessible. | 90 | the·Ctrl-Meta-characters·are·directly·accessible. |
70 | For·example,·to·enter | 91 | For·example,·to·enter |
71 | 92 | .Sq·Ctrl-Meta-H | |
72 | in·order·to·call·the | 93 | in·order·to·call·the |
73 | 94 | .Ic·ed-delete-prev-word | |
74 | editor·command·in·emacs·mode,·hold·down·the·keys | 95 | editor·command·in·emacs·mode,·hold·down·the·keys |
75 | `Ctrl', | ||
76 | 96 | .Sq·Ctrl·, | |
97 | .Sq·Meta·, | ||
77 | and | 98 | and |
78 | 99 | .Sq·H | |
79 | at·the·same·time. | 100 | at·the·same·time. |
80 | Alternatively,·press·and·release·the·escape·key,·then·press·and | 101 | Alternatively,·press·and·release·the·escape·key,·then·press·and |
81 | release | 102 | release |
82 | `Ctrl-H'. | ||
103 | .Sq·Ctrl-H·. | ||
104 | .Pp | ||
83 | In·vi·input·mode,·input·characters·are·bound·to·the·following·editor | 105 | In·vi·input·mode,·input·characters·are·bound·to·the·following·editor |
84 | commands·by·default: | 106 | commands·by·default: |
107 | .Bl·-column·-offset·indent·"Ctrl-Z,·TSTP"·"ed-search-next-history" | ||
85 | It·Ctrl-D,·EOF·Ta· | 108 | .It·Ctrl-D,·EOF·Ta·Ic·vi-list-or-eof |
86 | It·Ctrl-H,·BS·Ta· | 109 | .It·Ctrl-H,·BS·Ta·Ic·vi-delete-prev-char |
87 | It·Ctrl-J,·LF·Ta· | 110 | .It·Ctrl-J,·LF·Ta·Ic·ed-newline |
88 | It·Ctrl-M,·CR·Ta· | 111 | .It·Ctrl-M,·CR·Ta·Ic·ed-newline |
89 | It·Ctrl-Q·Ta· | 112 | .It·Ctrl-Q·Ta·Ic·ed-tty-start-output |
90 | It·Ctrl-S·Ta· | 113 | .It·Ctrl-S·Ta·Ic·ed-tty-stop-output |
91 | It·Ctrl-U·Ta· | 114 | .It·Ctrl-U·Ta·Ic·vi-kill-line-prev |
92 | It·Ctrl-V·Ta· | 115 | .It·Ctrl-V·Ta·Ic·ed-quoted-insert |
93 | It·Ctrl-W·Ta· | 116 | .It·Ctrl-W·Ta·Ic·ed-delete-prev-word |
94 | It·Ctrl-[,·ESC·Ta· | 117 | .It·Ctrl-[,·ESC·Ta·Ic·vi-command-mode |
95 | It·Ctrl-\e,·QUIT·Ta· | 118 | .It·Ctrl-\e,·QUIT·Ta·Ic·ed-tty-sigquit |
96 | It·Ctrl-?,·DEL·Ta· | 119 | .It·Ctrl-?,·DEL·Ta·Ic·vi-delete-prev-char |
120 | .El | ||
121 | .Pp | ||
97 | All·other·input·characters·except·the·NUL·character·(Ctrl-@)·are | 122 | All·other·input·characters·except·the·NUL·character·(Ctrl-@)·are |
98 | bound·to | 123 | bound·to |
99 | \fBed-insert\fP. | ||
... Open expanded diff ... |