gpt4 book ai didi

linux - 如何将文件移动到参数路径?

转载 作者:太空狗 更新时间:2023-10-29 11:46:41 24 4
gpt4 key购买 nike

假设我有以下代码,

mkdir $1
# Output that the folder was created and the name
echo "The folder was created and name is: `echo $1`"

touch $2
# Output that the file was created and the name
echo "The file was created and name is: `echo $2`"

如何将创建的文件移动到创建的参数文件夹?

最佳答案

你需要使用命令mv

mv $2 $1

关于linux - 如何将文件移动到参数路径?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9508929/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com