为什么file xxx.src
导致cannot open `xxx.src' (No such file or directory)
但退出状态为 0(成功)?
$ file xxx.src ; echo $?
xxx.src: cannot open `xxx.src' (No such file or directory)
0
Run Code Online (Sandbox Code Playgroud)
注意:比较ls
:
$ ls xxx.src ; echo $?
ls: cannot access 'xxx.src': No such file or directory
2
Run Code Online (Sandbox Code Playgroud) 如何获取scp
版本?
已经尝试过:
$ scp --version
scp: unknown option -- -
usage: scp [-346ABCOpqRrsTv] [-c cipher] [-D sftp_server_path] [-F ssh_config]
[-i identity_file] [-J destination] [-l limit]
[-o ssh_option] [-P port] [-S program] source ... target
$ man scp | grep version
<nothing>
Run Code Online (Sandbox Code Playgroud)
意思是scp
没有版本吗?
设想:
$ cat t0.txt
xxx
yyy
$ man grep | grep '\-\-null\-data' -A1
-z, --null-data
Treat the input as a set of lines, each terminated by a zero byte (the ASCII NUL character) instead of a newline.
$ grep -Pzo 'xxx\0yyy' t0.txt
<nothing>
$ grep -Pzo 'xxx\nyyy' t0.txt
xxx
yyy
Run Code Online (Sandbox Code Playgroud)
那么,如果 grep “将输入视为一组行,每行以零字节终止”,那么为什么'xxx\0yyy'
不产生结果呢?
我需要从(34G)中提取特定文件夹。.tar.bz2
问题是需要1个小时。我猜这是由于压缩造成的。我想对特定文件夹进行不压缩提取会更快。
因此,是否可以.tar
从获得.tar.bz2
?