shellhistory

package
v0.8.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 7, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Plugin

type Plugin struct {
	plugin.BasePlugin
}

Plugin persists shell history across container recreations by bind-mounting the history directory from the workspace state directory and setting HISTFILE. We mount the directory (not the file) so that shells like zsh can do atomic renames when saving history (e.g. writing .shell_history.new then renaming).

func New

func New() *Plugin

New creates a shell-history plugin.

func (*Plugin) Name

func (p *Plugin) Name() string

Name returns the plugin identifier.

func (*Plugin) PreContainerRun

PreContainerRun creates a history file in the workspace state dir (if it doesn't already exist) and returns a bind mount plus HISTFILE env var so both bash and zsh write to the persistent location.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL