I am executing below script but i get an error line 14: last-tag=TSTA-6: command not found i.e. at the point i try to store the command output in variable (TSTA-6 is output of command). Any ideas where am i going wrong?#!/bin/bashecho This script will remote trigger tagging job. Kindly provide Inputsrelease=-1if [ -z $1 ];then echo Enter release number [In 3 digit format i.e. 20.0.0]  read releaseelse release=$1;fi last-tag=$(svn ls -v https://abc.com/tags | sort -k1 | tail -1 | tr -s ' ' | cut -d' ' -f7 | cut -d'/' -f1)  echo release is: $last-tag 
Unable to store command output in variable
bash;shell script
The shell is looking for a command called last-tag=TSTA-6 because last-tag is not a valid variable name, so once the shell sees the dash - in last-tag, the shell begins to look for a command.  As in the comments, change last-tag to a valid variable name such as lasttag or last_tag.