GNU Readline
- 简介
- 安装/配置
- 预定义常量
- Readline 函数
- readline — 读取一行
- readline_add_history — 添加一行到历史
- readline_callback_handler_install — 初始化 readline 回调接口和终端,然后打印提示并立即返回
- readline_callback_handler_remove — 移除之前已安装的回调函数句柄并且恢复终端设置
- readline_callback_read_char — 当一个行被接收时读取一个字符并且通知 readline 回调接口
- readline_clear_history — 清除历史
- readline_completion_function — 注册完成函数
- readline_info — 获取/设置各种 readline 内部变量
- readline_list_history — 获取历史
- readline_on_new_line — 通知 readline 将光标移动到新行
- readline_read_history — 读取历史
- readline_redisplay — 重绘显示区
- readline_write_history — 写入历史记录
+添加备注
用户贡献的备注 1 note
list2011 at lunch dot za dot net ¶
13 years ago
When readline is enabled, php switches the terminal mode to accept line-buffered input. This means that the proper way to use the cli when you pipe to an interactive command is to explicitly specify that php is not using the terminal for input:
php somescript.php < /dev/null | less