Skip to content
/ anyenv Public
forked from mislav/anyenv

rbenv-inspired version manager that can be configured to manage versions of ANYTHING

License

Notifications You must be signed in to change notification settings

aliou/anyenv

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

62 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

rbenv, but for anything

This is an implementation of rbenv that aims to be agnostic about what kind of software it is managing versions for. With names of configuration files and variables such as .ruby-version, RBENV_VERSION, etc. being configurable, this project could in theory manage multiple versions of anything and should be able to replace rbenv, pyenv, phantomenv, nodenv and other rbenv-inspired projects.

Build your own version manager

For example, let's say you want to build pyenv with this:

  1. Clone this project into your GOPATH;

  2. Run make with appropriate configuration:

    $ PROGRAM_NAME=pyenv PROGRAM_EXECUTABLE=python make
  3. Move the resulting pyenv binary somewhere into your PATH;

  4. Marvel at how you can now run pyenv version and other commands. This binary is hardcoded to respect:

  • .python-version local files,
  • PYENV_VERSION,
  • PYENV_ROOT,
  • PYENV_DIR.

A work in progress 🚧

Rbenv commands implemented so far:

  • rbenv
  • rbenv---version
  • rbenv-commands
  • rbenv-completions
  • rbenv-exec
  • rbenv-global
  • rbenv-help
  • rbenv-hooks ⚠️
  • rbenv-init
  • rbenv-local
  • rbenv-prefix
  • rbenv-rehash
  • rbenv-root
  • rbenv-sh-rehash
  • rbenv-sh-shell
  • rbenv-shims
  • rbenv-version
  • rbenv-version-file
  • rbenv-version-file-read
  • rbenv-version-file-write
  • rbenv-version-name
  • rbenv-version-origin
  • rbenv-versions
  • rbenv-whence
  • rbenv-which

⚠️ Big hurdle to overcome: support rbenv plugin (hook) system that is right now dependent on sourcing bash scripts.

Stay tuned.

About

rbenv-inspired version manager that can be configured to manage versions of ANYTHING

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 96.4%
  • Makefile 3.6%