Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

linux bash assign variable and print to console

# Example:
MY_VAR=a    # here you assigned the value 'a' to MY_VAR
echo $MY_VAR
echo MY_VAR
# output:
a
MY_VAR
# good practice says to name variable in all caps to differ from commands
# if you want to print to print to console the value of MY_VAR, you must use $
# if you echo without using $, the name of the variable will be printed
# not the value
Comment

PREVIOUS NEXT
Code Example
Shell :: remove remote origin git 
Shell :: free space in ubuntu 
Shell :: install specific gitlab version on ubuntu 
Shell :: git auto sign 
Shell :: shell run in background no output 
Shell :: top running port 
Shell :: how to run a specific knex seed file 
Shell :: nano add line numbers 
Shell :: wireguard turn on 
Shell :: push a new local repository to github. 
Shell :: where is office folder 
Shell :: git push unable to create temporary object directory 
Shell :: git revert last 2 commits 
Shell :: snapcraft 
Shell :: docker on linux 
Shell :: Check Firewall setup 
Shell :: reset branch to other branch 
Shell :: linux password expires date 
Shell :: how to install simple screen recorder in fedora 
Shell :: download sklearn linux 
Shell :: mongodb install windows 
Shell :: git fetch all after --single-branch 
Shell :: how to edit and save crontab in linux 
Shell :: how to print array bash 
Shell :: how to use https in npm install instead of ssh 
Shell :: mac kill process 
Shell :: docker db instance workbench connection 
Shell :: windows batch script to run application in background 
Shell :: pyinstaller add files 
Shell :: install serial port using npm 
ADD CONTENT
Topic
Content
Source link
Name
6+8 =