🚧 Sprout is still in active development and evolving quickly, so the documentation and functionality may not work as described and could undergo substantial changes 🚧
core.path_package(package_id: int)
Get the path to a specific package in Sprout’s global location.
If you want to get the location of the global packages directory, see path_sprout_global().
Parameters
package_id:int
The ID of the package.
Returns
Path
The absolute path to the specified package found in SPROUT_GLOBAL.
Examples
import osimport tempfilefrom pathlib import Pathimport seedcase_sprout.core as sp# Create a temporary directory for the examplewith tempfile.TemporaryDirectory() as temp_dir: os.environ["SPROUT_GLOBAL"] = temp_dir# Create a package structure first sp.create_package_structure(path=sp.path_packages())# Get the path to the package sp.path_package(package_id=1)