Skip to content

Commit

Permalink
Generate py.typed in catkin built packages (#30)
Browse files Browse the repository at this point in the history
  • Loading branch information
bonprosoft authored Apr 30, 2021
1 parent 0597dac commit ffeb14b
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions cmake/genpyi-extras.cmake.em
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,11 @@ macro(_generate_module_pyi ARG_PKG ARG_GEN_OUTPUT_DIR ARG_GENERATED_FILES)
file(WRITE ${ARG_GEN_OUTPUT_DIR}/__init__.pyi "")
endif()

# place py.typed in order to mark this package as PEP561 compatible
if(NOT EXISTS ${ARG_GEN_OUTPUT_DIR}/py.typed)
file(WRITE ${ARG_GEN_OUTPUT_DIR}/py.typed "")
endif()

foreach(type "msg" "srv")
set(GEN_OUTPUT_DIR "${ARG_GEN_OUTPUT_DIR}/${type}")
set(GEN_OUTPUT_FILE ${GEN_OUTPUT_DIR}/__init__.pyi)
Expand Down

0 comments on commit ffeb14b

Please sign in to comment.