()
| 21 | } |
| 22 | |
| 23 | func (b bash) Register() error { |
| 24 | if err := b.installBinary(); err != nil { |
| 25 | return fmt.Errorf("failed to install bash binary -> %w", err) |
| 26 | } |
| 27 | if err := b.installCompletion(); err != nil { |
| 28 | return fmt.Errorf("failed to install bash completion -> %w", err) |
| 29 | } |
| 30 | if err := b.registerRunCommand(); err != nil { |
| 31 | return fmt.Errorf("failed to add run command to bashrc -> %w", err) |
| 32 | } |
| 33 | |
| 34 | return nil |
| 35 | } |
| 36 | |
| 37 | func (b bash) Unregister() error { |
| 38 | if err := b.uninstallBinary(); err != nil { |
nothing calls this directly
no test coverage detected