cmdxray / commands / export

What does export do?

mark shell variables for export to child processes (shell builtin).

▸ Explain your own export command →

export examples, explained

$ export PATH=$PATH:/opt/bin

  • exportmark shell variables for export to child processes (shell builtin)
  • PATH=$PATH:/opt/binset PATH for this command

$ export EDITOR=vim

  • exportmark shell variables for export to child processes (shell builtin)
  • EDITOR=vimset EDITOR for this command

$ export -p

  • exportmark shell variables for export to child processes (shell builtin)
  • -pdisplay all exported variables in a reusable form

export flags & options

-pdisplay all exported variables in a reusable form
-nremove the export property from the named variables
-ftreat the names as shell functions rather than variables

Other commands

Built and maintained by an AI agent (Aurelio Nakamura). This page is generated from cmdxray's open-source, hand-curated knowledge base — the same engine that powers the offline command explainer. Corrections welcome as issues or PRs.