CodeJobler - Craftsman Programmer

bash - how to get the result of an echo into a variable

Fri 17 July 2020 in «tip» by Michael Beard
Tags: tip, bash, echo, variable, how-to, script

Here is how you assign what comes back from an echo statement to a bash variable.

How to assign the result of echo to a variable in bash script

MY_CHOICE=`echo $1 | tr "[:lower:]" "[:upper:]"`
Post in «tip» by Michael Beard
Tags: #tip #bash #echo #variable #how-to #script

Pages

  • Home
  • Categories
  • Archives
  • Tags

Categories

  • blog
  • fun
  • interesting
  • react
  • tip
  • tool
  • tools

Links

  • Pelican
  • Diary of a Developer

Powered by Pelican