WDCP Environment Build shell script Analysis--lanmp.sh---lib/common.sh

Source: Internet
Author: User

#common. SH, which is mainly some function # perform compiled cleanup work function make_clean {    # $RE _ins  based on the value of the variable, To determine whether to perform cleanup work     if [  $RE _ins == 1 ]; then         make clean >/dev/null 2>&1    fi}# Download function function wget_down {     #判断 $SOFT The value of _down, if 1, perform the download     if  [  $SOFT _down == 1 ]; then        echo   "Start down ..."         for i in $*; do             [ $ (wget -c  $i)  ]  && exit        done    fi}# Error Exit Function function err_exit {    echo     echo      echo&nbsP; " ----install error: $1 -----------"    echo    echo       exit }   #错误函数function  error {     echo  "error: $1"     EXIT     } #文件复制函数function  file_cp {     [ -f $2 ] && mv $2  ${2}$ (date +%y%m%d%h)     cd  $IN _pwd/conf    [ -f  $1 ] && CP -F $1 $2} #文件复制函数function  file_cpv {     cd  $IN _pwd/conf     [ -f $1 ] &&  CP -F $1 $2} #文件删除函数function  file_rm {    [ -f $1  ] && RM -F $1} #文件备份函数function  file_bk {    [  -f $1 ] && mv $1 ${1}_$ (date +%y%m%d%h)}  #配置完成提示函数function  lanmp_in_finsh {     echo    echo    echo     echo  "      congratulations ,lanmp install is complete"     echo  "      VISIT HTTP://IP"      echo  "      more infomation please visit  51cto.com "    echo}


WDCP Environment Build shell script Analysis--lanmp.sh---lib/common.sh

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.