Skip to content

Instantly share code, notes, and snippets.

View stevenjj's full-sized avatar

Steven Jens Jorgensen stevenjj

View GitHub Profile
@myusuf3
myusuf3 / delete_git_submodule.md
Created November 3, 2014 17:36
How effectively delete a git submodule.

To remove a submodule you need to:

  • Delete the relevant section from the .gitmodules file.
  • Stage the .gitmodules changes git add .gitmodules
  • Delete the relevant section from .git/config.
  • Run git rm --cached path_to_submodule (no trailing slash).
  • Run rm -rf .git/modules/path_to_submodule (no trailing slash).
  • Commit git commit -m "Removed submodule "
  • Delete the now untracked submodule files rm -rf path_to_submodule
@mandiwise
mandiwise / Count lines in Git repo
Last active October 11, 2025 19:44
A command to calculate lines of code in all tracked files in a Git repo
// Reference: http://stackoverflow.com/questions/4822471/count-number-of-lines-in-a-git-repository
$ git ls-files | xargs wc -l
@mmurooka
mmurooka / robot_self_filter.launch
Last active August 17, 2017 17:21
robot_self_filter example
<launch>
<arg name="INPUT" default="/camera/depth/points" />
<arg name="SELF_FILTER_PARAM" default="robot_self_filter.yaml" />
<node pkg="robot_self_filter"
type="self_filter" clear_params="true"
name="self_filter" respawn="true" output="screen">
<remap from="cloud_in" to="$(arg INPUT)" />
<remap from="cloud_out" to="~output" />
<rosparam command="load" file="$(arg SELF_FILTER_PARAM)" />
@tdenewiler
tdenewiler / CMakeLists.txt
Last active July 17, 2024 02:33
ROS Synchronization Example
cmake_minimum_required(VERSION 2.8.3)
project(sync_example)
find_package(catkin REQUIRED COMPONENTS message_filters roscpp sensor_msgs)
catkin_package(
CATKIN_DEPENDS message_filters roscpp sensor_msgs
)
include_directories(${catkin_INCLUDE_DIRS})
@Cartexius
Cartexius / install_gtest_ubuntu.md
Last active November 7, 2024 00:57
Install gtest in Ubuntu
@goddoe
goddoe / solution.txt
Last active May 21, 2024 16:04
ssh: connect to host bitbucket.org port 22: Connection timed out
I have done below mentioned things and it started working.
vim ~/.ssh/config
Add these lines and save it.
Host github.com
Hostname ssh.github.com
Port 443
Host bitbucket.org
printf '[' > compile_commands.json
find ./build -type f -name 'compile_commands.json' -exec sh -c "cat {} | tail -n+2 | head -n-1 && printf ','" >> compile_commands.json \;
sed -i '$s/.$//' compile_commands.json
printf '\n]\n' >> compile_commands.json