file.sh
#!/bin/bash
fileName="Screenshot_$(TZ=GMT-3 date +%Y%m%d_%H%M%S).png"
echo "|$fileName|"
Terminal at Ubuntu 19.04:
> bash file.sh
|Screenshot_20190521_104141.png
|
I want to understand why a new-line is added to the variable at end?
file.sh
#!/bin/bash
fileName="Screenshot_$(TZ=GMT-3 date +%Y%m%d_%H%M%S).png"
echo "|$fileName|"
Terminal at Ubuntu 19.04:
> bash file.sh
|Screenshot_20190521_104141.png
|
I want to understand why a new-line is added to the variable at end?