{"id":13462487,"url":"https://github.com/zplug/zplug","last_synced_at":"2025-05-13T22:03:25.508Z","repository":{"id":40774971,"uuid":"46624643","full_name":"zplug/zplug","owner":"zplug","description":":hibiscus: A next-generation plugin manager for zsh","archived":false,"fork":false,"pushed_at":"2024-06-12T00:10:57.000Z","size":1137,"stargazers_count":5891,"open_issues_count":145,"forks_count":226,"subscribers_count":57,"default_branch":"master","last_synced_at":"2025-04-09T01:20:32.306Z","etag":null,"topics":["zplug","zsh"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/zplug.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":".github/CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":["b4b4r07"],"patreon":"b4b4r07","open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":null}},"created_at":"2015-11-21T17:00:26.000Z","updated_at":"2025-04-08T08:07:53.000Z","dependencies_parsed_at":"2024-01-12T18:28:44.890Z","dependency_job_id":"7e0da619-2d98-47d5-ba91-179312078bc5","html_url":"https://github.com/zplug/zplug","commit_stats":{"total_commits":715,"total_committers":61,"mean_commits":"11.721311475409836","dds":"0.37342657342657337","last_synced_commit":"18cfcd4f761eceaf2ca63a291d11782d0f8b590e"},"previous_names":[],"tags_count":15,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zplug%2Fzplug","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zplug%2Fzplug/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zplug%2Fzplug/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zplug%2Fzplug/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zplug","download_url":"https://codeload.github.com/zplug/zplug/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251336400,"owners_count":21573189,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["zplug","zsh"],"created_at":"2024-07-31T12:00:49.368Z","updated_at":"2025-04-28T15:20:40.277Z","avatar_url":"https://github.com/zplug.png","language":"Shell","readme":":us: [:jp:](./doc/guide/ja/README.md)\n\n\u003e Zsh Plugin Manager\n\n[![Travis][travis-badge]][travis-link]\n[![Latest][latest-badge]][latest-link]\n[![Slack][slack-badge]][slack-link]\n\n\u003cdiv align=\"center\"\u003e\n  \u003ca href=\"http://zplug.sh\"\u003e\n    \u003cimg width=650px src=\"https://raw.githubusercontent.com/b4b4r07/screenshots/master/zplug/logo.png\"\u003e\n  \u003c/a\u003e\n\u003c/div\u003e\n\u003cbr\u003e\n\n## Pros.\n\n- Can manage everything\n  - Zsh plugins/UNIX commands on [GitHub](https://github.com) and [Bitbucket](https://bitbucket.org)\n  - Gist files ([gist.github.com](https://gist.github.com))\n  - Externally managed plugins e.g., [oh-my-zsh](https://github.com/robbyrussell/oh-my-zsh) and [prezto](https://github.com/sorin-ionescu/prezto) plugins/themes\n  - Binary artifacts on [GitHub Releases](https://help.github.com/articles/about-releases/)\n  - Local plugins\n  - etc. (you can add your [own sources](https://github.com/zplug/zplug/blob/master/doc/guide/External-Sources.md)!)\n- Super-fast parallel installation/update\n- Support for lazy-loading\n- Branch/tag/commit support\n- Post-update, post-load hooks\n- Dependencies between packages\n- Unlike [antigen](https://github.com/zsh-users/antigen), no ZSH plugin file (`*.plugin.zsh`) required\n- Interactive interface ([fzf](https://github.com/junegunn/fzf), [peco](https://github.com/peco/peco), [zaw](https://github.com/zsh-users/zaw), and so on)\n- Cache mechanism for reducing [the startup time](#vs)\n\n***DEMO:***\n\n\u003c!-- [![](https://raw.githubusercontent.com/b4b4r07/screenshots/master/zplug/install.gif)][repo] --\u003e\n[![](https://raw.githubusercontent.com/b4b4r07/screenshots/master/zplug/demo.gif)][repo]\n\n## Installation\n\nlatest | stable\n---|---\n[![Latest][latest-badge]][latest-link] | [![Stable][stable-badge]][stable-link]\n\n### The best way\n\n```console\ncurl -sL --proto-redir -all,https https://raw.githubusercontent.com/zplug/installer/master/installer.zsh | zsh\n```\n\nCurious about the installation script? Check it out at [zplug/installer](https://github.com/zplug/installer/blob/master/installer.zsh).\n\n### Using [Homebrew](https://github.com/Homebrew/brew) (OS X)\n\n```console\nbrew install zplug\n```\n\n### Manually\n\nCloning from GitHub, and source `init.zsh`:\n\n```console\n$ export ZPLUG_HOME=/path/to/.zplug\n$ git clone https://github.com/zplug/zplug $ZPLUG_HOME\n```\n\n## Requirements\n\n- `zsh`: version 4.3.9 or higher\n- `git`: version 1.7 or higher\n- `awk`: An AWK variant that's **not** `mawk`\n\n## Usage\n\nAdd a zplug section to your `.zshrc`:\n\n1. List the packages with `zplug` commands\n2. `zplug load` to source the plugins and add commands to your `$PATH`\n\n### Example\n\n[![](https://raw.githubusercontent.com/b4b4r07/screenshots/master/zplug/example.png)][repo]\n\n```zsh\nsource ~/.zplug/init.zsh\n\n# Make sure to use double quotes\nzplug \"zsh-users/zsh-history-substring-search\"\n\n# Use the package as a command\n# And accept glob patterns (e.g., brace, wildcard, ...)\nzplug \"Jxck/dotfiles\", as:command, use:\"bin/{histuniq,color}\"\n\n# Can manage everything e.g., other person's zshrc\nzplug \"tcnksm/docker-alias\", use:zshrc\n\n# Disable updates using the \"frozen\" tag\nzplug \"k4rthik/git-cal\", as:command, frozen:1\n\n# Grab binaries from GitHub Releases\n# and rename with the \"rename-to:\" tag\nzplug \"junegunn/fzf\", \\\n    from:gh-r, \\\n    as:command, \\\n    use:\"*darwin*amd64*\"\n\n# Supports oh-my-zsh plugins and the like\nzplug \"plugins/git\",   from:oh-my-zsh\n\n# Also prezto\nzplug \"modules/prompt\", from:prezto\n\n# Load if \"if\" tag returns true\nzplug \"lib/clipboard\", from:oh-my-zsh, if:\"[[ $OSTYPE == *darwin* ]]\"\n\n# Run a command after a plugin is installed/updated\n# Provided, it requires to set the variable like the following:\n# ZPLUG_SUDO_PASSWORD=\"********\"\nzplug \"jhawthorn/fzy\", \\\n    as:command, \\\n    rename-to:fzy, \\\n    hook-build:\"make \u0026\u0026 sudo make install\"\n\n# Supports checking out a specific branch/tag/commit\nzplug \"b4b4r07/enhancd\", at:v1\nzplug \"mollifier/anyframe\", at:4c23cb60\n\n# Can manage gist file just like other packages\nzplug \"b4b4r07/79ee61f7c140c63d2786\", \\\n    from:gist, \\\n    as:command, \\\n    use:get_last_pane_path.sh\n\n# Support bitbucket\nzplug \"b4b4r07/hello_bitbucket\", \\\n    from:bitbucket, \\\n    as:command, \\\n    use:\"*.sh\"\n\n# Rename a command with the string captured with `use` tag\nzplug \"b4b4r07/httpstat\", \\\n    as:command, \\\n    use:'(*).sh', \\\n    rename-to:'$1'\n\n# Group dependencies\n# Load \"emoji-cli\" if \"jq\" is installed in this example\nzplug \"stedolan/jq\", \\\n    from:gh-r, \\\n    as:command, \\\n    rename-to:jq\nzplug \"b4b4r07/emoji-cli\", \\\n    on:\"stedolan/jq\"\n# Note: To specify the order in which packages should be loaded, use the defer\n#       tag described in the next section\n\n# Set the priority when loading\n# e.g., zsh-syntax-highlighting must be loaded\n# after executing compinit command and sourcing other plugins\n# (If the defer tag is given 2 or above, run after compinit command)\nzplug \"zsh-users/zsh-syntax-highlighting\", defer:2\n\n# Can manage local plugins\nzplug \"~/.zsh\", from:local\n\n# Load theme file\nzplug 'dracula/zsh', as:theme\n\n# Install plugins if there are plugins that have not been installed\nif ! zplug check --verbose; then\n    printf \"Install? [y/N]: \"\n    if read -q; then\n        echo; zplug install\n    fi\nfi\n\n# Then, source plugins and add commands to $PATH\nzplug load --verbose\n```\n\nFinally, use `zplug install` to install your plugins and reload `.zshrc`.\n\n### 1. Options for `zplug`\n\n| Option          | Description |\n|-----------------|-------------|\n| `--help`        | Display the help message |\n| `--rollback`    | Rollback a failed package |\n| `--self-manage` | Self management of zplug |\n| `--version`     | Display the version of zplug |\n| `--log`         | Show the report of zplug errors |\n\n### 2. Commands for `zplug`\n\n|  Command  | Description | Options |\n|-----------|-------------|---------|\n| `install` | Install packages in parallel | (None) |\n| `load`    | Source installed plugins and add installed commands to `$PATH` | `--verbose` |\n| `list`    | List installed packages (more specifically, view the associative array `$zplugs`) | `--select`,`--installed`,`--loaded` |\n| `update`  | Update installed packages in parallel | `--select`,`--force` |\n| `check`   | Return true if all packages are installed, false otherwise | `--verbose` |\n| `status`  | Check if the remote repositories are up to date | `--select` |\n| `clean`   | Remove repositories which are no longer managed | `--force`,`--select` |\n| `clear`   | Remove the cache file | (None) |\n| `info`    | Show the information such as the source URL and tag values for the given package | (None) |\n\n#### Take a closer look\n\n```zsh\n# zplug check returns true if all packages are installed\n# Therefore, when it returns false, run zplug install\nif ! zplug check; then\n    zplug install\nfi\n\n# source plugins and add commands to the PATH\nzplug load\n\n# zplug check returns true if the given repository exists\nif zplug check b4b4r07/enhancd; then\n    # setting if enhancd is available\n    export ENHANCD_FILTER=fzf-tmux\nfi\n```\n\n#### Let zplug manage zplug\n\nTo manage zplug itself like other packages, write the following in your `.zshrc`.\n\n```zsh\nzplug 'zplug/zplug', hook-build:'zplug --self-manage'\n```\n\nAll that's left is to run `zplug update`.\n\n\u003c!-- [![](https://raw.githubusercontent.com/b4b4r07/screenshots/master/zplug/update.gif)][repo] --\u003e\n\n### 3. Tags for `zplug`\n\n`truthy` is any of `true`, `yes`, `on`, `1` and `falsy` is any of `false`, `no`, `off`, `0`.\n\n| Tag | Description | Value (default) | Example |\n|-----|-------------|-----------------|---------|\n| `as`          | Specify whether to register the package as plugins or commands | `plugin`,`command`,`theme` (`plugin`) | `as:command` |\n| `use`         | Specify the pattern of the files to source (for `plugin`) or the relative path to add to the `$PATH` (for `command`) / With `from:gh-r`, zplug tries to guess which file to use from your OS and architecture. You can manually specify `use:\"*darwin*{amd,386}*\"` if that doesn't get the right file. | *glob* (`use:\"*.zsh\"`) | `use:bin`,`use:\"*.sh\"`, `use:*darwin*` |\n| `ignore`      | Similar to `use` tag, but specify pattern of files you want to ignore (see also [#56](https://github.com/zplug/zplug/issues/56)) | *glob* (-) | `ignore:\"some_*.zsh\"` |\n| `from`        | Specify where to get the package from | `github`,`bitbucket`,\u003cbr\u003e`gh-r`,`gist`,\u003cbr\u003e`oh-my-zsh`,`prezto`,`local` (`github`) | `from:gh-r` |\n| `at`          | Specify branch/tag/commit to install | *revision* (`master`) | `at:v1.5.6` |\n| `rename-to`   | Specify the filename you want to rename the command to (use this only with `as:command`) | *filename* (-) | `rename-to:fzf` |\n| `dir`         | Installed directory of the package | **READ ONLY** | `dir:/path/to/user/repo` |\n| `if`          | Specify the conditions under which to install and use the package | *boolean* (-) | `if:\"[ -d ~/.zsh ]\"` |\n| `hook-build`  | Commands to run after installation/update | *commands* (-) | `hook-build:\"make install\"` |\n| `hook-load`   | Commands to run after loading | *commands* (-) | `hook-load:\"echo 'Loaded!'\"` |\n| `frozen`      | Do not update unless explicitly specified | truthy,falsy (false) | `frozen:1` |\n| `on`          | Load this package only if a different package is installed | *package* | `on:user/repo` |\n| `defer`        | Defers the loading of a package. If the value is 2 or above, zplug will source the plugin after `compinit` (see also [#26](https://github.com/zplug/zplug/issues/26)) | 0..3 (0) | `defer:2` |\n| `lazy`        | Whether it is an autoload function or not | truthy,falsy (false) | `lazy:true` |\n| `depth`       | The number of commits to include in the cloned repository. 0 means the whole history. | Any non-negative integer | `depth:10` |\n\n#### Changing the defaults\n\nYou can use `zstyle` to change the default value. The format is:\n\n```zsh\nzstyle \":zplug:tag\" tag_name new_default_value\n```\n\nFor example, if you have a lot of commands and not so many plugins, (i.e. if\nyou find yourself specifying `as:command` often), you can do:\n\n```zsh\nzstyle \":zplug:tag\" as command\n```\n\nThe default value for all tags can be changed in this way.\n\n#### Available on CLI\n\nYou can register packages to zplug from the command-line. If you use zplug from the command-line, it is possible to add stuff more easily with the help of powerful zsh completions.\n\n\u003c!-- [![](https://raw.githubusercontent.com/b4b4r07/screenshots/master/zplug/cli.gif)][repo] --\u003e\n\nIn this case, zplug spit out its settings to `$ZPLUG_LOADFILE` instead of `.zshrc`. If you launch new zsh process, `zplug load` command automatically search this file and run `source` command.\n\nSee [`ZPLUG_LOADFILE`](#zplug_loadfile) for other usage of `ZPLUG_LOADFILE`.\n\n### 4. Environment variables for `zplug`\n\n#### `ZPLUG_HOME`\n\nDefaults to `~/.zplug`. `zplug` will store/load packages in this directory. The directory structure is shown below.\n\n```\n$ZPLUG_HOME\n|-- bin\n|   `-- some_command -\u003e ../repos/username_A/reponame1/some_command\n`-- repos\n    |-- username_A\n    |   |-- reponame1\n    |   |   |-- README.md\n    |   |   `-- some_command\n    |   `-- reponame2\n    |       |-- README.md\n    |       `-- some_plugin.zsh\n    `-- username_B\n        `-- reponame1\n```\n\nIf you specify `as:command`, zplug will see the package as a command and create a symbolic link of the same name (if you want to rename it, use the `rename-to:` tag) in `$ZPLUG_BIN`. Because zplug adds `$ZPLUG_BIN` to the `$PATH`, you can run that command from anywhere.\n\n#### `ZPLUG_THREADS`\n\nThe number of threads zplug uses when installing/updating. The default value is 16.\n\n#### `ZPLUG_PROTOCOL`\n\nDefaults to HTTPS. Valid options are `HTTPS` and `SSH`. Unless you have a specific reason, you should use the HTTPS protocol.\n\nFor more information, see also [**Which remote URL should I use?** - GitHub Help](https://help.github.com/articles/which-remote-url-should-i-use/)\n\n#### `ZPLUG_FILTER`\n\nDefaults to `fzf-tmux:fzf:peco:percol:zaw`. When `--select` option is specified, the first element in the colon-separated list that exists in the `$PATH` will be used by zplug as the interactive filter. You can also use spaces and double quotes in `ZPLUG_FILTER` like: `fzf-tmux -d \"10%\":/path/to/peco:my peco`.\n\n#### `ZPLUG_LOADFILE`\n\nDefaults to `$ZPLUG_HOME/packages.zsh`. This file is used to add plugins from zplug on the command-line. It is also a useful place to isolate your packages list from `.zshrc`. Rather than cluttering your `.zshrc` with many lines enumerating packages, you can put them in a separate file and set `ZPLUG_LOADFILE` to its path.\n\n#### `ZPLUG_USE_CACHE`\n\nDefaults to `true`. If this variable is true, zplug will use cache files to speed up the load process. The cache files are saved under the `$ZPLUG_CACHE_DIR` directory. If you want to clear the cache, please run `zplug clear` or do the following:\n\n```console\n$ ZPLUG_USE_CACHE=false zplug load\n```\n\n#### `ZPLUG_CACHE_DIR`\n\nDefaults to `$ZPLUG_HOME/.cache`. You can change where the cache file is saved, for example, `~/.cache/zplug`.\n\n#### `ZPLUG_REPOS`\n\nDefaults to `$ZPLUG_HOME/repos`. You can change where the repositories are cloned in case you want to manage them separately.\n\n#### `ZPLUG_SUDO_PASSWORD`\n\nDefaults to `''`. You can set sudo password for zplug's `hook-build` tag. However, this variable should not be managed in dotfiles and so on.\n\n#### `ZPLUG_LOG_LOAD_SUCCESS`\n\nDefaults to `false`. If true, zplug spit the log about its success operation out to file (you can see it with `zplug --log`).\n\n#### `ZPLUG_LOG_LOAD_FAILURE`\n\nDefaults to `false`. If true, zplug spit the log about its failure operation out to file (you can see it with `zplug --log`).\n\n```zsh\n# your .zshrc\nsource ~/.zshrc_secret\nzplug \"some/command\", hook-build:\"make \u0026\u0026 sudo make install\"\n```\n\n#### `ZPLUG_BIN`\n\nDefaults to `$ZPLUG_HOME/bin`. You can change the save destination of the command's symbolic link, e.g. `~/bin`.\n\n### External commands\n\nzplug, like `git(1)`, supports external commands.\nThese are executable scripts that reside somewhere in the PATH, named `zplug-cmdname`,\nwhich can be invoked with `zplug cmdname`.\nThis allows you to create your own commands without modifying zplug's internals.\nInstructions for creating your own commands can be found in the [docs](https://github.com/zplug/zplug/blob/master/doc/zplug/External-Commands.md).\nCheck out the sample [`zplug-env`](https://github.com/zplug/zplug/blob/master/bin/zplug-env) external command for an example.\n\n## V.S.\n\nzplug is the fastest among the famous zsh plugin managers. Numbers? Here they are:\n\n[![](https://raw.githubusercontent.com/b4b4r07/screenshots/master/zplug/time.png)][repo]\n\n## Note\n\n- Not antigen :syringe: but **zplug** :hibiscus: will be here for you from now on.\n- :hibiscus: It was heavily inspired by [vim-plug](https://github.com/junegunn/vim-plug), [neobundle.vim](https://github.com/Shougo/neobundle.vim) and the like.\n\n## Other resources\n\n[awesome-zsh-plugins](https://github.com/unixorn/awesome-zsh-plugins) is a list of ZSH plugins, themes and completions that you can use with zplug.\n\nFor migration from antigen, zgen, or zplug v1, check out the [wiki\npage](https://github.com/zplug/zplug/wiki/Migration).\n\n## License\n\n[MIT][license] (c) [@b4b4r07](https://github.com/b4b4r07)\n\n[repo]: https://github.com/zplug/zplug\n[license]: http://b4b4r07.mit-license.org\n[travis-link]: https://travis-ci.org/zplug/zplug\n[travis-badge]: https://img.shields.io/travis/zplug/zplug.svg?style=flat-square\n[latest-badge]: https://img.shields.io/badge/latest-v2.4.2-ca7f85.svg?style=flat-square\n[latest-link]: https://github.com/zplug/zplug/releases/latest\n[stable-badge]: https://img.shields.io/badge/stable-v2.3.2-e9a326.svg?style=flat-square\n[stable-link]: https://github.com/zplug/zplug/releases/tag/2.3.2\n[slack-link]: https://zplug.herokuapp.com\n[slack-badge]: https://img.shields.io/badge/slack-join-ca7f85.svg?style=flat-square\n","funding_links":["https://github.com/sponsors/b4b4r07","https://patreon.com/b4b4r07"],"categories":["Uncategorized","Shell","Frameworks","Tool","Installation","HarmonyOS","Terminal","Shells","Tools"],"sub_categories":["Uncategorized","[zplug](https://github.com/zplug/zplug)","Miscs","Windows Manager","\u003cb\u003e\u003ccode\u003e\u0026nbsp;\u0026nbsp;5971⭐\u003c/code\u003e\u003c/b\u003e \u003cb\u003e\u003ccode\u003e\u0026nbsp;\u0026nbsp;\u0026nbsp;229🍴\u003c/code\u003e\u003c/b\u003e [zplug](https://github.com/zplug/zplug))","Zsh","ZSH","Command line","PCAP"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzplug%2Fzplug","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzplug%2Fzplug","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzplug%2Fzplug/lists"}