wget print content to screen
wget is used to download files. When you use wget to run cronjob, it create lot of files. To avoid this, you can replace wget command with curl.
If you want to use wget, you can use -O option, that speicify file to save. You can use -O /dev/stdout, so downloaded file content will be written to stdout.
1 |
wget -O /dev/stdout http://checkip.amazonaws.com |
You can use -q to hide the download progres message (quite).
1 |
wget -q -O /dev/stdout http://checkip.amazonaws.com |
-O /dev/stdout can be replaced with
1 |
-O - |
Or
1 |
-O- |
Example
1 |
wget -qO- http://checkip.amazonaws.com |
See wget