I have tried same like below but getting same message.
wget http://mirrors.estointernet.in/apache/maven/maven-3/3.6.0/source/apache-maven-3.6.0-src.zip # from https://maven.apache.org/download.cgi
unzip apache-maven-3.6.0-src.zip
vi .bash_profile
export JAVA_HOME=/opt/soft/jdk1.8.0_192
M2_HOME=/opt/soft/maven/apache-maven-3.6.0
export M2_HOME
PATH=$PATH:$HOME/bin:$JAVA_HOME/bin:$M2_HOME/bin
After that I have executed :
source .bash_profile
mvn --version
I get the following error:
bash: mvn: command not found