Skip to content

Instantly share code, notes, and snippets.

@ahoarau
Last active September 8, 2015 17:08
Show Gist options
  • Save ahoarau/bcb9a6966d2a1d82d88a to your computer and use it in GitHub Desktop.
Save ahoarau/bcb9a6966d2a1d82d88a to your computer and use it in GitHub Desktop.
Everything from scratch
#!/usr/bin sh
echo 'Upgrades'
sudo apt-get update
sudo apt-get -y upgrade
#sudo apt-get -y dist-upgrade
echo 'Git'
sudo apt-get install -y git
echo 'OpenSSH'
sudo apt-get install -y openssh-server openssh-client sshfs
echo 'Build stuff'
sudo apt-get install -qq google-mock lcov
sudo pip install cpp-coveralls --use-mirrors
echo 'OmniORB'
sudo apt-get install -y omniorb*
echo 'Htop'
sudo apt-get install -y htop
echo 'NTP'
sudo apt-get install -y ntp
sudo service ntp restart
echo 'Terminator'
sudo apt-get -y install terminator
## Set terminator to default
gconftool --type string --set /desktop/gnome/applications/terminal/exec terminator
echo 'Chrome'
sudo apt-get -y install libxss1 libappindicator1 libindicator7
wget -nc https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo dpkg -i google-chrome*.deb
echo 'Various IDES'
sudo apt-get -y install qtcreator kdevelop spyder eclipse
echo 'Atom'
wget https://atom.io/download/deb
sudo dpkg -i deb
## ROS Hydro
ROS_DISTRO=indigo
if [ $(lsb_release -cs) == "precise" ]; then ROS_DISTRO=hydro ;fi
if [ $(lsb_release -cs) == "trusty" ]; then ROS_DISTRO=indigo ;fi
if [ $(lsb_release -cs) == "vivid" ]; then ROS_DISTRO=jade ;fi
sudo sh -c "echo 'deb http://packages.ros.org/ros/ubuntu $(lsb_release -cs) main' > /etc/apt/sources.list.d/ros-latest.list"
wget http://packages.ros.org/ros.key -O - | sudo apt-key add -
sudo apt-get update
sudo apt-get -y install ros-$ROS_DISTRO-desktop-full ros-$ROS_DISTRO-moveit-* ros-$ROS_DISTRO-ros-control* ros-$ROS_DISTRO-control* python-rosinstall python-pip ros-$ROS_DISTRO-openni* ros-$ROS_DISTRO-gazebo-ros-control
if [ $(lsb_release -cs) == "precise" ]; then sudo apt-get install -y gazebo ;fi
if [ $(lsb_release -cs) == "trusty" ]; then sudo apt-get install -y gazebo2 ;fi
#ROS
echo 'source /opt/ros/$ROS_DISTRO/setup.bash' >> ~/.bashrc
source ~/.bashrc
## Rosdep
sudo rosdep init
rosdep update
# OROCOS
toolchain-version=2.8
if [ $ROS_DISTRO == "hydro" ]; then toolchain-version=2.7 ;fi
if [ $ROS_DISTRO == "indigo" ]; then toolchain-version=2.8 ;fi
if [ $ROS_DISTRO == "jade" ]; then toolchain-version=2.8 ;fi
sudo apt-get install -y ros-$ROS_DISTRO-metaruby
mkdir ~/orocos_iso_ws/
cd ~/orocos_iso_ws
rosdep install --from-paths src --ignore-src --rosdistro $ROS_DISTRO -y
git clone --recursive https://github.com/orocos-toolchain/orocos_toolchain.git -b toolchain-$toolchain-version src/orocos/orocos_toolchain
## Get the very latest updates (might be unstable)
git submodule foreach git checkout toolchain-$toolchain-version
# RUBY WORKAROUND
sudo apt-get install -y ruby-configurate
sudo updatedb
config=$(locate config.h | grep ruby)
config_dir=${config%ruby/config.h}
catkin_make_isolated --install -DENABLE_CORBA=ON -DCORBA_IMPLEMENTATION=OMNIORB -DRUBY_CONFIG_INCLUDE_DIR=$config_dir
source install_isolated/setup.sh
## workspace
mkdir -p ~/rtt_ros_ws/src
cd ~/rtt_ros_ws/src
catkin_init_workspace
git clone https://github.com/jbohren/rqt_dot.git
git clone https://github.com/jhu-lcsr/rtt_ros_control.git
git clone https://github.com/ahoarau/rtt_gazebo
git clone https://github.com/orocos/rtt_geometry.git
git clone https://github.com/jbohren/conman.git
git clone https://github.com/orocos/rtt_ros_integration -b $ROS_DISTRO-devel
cd ~/rtt_ros_ws/
rosdep install -r --from-paths ~/rtt_ros_ws/src --ignore-src --rosdistro $ROS_DISTRO -y
catkin_make -DCATKIN_ENABLE_TESTING=OFF
source ~/rtt_ros_ws/devel/setup.sh
# lwr
mkdir -p ~/lwr_ws/src
cd ~/lwr_ws/src
catkin_init_workspace
git clone https://github.com/kuka-isir/rtt_ros_kdl_tools
git clone --recursive https://github.com/kuka-isir/rtt_lwr
git clone https://github.com/kuka-isir/rtt_lwr_controllers
wget https://raw.githubusercontent.com/IDSCETHZurich/re_trajectory-generator/master/kuka_IK/include/friComm.h
mv friComm.h ~/catkin_ws/src/rtt_lwr/lwr_hardware/kuka_lwr_fri/include/kuka_lwr_fri/friComm.h
cd ~/lwr_ws/
catkin_make
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment