bash - 从 Bash shell 脚本发布文件

标签 bash curl

我需要将 PowerPoint 文件发布到可将 PPT 文件转换为 PDF 的在线服务。我是 Bash shell 的新手,不知道如何从我的本地计算机发布 PPT 文件。我应该如何修改下面的行?

curl -i -H "Accept: application/pdf" -X POST http://do.convertapi.com/PowerPoint2Pdf > output

最佳答案

使用 --data-binary <data> 选项。

$ curl --data-binary @your.pdf ...

关于bash - 从 Bash shell 脚本发布文件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9512616/

相关文章:

bash - 如何使用shell命令检查SVN checkout 文件并在目录中创建链接

linux - 在 Bash 脚本中传递变量名称和值

php - 将 cURL header 信息拆分为数组

PHP/ curl : inspecting response headers before downloading body

node.js - 如何使用 'PUT'模块在 Node 中编写curl 'request'请求

python - 将变量从 python 传递到 shell 脚本

bash - 将 STDERR 发送到记录器

linux - bash 解析服务名称

c - 从文件中解析 http 响应

rest - 如何从服务器访问 JIRA