On 12/12/23 10:18 AM, 林宏雄 wrote:

https://tiswww.cwru.edu/php/chet/readline/readline.html#index-rl_005fstartup_005fhook 
<https://tiswww.cwru.edu/php/chet/readline/readline.html#index-rl_005fstartup_005fhook>

 > Variable: rl_hook_func_t * rl_startup_hook
> If non-zero, this is the address of a function to call just before readline prints the first prompt.

rl_startup_hook is called before readline prints every prompt.

rl_startup_hook is called once for each invocation of readline(), before
readline prints the prompt for the first time. This is what your code
shows.


--
``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    [email protected]    http://tiswww.cwru.edu/~chet/


Reply via email to