当前位置: 首页 > news >正文

怎么让网站能被百度到网站建设公制度

怎么让网站能被百度到,网站建设公制度,宁波seo推广推荐,台州 做网站分享一个linux下一键安装nodenpm脚本。 使用方式为#xff1a; ./install-node.sh#xff0c;然后输入版本号#xff0c;node.js版本查询 切记不需要加 sudo 执行!!! 默认安装10.15.0。 #! /bin/bash############################################################ # …分享一个linux下一键安装nodenpm脚本。 使用方式为 ./install-node.sh然后输入版本号node.js版本查询 切记不需要加 sudo 执行!!! 默认安装10.15.0。 #! /bin/bash############################################################ # 此脚本为一键安装node-npm脚本 # # 2018-08-24 # # 使用方式为./install-node.sh # ############################################################nodeVersion10.15.0 # 安装的默认版本 VERSIONPATTERN[0-9]{1,2}.[0-9]{1,2}.[0-9]{1,2}echo -n Please input a node version number (Enter 10.15.0): read customVersion # user custom version, eg. 10.15.0if [ ! -z $customVersion ] # 如果输入的版本不为空 thenmacthResult$(echo $customVersion | grep -E -x $VERSIONPATTERN )if [ -z $macthResult ]thenecho Please input a right version number. eg. 8.11.4 or 10.15.0exit 1finodeVersion$customVersion fi # 下载网址 downloadAddresshttps://nodejs.org/download/release/v${nodeVersion}/node-v${nodeVersion}-linux-x64.tar.gz downloadPath/opt/ # 默认安装的路径nodePath/opt/node/ packageNamenode.tar.gz sysPathFileForNode/etc/profile.d/node.sh # system PATH file name for node.currentUser$(whoami)if [[ $currentUser root ]] thenecho please execute script by user! Not root!exit fiisReinstalln # Check if node is already installed. checkNodeIsExist() {# 1.Check whether the node command exists.if [[ $(checkCmd node) y ]]thenecho -n The node command already exists,whether to reinstall [y/n]? :read isReinstallif [[ ${isReinstall} y ]] || [[ {$isReinstall} Y ]] # not reinstallthenechoelseexit 1fifiecho Check local node has been completed. }download() {echo Download version is $nodeVersionechosudo wget -O $packageName $downloadAddressif [ $? -ne 0 ]thenecho The node package download faild !exit 1fisudo mv ./$packageName $downloadPathecho The node v${nodeVersion} has been downloaded. }decompress() {sudo tar -zxf ${downloadPath}${packageName} -C $downloadPath# check isReinstallif [[ $isReinstall y ]] || [[ $isReinstall Y ]]then# update node binary filesudo mv ${downloadPath}node-v${nodeVersion}-linux-x64/bin/node ${downloadPath}node/bin/# update npmsudo rm -rf ${downloadPath}node/lib/node_modules/npmsudo mv ${downloadPath}node-v${nodeVersion}-linux-x64/lib/node_modules/npm/ ${downloadPath}node/lib/node_modules/sudo mv ${downloadPath}node-v${nodeVersion}-linux-x64/bin/npm ${downloadPath}node/bin/# update npx link filesudo mv ${downloadPath}node-v${nodeVersion}-linux-x64/bin/npx ${downloadPath}node/bin/# remove include/node foldersudo rm -rf ${downloadPath}node/include/node# update include/node flder sudo mv ${downloadPath}node-v${nodeVersion}-linux-x64/include/node ${downloadPath}node/include/# remove share foldersudo rm -rf ${downloadPath}node/share# update share foldersudo mv ${downloadPath}node-v${nodeVersion}-linux-x64/share ${downloadPath}node/# update CHANGELOG.md 、LICENSE 、README.md filesudo mv ${downloadPath}node-v${nodeVersion}-linux-x64/CHANGELOG.md ${downloadPath}node/sudo mv ${downloadPath}node-v${nodeVersion}-linux-x64/LICENSE ${downloadPath}node/sudo mv ${downloadPath}node-v${nodeVersion}-linux-x64/README.md ${downloadPath}node/sudo rm -rf ${downloadPath}node-v${nodeVersion}-linux-x64sudo rm -rf ${downloadPath}${packageName}elsesudo mv ${downloadPath}node-v${nodeVersion}-linux-x64 ${downloadPath}nodesudo rm ${downloadPath}${packageName}if [ $? -ne 0 ]thenecho Faild to decompressed!exit 1fifiecho The node package has been decompressed. }changePermission() {sudo chown ${currentUser}:${currentUser} ${nodePath} -Recho The node folder permission has been changed. }# Configure system environment variables and export executable paths of node and NPM. configSysPath() {local tempFilenode.shtouch $tempFileecho export NODE_HOME/opt/node $tempFileecho export PATH$PATH:$NODE_HOME/bin $tempFileecho export NODE_PATH$PATH:$NODE_HOME/lib/node_modules $tempFilesudo mv ./$tempFile $sysPathFileForNode }checkCmd() {local cmd$1which $cmd /dev/null 21if [[ $? 0 ]]thenecho yelseecho nfi }npmCompletion() {local temp/tmp/npm_completionecho if type complete /dev/null; then_npm_completion () {local words cwordif type _get_comp_words_by_ref /dev/null; then_get_comp_words_by_ref -n -n -n : -w words -i cwordelsecword$COMP_CWORDwords(${COMP_WORDS[]})filocal si$IFSIFS$\n COMPREPLY($(COMP_CWORD$cword \COMP_LINE$COMP_LINE \COMP_POINT$COMP_POINT \npm completion -- ${words[]} \2/dev/null)) || return $?IFS$siif type __ltrim_colon_completions /dev/null; then__ltrim_colon_completions ${words[cword]}fi}complete -o default -F _npm_completion npm elif type compdef /dev/null; then_npm_completion() {local si$IFScompadd -- $(COMP_CWORD$((CURRENT-1)) \COMP_LINE$BUFFER \COMP_POINT0 \npm completion -- ${words[]} \2/dev/null)IFS$si}compdef _npm_completion npm elif type compctl /dev/null; then_npm_completion () {local cword line point words siread -Ac wordsread -cn cwordlet cword-1read -l lineread -ln pointsi$IFSIFS$\n reply($(COMP_CWORD$cword \COMP_LINE$line \COMP_POINT$point \npm completion -- ${words[]} \2/dev/null)) || return $?IFS$si}compctl -K _npm_completion npm fi $tempsudo mv $temp /etc/bash_completion.d/ }main() {echo ------------------------START-------------------------# 1. check node installationcheckNodeIsExist# 2. download node packagedownload# 3. decompree node packagedecompress# 4. change node folder permissionchangePermission# 5. install npm completionnpmCompletion# 6. configure node configconfigSysPathsource $sysPathFileForNode # Enable the configuration to take effect immediately.echo ------------------------END-------------------------echo -e Successfully installed node and NPM.\nPlease try : node -v and npm -v }main
http://wiki.neutronadmin.com/news/110194/

相关文章:

  • 局域网内服务器做网站上海网络推广工资
  • 做平台网站怎么做营业执照年报官网入口
  • 建微网站重庆市任免干部
  • 比较好的企业网站wordpress tag到导航
  • 网站集约化建设意见打开网页出现网站建设中
  • 关于网站开发的参考文献有哪些网站建设的电话销售
  • 河北建设安装工程有限公司怎么样seo是什么意思 seo是什么职位
  • 广东建设项目备案公示网站青岛网站权重提升
  • 荣县住房和城乡建设厅网站网络营销对传统营销有哪些冲击
  • 西安建设网站公司怎么建设淘宝联盟的网站
  • 视频网站X站H站搭建建设天津网架公司
  • 学校网站建设培训方案模板潍坊市住房和城乡建设局网站下载
  • 教你如何用天翼云盘做网站如何设计个人网站
  • 页面看不到网站wordpress更改固定链接后
  • 徐州网站建设网络推广wordpress park主题
  • 上传到网站的根目录中国内网站制作特点
  • 贵阳网站建设功能济宁优化推广公司
  • 江门h5模板建站开装潢公司做网站
  • 自建网站备案通过后怎么做宁波网络公司董事长
  • 网站开发网页跳转到新的页面网站建设和管理情况自查报告
  • 新乡做网站的公司oa系统下载
  • php网站连接数据库教程济南物流公司网站建设
  • 贵金属如何用网站开发客户油漆涂料网站建设
  • 如何引用404做网站网站平台建设哪家公司好
  • 建设网站需要哪些费用电商培训机构需要什么资质
  • 广州淘宝网站建设开发板推荐
  • 互联网公司响应式网站周口网站制作哪家好
  • 苏州网站建设caiyiduo百度关键词搜索怎么弄
  • 基金会网站开发方案网站项目上线流程
  • 做网站需要做手机版吗广东东莞地图