Skip to content

Instantly share code, notes, and snippets.

@surajRathi
Created March 22, 2022 07:12
Show Gist options
  • Save surajRathi/0dc80c361d585201fd9e8d7ce73ea5b7 to your computer and use it in GitHub Desktop.
Save surajRathi/0dc80c361d585201fd9e8d7ce73ea5b7 to your computer and use it in GitHub Desktop.
Integrate clion with multi package catkin tools setup
export ROS_HOSTNAME=$(hostname -I | awk '{print $1}' | head -c -1 -)
source ./devel/setup.zsh
export CATKIN_PROFILE="$(catkin profile list | awk '/\(active\)/{print $2}')"
echo -ne "[\n]" > $ROS_WS_DIR/.catkin_tools/CATKIN_BUILD_DUMMY.json
catkin_build() {
catkin build $@
cat $ROS_WS_DIR/.catkin_tools/CATKIN_BUILD_DUMMY.json $ROS_WS_DIR/build/*/compile_commands.json(N) $ROS_WS_DIR/.catkin_tools/CATKIN_BUILD_DUMMY.json | sed 's:\]\[:,:' > "${ROS_WS_DIR}/src/${CATKIN_PROFILE}/compile_commands.json"
}
## Contents of ~/.zshrc.local (with GRML zsh config)
# export DISPLAY=:0
# export _JAVA_AWT_WM_NONREPARENTING=1
# ulimit -Hn 524288
# export GPG_TTY=$(tty)
# export TERM=xterm-256color
#
# fk () { $@ 2>&1 1>/dev/null &!} # Silent Fork off the process
# export PATH="${PATH}:/home/suraj/.local/bin"
# alias clion='clion 2>&- >&- &!'
# alias pycharm='pycharm 2>&- >&- &!'
#
# autoload bashcompinit
# bashcompinit
#
# source /opt/ros/noetic/setup.zsh
# source /opt/ros/noetic/share/rosbash/roszsh
#
# export ROS_WS_DIR=$HOME/ws
# cd $ROS_WS_DIR
#
# source ./cc_setup.zsh
#
# echo "Initialized ROS Noetic..."
#
#
# source /usr/share/doc/fzf/examples/key-bindings.zsh
# source /usr/share/doc/fzf/examples/completion.zsh
# source /home/suraj/.local/share/zsh/fzf-zsh-completion.sh
#
# source /usr/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment