get_path_profile()

Returns the full path of a file within the profile directory. The profile directory is the folder where the machine’s configuration, settings, scripts, and other files are stored.

An optional relative path (or filename) can be provided, which is appended to the base profile directory path.

Syntax

planetcnc.get_profile_path()
planetcnc.get_profile_path(str)

Parameters

Parameter Type Description
str string A string representing a relative subpath or filename.

Return Value

Examples

#! /usr/bin/env python 
 
import planetcnc
 
# Get the full path for a file "Settings.settings" within the profile directory.
set_path = planetcnc.get_path_profile("Settings.settings")
print("Settings path:", set_path )
 
# Or, get the profile directory itself:
profile_dir = planetcnc.get_path_profile()
print("Profile directory:", profile_dir)

See also

get_path
get_path_exe
get_path_profile
get_path_temp
get_path_working