Skip to content

Instantly share code, notes, and snippets.

View rotu's full-sized avatar

Dan Rose rotu

  • Digi Labs
  • Minneapolis, MN
  • 09:42 (UTC -06:00)
View GitHub Profile
# generated with `vcs export ~/ros2_ws/src`
repositories:
bno055_driver:
type: git
url: https://github.com/RoverRobotics/bno055_driver.git
version: master
joint_state_publisher:
type: git
url: https://github.com/RoverRobotics-forks/joint_state_publisher.git
// Copyright 2019 Dan Rose
// Copyright 2014 Open Source Robotics Foundation, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
@rotu
rotu / .envrc
Last active August 23, 2022 08:41
environment setup for ROS 2 development
#!/usr/bin/env bash
# This file is meant to be run by direnv. Direnv will execute your script with bash, even if you're using another shell.
printf '─%.0s' $(seq $(tput cols))
################## CMake Generator (Cmake 3.15+)
# If available, use Ninja buildsystem generator, which is faster
# but Colcon may not show compiler output on a failed build
# if [ -x "$(command -v ninja)" ]; then
@rotu
rotu / ospl_shmem.xml
Created September 17, 2019 18:44
ROS2 Configuration for OpenSplice Commercial with shared memory
<OpenSplice>
<Domain>
<Name>ospl_shmem</Name>
<Id>${ROS_DOMAIN_ID}</Id>
<SingleProcess>false</SingleProcess>
<Service name="ddsi2">
<Command>ddsi2</Command>
</Service>
<Database>
<Size>32M</Size>
@rotu
rotu / colcon.yaml
Last active March 18, 2020 20:40
My colcon configuration
_definitions:
- &base-paths
# don't look at packages outside the src subdirectory
base-paths: [/opt/ros/master/src]
- &build-base
build-base: /opt/ros/master/build
- &test-base
test-base: /opt/ros/master/build
- &test-result-base
test-result-base: /opt/ros/master/test-results
@rotu
rotu / CMakeLists.txt
Last active November 3, 2024 16:18
CLion top level ROS2 Workspace CMakeLists
cmake_minimum_required(VERSION 3.14)
project("ROS2 Master")
# usually I put this in a separate file include("/opt/ros/_common/Colcon.cmake")
function(colcon_add_subdirectories)
cmake_parse_arguments(PARSE_ARGV 0 "ARG" "" "BUILD_BASE;BASE_PATHS" "")
message("search criteria: ${ARGV}")
execute_process(COMMAND colcon list
@rotu
rotu / prepare-commit-msg
Last active May 26, 2020 23:33
ros2 prepare-commit-msg
#!/usr/bin/env python3
# shared commit message trigger
# this file should exist in /opt/ros/_common/githooks and should be executable
# install everywhere (respected by GitKraken since 7):
# vcs custom --git --args config --local core.hooksPath "/opt/ros/_common/githooks/"
# uninstall everywhere:
# vcs custom --git --args config --local --unset core.hooksPath
#!/usr/bin/env python3
from fractions import Fraction
from functools import lru_cache
# to examine what moves are chosen
trace=False
@lru_cache(maxsize=None)
def f(x, y):
repositories:
ament/ament_cmake:
type: git
url: https://github.com/ament/ament_cmake.git
version: master
ament/ament_index:
type: git
url: https://github.com/ament/ament_index.git
version: master
ament/ament_lint:
repositories:
ament/ament_cmake:
type: git
url: https://github.com/ament/ament_cmake.git
version: master
ament/ament_index:
type: git
url: https://github.com/ament/ament_index.git
version: master
ament/ament_lint: