1. Introduction
In this article, we will show a way to not show the progress bar with curl. It can be helpful especially when we create bash scripts that automate some processes and the progress bar is not needed and even gets in the way.
2. Using the -s
parameter
The -s
param is used to enable silent mode. In the silent mode, the curl will not show the progress meter or error messages.
Check the following command:
In some cases, this is not enough. If you still see the progress bar try to redirect stderr to /dev/null:
You can use the S
param with -s
to show an error message if the request fails:
3. Conclusion
In this article, we presented how to execute a request using curl in silent mode.
{{ 'Comments (%count%)' | trans {count:count} }}
{{ 'Comments are closed.' | trans }}