linux - shell 脚本 : how to output to command line?

标签 linux command-line shell

我正在制作一个 shell 脚本,我想知道是否可以在脚本执行时直接写入命令行?

示例:

user@localhost:/home/user$./script.sh
... output
... another output
... another output
... last output
user@localhost:/home/user$I want to write here on the command line

我不想“回显”某些文本,我想直接在提示符下写入。

谢谢!

最佳答案

不,你不能那样做。如果您希望用户在脚本完成后调用您提供的命令 - 为什么不提示用户进行确认?

关于linux - shell 脚本 : how to output to command line?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3550640/

相关文章:

android - 在 OS X 上运行 ADB shell

java - 如果命令返回错误,是否可以防止在运行命令后自动关闭 cmd?

python - 通知包版本更改的脚本

linux - find命令重命名文件

xml - 在导入具有特定 'batchnumber' 标记的 xml 文件之前查询 Oracle 表是否存在 'batchnumber'

linux - eBPF - 无法从跟踪点 sys_enter_execve 读取 argv 和 envp

linux - 将所选用户的 foo@bar$ 更改为 foo@bar#

linux - 如何在 Ubuntu 16.04 中访问 BitLocker 加密的驱动器?

linux - Redis "--protected-mode no"磁盘上没有持久数据

python - 如何在 Windows 命令提示符下运行 python 文件?