X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=README.md;h=d79f82f4dd53304cff41e5c5e82dfac108978f6d;hb=a3b17ae521205a9cfec91ab57fb0bea4a0610cda;hp=a1a7a3ea88d9fa54477d5326546cf5efe8ee821f;hpb=4662c9785daf52e11c932b0e9a6896be5433bf6f;p=ax-zsh.git diff --git a/README.md b/README.md index a1a7a3e..d79f82f 100644 --- a/README.md +++ b/README.md @@ -1,50 +1,72 @@ AX-ZSH: Alex' Modular ZSH Configuration ======================================= +AX-ZSH is a modular configuration system for the Z shell (ZSH). +It provides sane defaults and is extendable by plugins. -Configuration -------------- -AX-ZSH can be configured using settings in a `$HOME/.zshenv` file. +Installation +------------ + +To install AX-ZSH, either download a source archive or use Git to clone it. +Afterwards use the `install.sh` script inside of the source directory to set +up the `~/.axzsh` directory. + +When using Git it is best to directly clone the AX-ZSH repository into the +`~/.axzsh` directory and call `install.sh` from this location. + +Clone repository from _GitHub_ (https://github.com/alexbarton/ax-zsh): + + $ git clone https://github.com/alexbarton/ax-zsh.git ~/.axzsh + +Then run the installer script: + + $ ~/.axzsh/install.sh + +The `install.sh` script creates symbolic links for `~/.zprofile`, `~/.zshrc`, +`~/.zlogin`, and `~/.zlogout` (don't worry, already existing files are backed +up). + +Now close and restart all your running ZSH session to activate AX-ZSH. -The following configuration variables are supported: +To update AX-ZSH run `axzshctl upgrade`. -* `AXZSH_PLUGIN_D`: Optional directory for additional plugins. -* `axzsh_default_plugins`: Array of default plugins, that will be loaded in - addition to the core plugins. You can reset this array to disable(!) loading - of these default plugins. Currently these plugins are loaded by default: - * byebye - * completion - * correction - * history - * ls - * prompt - * ssh - * std_aliases - * std_env -* `axzsh_plugins`: Optional array of addiutional (non-core and non-default) - plugins to load. -Example for a `$HOME/.zshenv` file: +AX-ZSH & Local ZSH Configuration +-------------------------------- + +Plugins are loaded when they are linked into the `$AXZSH/active_plugins/` +directory; see the _Customization_ section below for how to activate them. + +Don't modify `~/.zprofile`, `~/.zshrc`, `~/.zlogin`, or `~/.zlogout`! These +are links to "AX-ZSH"-private files that can become overwritten when updating. + +You can use the following files for local ZSH configuration: + +1. AX-ZSH doesn't use `~/.zshenv` in any way. So you can use this file for your + own purposes (for example, to set up some environment variables that AX-ZSH + relies on). + +2. AX-ZSH reads the optional files `~/.zprofile.local`, `~/.zshrc.local`, + `~/.zlogin.local`, and `~/.zlogout.local` after its own core initialization + files when present. + + +Customization +------------- -``` -# Add additinal custom plugin search path -export AXZSH_PLUGIN_D="/opt/ax-zsh-plugins" +Use the `axzshctl` tool to enable, disable, and reset plugins. AXZSH +initializes an alias which points to the actual location in `~/.axzsh/bin/`. -# Disable all default plugins -typedef -U axzsh_default_plugins -axzsh_default_plugins=() +See `axzshctl --help` for details. -# Add additional plugins -typedef -U axzsh_plugins -axzsh_plugins=( - editor_select - homebrew -) -``` +You can link custom plugins stored in arbitrary directories using `axzshctl` +by specifying the complete path name. Or you can place additional plugins into +the `~/.axzsh/custom_plugins` folder which is searched by the `axzshctl` tool +by default. -Note: it should *not* be necessary to disable the default plugins! The above -is an example only! +In addition you can set the `AXZSH_PLUGIN_D` variable (and `ZSH_CUSTOM` like +"OhMyZsh") to specify additional plugin search directories. Environment Variables @@ -64,5 +86,6 @@ Validated and/or set up by core plugins: * `PS1` * `SHORT_HOST` * `TERM` +* `XDG_RUNTIME_DIR` * `XDG_CACHE_HOME` * `ZSH_CACHE_DIR`