Linux,maven,redis,android,java,yum,ant部署相關命令

來源:互聯網
上載者:User

標籤:linux   maven   redis   

(linux系統查看)

getconf LONG_BIT 查看系統位元


(java環境變數)

export JAVA_HOME=/home/gcweb/usr/java/jdk1.7.0_45

export PATH=$JAVA_HOME/bin:$PATH

如果需要修改到系統變數中:

cd ~

vi .bash_profile

然後開始編輯,退出Esc-->:-->q     只退出,不儲存


(android 配置)

cd /home/gcweb/usr/sdk

wget http://dl.google.com/android/android-sdk_r22.6.2-linux.tgz

tar -zxvf android-sdk_r22.6.2-linux.tgz

cp -r /home/gcweb/usr/sdk/android-sdk-linux/* /home/gcweb/usr/sdk 拷貝整個檔案夾

rm -rf android-sdk-linux/

export ANDROID_HOME=/home/gcweb/usr/sdk

export PATH=$ANDROID_HOME/tools:$ANDROID_HOME/platform-tools:$PATH

Android鏡像更新SDK,如果網址不行,用對應的IP

android list sdk --proxy-host 219.216.128.25 --proxy-port 80 -s -u

android update sdk --proxy-host 219.216.128.25 --proxy-port 80 -s -u

adb  (查看Android是否安裝成功)


yum安裝(安裝之前查看系統版本,根據版本搜尋響應的鏡像檔案):

/etc/yum.repos.d 下面的檔案全部刪除,刪除之前請做好備份

wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-5.repo

CentOS-Base.repo  更新鏡像檔案 

yum makecache  重新整理緩衝

yum list|grep xulrunner 查詢32位運行庫,非centos是 ia32打頭的 

yum install xulrunner.i686


(運行jenkins)

export JAVA_HOME=/home/jdk1.8.0_141

export PATH=$JAVA_HOME/bin:$PATH 

cd /home/jenkins

java -jar jenkins.war


(安裝ant,Android源碼打包工具--http://ant.apache.org/bindownload.cgi)

下載apache-ant-1.10.1-bin.tar.gz,複製到/home/gcweb/usr/ant

cd /home/gcweb/usr/ant

tar -vxzf apache-ant-1.10.1-bin.tar.gz 

cp -r /home/gcweb/usr/ant/apache-ant-1.10.1/* /home/gcweb/usr/ant 拷貝整個檔案夾

rm -rf apache-ant-1.10.1/

export JAVA_HOME=/home/gcweb/usr/java/jdk1.8.0_111

export PATH=$JAVA_HOME/bin:$PATH

export ANDROID_HOME=/home/gcweb/usr/sdk

export PATH=$ANDROID_HOME/tools:$ANDROID_HOME/platform-tools:$PATH

export ANT_HOME=/home/gcweb/usr/ant/

export PATH=$PATH:$ANT_HOME/bin

--開始Android打包

cd /home/androidSrc/ceshi

android update project -p ./Hell0 -n Hell0 -t 11

--Android測試專案產生和打包

android create project -n test -a MainActivity -k com.time2011.test -t 11 -p ./test

cd test (前往項目test目錄下面)

ant debug (發布debug版本)


(maven安裝)

cd /home/gcweb/usr/

wget http://mirrors.hust.edu.cn/apache/maven/maven-3/3.2.5/binaries/apache-maven-3.2.5-bin.tar.gz

tar -zxvf apache-maven-3.2.5-bin.tar.gz

export MAVEN_HOME=/home/gcweb/usr/apache-maven-3.2.5

export PATH=${PATH}:${MAVEN_HOME}/bin

本文出自 “IT技術男” 部落格,請務必保留此出處http://shengguimin.blog.51cto.com/3162140/1949409

Linux,maven,redis,android,java,yum,ant部署相關命令

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

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.