PCP.ENV(5)

πŸ“¦
version 7.2.2 Β· 2 versions
, in arch rolling, centos-stream 10, centos-stream 9, debian trixie, fedora 43, fedora 44, ubuntu questing, ubuntu resolute, ubuntu stonking

πŸ’– pcp.env β€” the PCP vibe-setting script πŸ’–

okay so this is PCP.ENV(5), from the File Formats Manual section, and it's literally the little script that gets Performance Co-Pilot's run-time environment variables all set up and cozy. bestie, it's giving backstage pass energy ✨


πŸŽ€ NAME πŸŽ€

pcp.env β€” script to set Performance Co-Pilot run-time environment variables


🌸 SYNOPSIS 🌸

/etc/pcp.env

✨ DESCRIPTION ✨

So the pcp.env script gets sourced by assorted Performance Co-Pilot (PCP) scripts and utilities to define the PCP operating environment variables. That's its whole job, and it eats every time. πŸ’…

The conjugate for executable programs that use the PCP libraries is the pmGetConfig(3) function β€” iykyk, that's the C-side twin. 🫢

Typical usage of pcp.env in a script is as follows:

#! /bin/sh

# source the PCP environment variables
. /etc/pcp.env
rest of script ...

The full syntax and semantics of the pcp.conf file and the pmGetConfig function are described in their respective reference pages β€” go read those if you want the deep lore πŸ“š

If the file $HOME/.pcp/pcp.conf exists then this will be processed after the system-wide pcp.conf file. This provides a mechanism to selectively modify or augment the environment settings for PCP scripts, which maybe useful if the scripts are run with sudo(1) β€” because sudo(1) cleans the environment of important settings that are required to ensure the correct execution of the PCP scripts, e.g. $PATH or $PERL5LIB. not sudo being the messy one that wipes your whole setup 😭 no cap, your home config is the comeback.


🌈 ENVIRONMENT 🌈

  • PCP_CONF β€” specifies an alternative path to the pcp.conf file. main character override behavior, fr fr πŸ‘‘

πŸ’œ SEE ALSO πŸ’œ

PCPIntro(1), sudo(1), PCPIntro(3), PMAPI(3), pmGetConfig(3) and pcp.conf(5).


quick vibe check bestie: this page comes from Performance Co-Pilot, the PCP collection, page PCP.ENV(5) β€” that's the source and version tag, slay. 🌟

mwah, that's the whole page, you ate it, periodt πŸ’–πŸ¦‹πŸŒΈ

πŸ“¦ where this page comes from