1.从代码仓库克隆源代码:
$ mkdir bzrobot_ws
$ cd bzrobot_ws
$ hg clone http://192.168.15.88/hg/bzrobot_src src
$ catkin_make
$ source devel/setup.sh
(IP 请根据实际实时更新)
2.将本地代码推到代码仓库:
wang@wang-Rev-1-0:~/bzrobot_ws/src$ hg pull http://192.168.15.88/hg/bzrobot_src
wang@wang-Rev-1-0:~/bzrobot_ws/src$ hg update
zhangzhen@Lenovo-B460:~/bzrobot_ws/src$ hg add
zhangzhen@Lenovo-B460:~$ gedit .bashrc
在最后一行加入:export HGUSER="WangCaiJie"
zhangzhen@Lenovo-B460:~$ source .bashrc
zhangzhen@Lenovo-B460:~/bzrobot_ws/src$ hg commit -m"Modifying urdf and gazebo"
zhangzhen@Lenovo-B460:~/bzrobot_ws/src$ hg push
3.用gh log查看更新信息
wang@wang-Rev-1-0:~/bzrobot_ws/src$ hg log
4.一次上传记录
1、按上下箭头键
2、history|more分页显示
3、vi /etc/profile找HISTSIZE=1000,说明你最多能存1000条历史记录。
4、!!执行最近执行的命令
5、history|head或者history |tail看记录的前几条或后几条
6、!100 执行第100条记录
7、fc -l 和history一样
8、CTRL+r输入字符ls查询包含ls的命令
9、history -c 清除以前的记录
http://www.wallcopper.com/linux/593.html
1773 cd ~/bzrobot_ws3
1774 ls
1775 cd src
1776 hg status
1777 ls
1778 cd bzrobot/
1779 ls
1780 cd ..
1781 ls
1782 find . -name *~
1783 find . -name *~ -exec rm {} \;
1784 find . -name *~
1785 ls
1786 cd bzrobot/
1787 ls
1788 cd ..
1789 hg status
1790 hg addremove
1791 hg status
1792 hg pull
1793 hg update
1794 hg resolve
1795 diff
1796 hg resove
1797 hg resolve
1798 hg resolve --all
1799 cd bzrobot/bzrobot_comm/
1800 ls
1801 hg merge CMakeLists.txt
1802 ls
1803 hg resolve CMakeLists.txt
1804 hg resolve CMakeLists.txt --mark
1805 gedit CMakeLists.txt
1806 hg resolve CMakeLists.txt
1807 cd scripts/
1808 hg resolve rs232_encoder_pub_motor_sub.py --mark
1809 gedit rs232_encoder_pub_motor_sub.py
1810 hg resolve --help
1811 hg status
1812 hg addremove
1813 ls
1814 hg update
1815 hg status
1816 hg commit -u"Wang CaiJie" -m"Modify Rs232 encoding publisher, add stm32 usb to uart encoder publisher"
1817 hg resolve -all
1818 gedit rs232_encoder_pub_motor_sub.py
1819 hg resolve -m rs232_motor_sub.py
1820 hg resolve -m stm32_usbtouart_encoder_pub.py
1821 hg status
1822 hg resolve
1823 hg resolve --help
1824 hg resolve --help -a
1825 hg resolve -a
1826 hg log
1827 hg commit -u"Wang CaiJie" -m"Modify Rs232 encoding publisher, add stm32 usb to uart encoder publisher"
1828 hg log
1829 hg push
mkdir codes
cd codes
ls
hg clone http://192.168.15.88/hg/bzrobot2 src
ls
cd src
ls
cd ..
ls
catkin_make
ls
cd src
ls
hg addremove
hg status
ls
hg commit -uWangCaiJie -m"Upload bzrobot_comm and bzrobot_comm_src"
hg status
hg push
ls
cd ..
catkin_make
cd src
hg addremove
hg commit -uZhangzhen -m"Upload bzrobot_msgs"
hg push
ls
cd ..
catkin_make