Python: sharing common code among a family of scripts
问题 I'm writing a family of Python scripts within a project; each script is within a subdirectory of the project, like so: projectroot | |- subproject1 | | | |- script1.main.py | `- script1.merger.py | |- subproject2 | | | |- script2.main.py | |- script2.matcher.py | `- script2.merger.py | `- subproject3 | |- script3.main.py |- script3.converter.py |- script3.matcher.py `- script3.merger.py Now several of the scripts share some code. The shared code is best considered part of the project itself,