colcon / colcon-clean

A colcon extension to clean package workspaces
http://colcon.readthedocs.io
Apache License 2.0
46 stars 4 forks source link

Does not pick up on colcon configuration file. #42

Closed artivis closed 9 months ago

artivis commented 9 months ago

colcon-clean does not seem to be picking up on existing colcon configuration file. Given ~/.colcon/defaults.yaml as:

{
  "build": {"build-base": "/home/ubuntu/colcon-build"}
}

commands such as colcon clean workspace --base-select build still propose the default build rather than the configured default /home/ubuntu/colcon-build.

cottsay commented 9 months ago

The first-level key in a colcon defaults file isn't a semantic class of operations to associate the arguments with, it is a literal verb (as in the thing that immediately follows colcon in your commands).

To change the build-base for colcon-clean, you should have entries like this:

{
  "clean.packages": {"build-base": "/home/ubuntu/colcon-build"},
  "clean.workspace": {"build-base": "/home/ubuntu/colcon-build"}
}
artivis commented 9 months ago

Right, that makes sense. Thanks @cottsay :+1: .