srew

module
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2023 License: MIT

README

What is Srew?

Srew is a plugin manager similar to the krew and brew command line tools

Supports the deployment of the server, which is used to manage its own operation and maintenance tools within the enterprise

Srew helps you:

  • discover all plugins,
  • install them on your machine,
  • and keep the installed plugins up-to-date.

Srew works across all major platforms, like macOS, Linux and Windows.

Srew also helps kubectl plugin developers: You can package and distribute your plugins on multiple platforms easily and makes them discoverable through a centralized plugin repository with Srew.

Installing

  • macOS/Linux: bash/zsh, fish
  • Windows

macOS/Linux

Bash or ZSH shells

Make sure that git is installed.

  1. Run this command to download and install Srew:
(
  set -x; cd "$(mktemp -d)" &&
  OS="$(uname | tr '[:upper:]' '[:lower:]')" &&
  ARCH="$(uname -m | sed -e 's/x86_64/amd64/' -e 's/\(arm\)\(64\)\?.*/\1\2/' -e 's/aarch64$/arm64/')" &&
  SREW="srew-${OS}_${ARCH}" &&
  curl -fsSLO "https://github.com/bryant-rh/srew/releases/latest/download/${SREW}.tar.gz" &&
  tar zxvf "${SREW}.tar.gz" &&
  ./"${SREW}" install srew
)

  1. Add the $HOME/.srew/bin directory to your PATH environment variable. To do this, update your .bashrc or .zshrc file and append the following line:
export PATH="${KREW_ROOT:-$HOME/.krew}/bin:$PATH"

and restart your shell.

  1. Run srew to check the installation.
Fish shell
  1. Run this command in your terminal to download and install srew:
begin
  set -x; set temp_dir (mktemp -d); cd "$temp_dir" &&
  set OS (uname | tr '[:upper:]' '[:lower:]') &&
  set ARCH (uname -m | sed -e 's/x86_64/amd64/' -e 's/\(arm\)\(64\)\?.*/\1\2/' -e 's/aarch64$/arm64/') &&
  set SREW srew-$OS"_"$ARCH &&
  curl -fsSLO "https://github.com/bryant-rh/srew/releases/latest/download/${SREW}.tar.gz" &&
  tar zxvf $SREW.tar.gz &&
  ./$SREW install srew &&
  set -e SREW temp_dir &&
  cd -
end
  1. Add the $HOME/.srew/bin directory to your PATH environment variable. To do this, update your config.fish file and append the following line:
set -gx PATH $PATH $HOME/.krew/bin

and restart your shell.

  1. Run srew to check the installation.

Windows

  1. Download srew.exe from the Releases page to a directory.

  2. Launch a command prompt (cmd.exe) with administrator privileges (since the installation requires use of symbolic links) and navigate to that directory.

  3. Run the following command to install srew:

.\srew install srew
  1. Add the %USERPROFILE%.srew\bin directory to your PATH environment variable (how?)

  2. Launch a new command-line window.

  3. Run srew to check the installation.

Directories

Path Synopsis
cmd
server/docs
Package docs GENERATED BY SWAG; DO NOT EDIT This file was generated by swaggo/swag
Package docs GENERATED BY SWAG; DO NOT EDIT This file was generated by swaggo/swag
internal
pkg
installation/receiptsmigration
todo(corneliusweig) remove migration code with v0.4
todo(corneliusweig) remove migration code with v0.4
installation/semver
Package semver is a wrapper for handling of semantic version (https://semver.org) values.
Package semver is a wrapper for handling of semantic version (https://semver.org) values.
installation/validation
Package validation implements functions to validate Srew plugin types.
Package validation implements functions to validate Srew plugin types.
jwt

Jump to

Keyboard shortcuts

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