加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 综合聚焦 > 服务器 > 安全 > 正文

文件 – Unix – 将一个目录的内容复制到另一个

发布时间:2020-12-15 16:36:12 所属栏目:安全 来源:网络整理
导读:Folder1/ -fileA.txt -fileB.txt -fileC.txt mkdir Folder2/ [copy command] 现在Folder2 /看起来像: Folder2/ -fileA.txt -fileB.txt -fileC.txt 如何使这发生?我试过cp -r Folder1 / Folder2 /但我最后得到: Folder2/ Folder1/ -fileA.txt -fileB.txt -
Folder1/
    -fileA.txt
    -fileB.txt
    -fileC.txt

> mkdir Folder2/

> [copy command]

现在Folder2 /看起来像:

Folder2/
    -fileA.txt
    -fileB.txt
    -fileC.txt

如何使这发生?我试过cp -r Folder1 / Folder2 /但我最后得到:

Folder2/
    Folder1/
        -fileA.txt
        -fileB.txt
        -fileC.txt

这是接近但不完全是我想要的。

谢谢!

尝试这个:
cp Folder1/* Folder2/

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读