Core Library0.xAPI reference

Choose documentation 2

latest

Current version

latest
English

Early release libtmux is released, and its APIs may still change between releases. This site's structure and URLs may change too.

MoreLess about this notice

cmdlet libtmux-powershell

LibTmux.Remove-TmuxEnvironment

Unset an environment entry or keep an explicit removal marker.

Source and package
Qualified name
LibTmux\Remove-TmuxEnvironment
Declared in
LibTmux
Package
LibTmux
Source
src/LibTmux.PowerShell/RemoveTmuxEnvironmentCommand.cs
Server (default): Remove-TmuxEnvironment [-Server] <LibTmux.Server> -Name <System.String> [-MarkRemoved] [-WhatIf] [-Confirm] [<CommonParameters>]Session: Remove-TmuxEnvironment [-Session] <LibTmux.Session> -Name <System.String> [-MarkRemoved] [-WhatIf] [-Confirm] [<CommonParameters>]

Description

By default, forget the entry using tmux set-environment -u. Unsetting a session entry allows a global value to apply to future panes again. MarkRemoved instead uses -r: tmux retains a removal marker to suppress the variable in future pane processes. Neither operation is equivalent to setting an empty string. WhatIf performs no tmux I/O.

Notes

A Server selects the global environment; a Session selects its local environment. Reads do not merge those tables. Changes affect newly created processes and do not rewrite the environment of an existing pane process. Empty owner pipelines do no I/O. Errors retain the original exception and owner; Continue permits later owners and Stop terminates. Cancellation cannot undo a dispatched mutation.

Command details

Command type
cmdlet
Default parameter set
Server
Confirmation
Supports -WhatIf and -Confirm; confirm impact: Medium.
Positional binding
Enabled.
Pipeline inputs
LibTmux.Server: A native server owner.; LibTmux.Session: A native session owner.
Outputs
System.Void
Parameters
Common parameters 12

PowerShell supplies these parameters. See common parameter behavior for their effects.

Returns

None: No success output.

Examples

Example 1 Prevent future processes in a native $session from inheriting APP_MODE. View source

Terminal window
$session | LibTmux\Remove-TmuxEnvironment -Name 'APP_MODE' -MarkRemoved

Recorded calls

source calls
No call edges in the PowerShell model.

The PowerShell reference records declarations, not calls, so this page shows no callers or callees. That is a limit of the extracted data, not a statement that nothing calls LibTmux\Remove-TmuxEnvironment.

Esc
Search in

Type to search.

Reference previewOpen reference