Skip to main content

Module iterm2

Module iterm2 

Source
Expand description

iTerm2 configuration instruction generator.

Most iTerm2 settings live in plist files, which are complex to modify programmatically, so this module generates manual setup instructions for them. The tab icon is the exception: iTerm2 loads Dynamic Profiles from plain JSON files with no restart, so the icon profile below is fully installable from code.

Structs§

ProfileIconInstallReport
Outcome of install_profile_icon.

Constants§

PROFILE_GUID
Stable identity of the shipped iTerm2 profile so reinstalls overwrite instead of duplicating it.
PROFILE_ICON_FILENAME
Filename of the installed profile artwork under the data root.

Functions§

default_install_paths
Resolve default install locations: home directory and canonical data root.
dynamic_profile_json
Render the dynamic-profile JSON pointing at an absolute icon path.
ensure_profile_icon
Ensure the iTerm2 profile icon is installed, returning the install report when this call wrote files.
ensure_profile_icon_at
Testable core of ensure_profile_icon with explicit paths and environment flags (no process-environment reads, no global roots).
generate_config
Generate iTerm2 setup instructions (manual configuration required)
install_profile_icon
Install the VT Code iTerm2 profile icon (macOS only, idempotent).
installed_icon_path
Absolute destination of the installed icon under a data root.
profile_icon_instructions
Guidance lines pointing at the automatic installer and the manual fallback.
run_profile_icon_install
Run the non-interactive profile-icon install with progress output.
run_profile_icon_reset
Reset the current session’s iTerm2 profile to its original name.