从下载特定的直通终端。命令访问

2024-04-19 19:16:24 发布

您现在位置:Python中文网/ 问答频道 /正文

我正在尝试在闪存驱动器上创建一个便携式VirtualBox设置。VirtualBox不喜欢在特定目录中手动安装,因此我想创建一个.command文件,通过Mac上的终端安装它。当我运行下面的download.command文件时

python -c "from urllib import urlretrieve; urlretrieve('https://download.virtualbox.org/virtualbox/6.1.0_BETA1/', 'VirtualBox-6.1.0_BETA1-133315-OSX.dmg')"

我收到以下终端输出,没有文件下载

Last login: Fri Oct 18 02:22:17 on ttys001
/Volumes/vBoxGo/VirtualBox/VBoxMacOS.command ; exit;
Michaels-Air:~ mhicks$ /Volumes/vBoxGo/VirtualBox/VBoxMacOS.command ; exit;
logout
Saving session...
...copying shared history...
...saving history...truncating history files...
...completed.

[Process completed]

我应该如何编程

此外,我计划为Windows创建一个类似的程序。任何特定或非特定的指针都值得赞赏


Tags: 文件终端downloadexithistorycommand驱动器virtualbox