Questions tagged «command-line»

有关使用命令行界面(CLI)的问题。



5
在Guake终端中打开选项卡的脚本
我正在gnome终端上使用此脚本: #!/bin/sh gnome-terminal --tab --title="1" --command="ssh 1" \ --tab --title="2" --command="ssh 2" \ --tab --title="3" --command="ssh 3" \ --tab --title="4" --command="ssh 4" exit 0 如何在Guake终端上通过脚本执行相同的操作?



5
ls --directory代表什么?
在我的Ubuntu版本中,man ls具有有关--directory的下一个信息: list directory entries instead of contents, and do not dereference symbolic links 所以我有点困惑。我使用了该命令,ls --directory并且希望包含所有目录的列表,但是我得到了. 那么究竟是什么ls --directory或ls -d做什么?
17 command-line  ls 



5
Ubuntu 14.04:从命令行创建的新用户缺​​少功能
我正在尝试从bash命令行在Ubuntu 14.04 LTS中创建一个新用户。我使用以下命令: sudo useradd -c "Samwise the Brave" sam sudo passwd sam Enter new UNIX password: hello-1234 Retype new UNIX password: hello-1234 passwd: password updated successfully 创建此新用户后,我遇到了3个问题: 我无法使用sam用户登录Ubuntu。每当我登录时,我都会被发送回登录屏幕。 当我查看/etc/passwd文件时,可以看到没有为用户sam定义默认外壳程序: cat /etc/passwd | grep sam sam:x:1003:1003:Samwise the Brave:/home/sam: Sam的主文件夹未创建,即/home/sam不存在。 关于什么可能导致所有这些问题的任何线索? 我应该在这里注意,当我使用Unity Control Center创建用户时,不会发生这些问题。但是我希望能够使用命令行,因为我要创建许多用户。

3
在使用youtube-dl提取音频时如何指定文件名?
我可以使用以下命令创建YouTube视频的mp3: youtube-dl --extract-audio --audio-format mp3 http://www.youtube.com/watch?v=rtOvBOTyX00 它将使用以下文件名创建一个mp3: Christina Perri - A Thousand Years [Official Music Video]-rtOvBOTyX00.mp3 我不需要最后的视频ID部分(rtOvBOTyX00),并且希望拥有以下内容: Christina Perri - A Thousand Years [Official Music Video].mp3 youtube-dl的选项可以实现吗?如果没有,那么下一个最佳解决方案是什么?


2
由于“无法打开终端'/ dev / pts / 1'-请检查”错误而无法运行屏幕
为了学习一些服务器管理,我刚刚创建了一个新的Ubuntu 12.04服务器。由于我只有一个root帐户,因此我使用创建了一个新用户adduser kramer65。然后,我使用切换到该用户su kramer65。我现在想运行屏幕,所以我输入screen并按下回车键,然后显示以下行: Cannot open your terminal '/dev/pts/1' - please check. 在这里我迷路了。为什么不打开屏幕,如何处理非常有用的提示“ 请检查 ”,我该怎么办? 欢迎所有提示!




By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.