Git Product home page Git Product logo

zed's Introduction

zed

ZSH Plugin Manager. Yes, yet another one.

Installation

declare -A ZED
ZED[CACHE_DIR]="${HOME}/.cache/zsh/.zed"
ZED[DATA_DIR]="${HOME}/.local/share/zsh/.zed"

if ! test -d "${ZED[DATA_DIR]}/self"; then
  git clone --depth 1 https://github.com/MunifTanjim/zed.git "${ZED[DATA_DIR]}/self"
fi

source "${ZED[DATA_DIR]}/self/zed.zsh"

Usage

You should load the plugins you want after running zed init and before running zed done.

Initialization:

zed init

Normal Plugin:

zed load github.com/momo-lab/auto-expand-alias

zed load github.com/trapd00r/LS_COLORS \
  pick:'lscolors.sh' \
  onpull:'dircolors -b LS_COLORS > lscolors.sh' \
  onload:'zstyle ":completion:*" list-colors "${(s.:.)LS_COLORS}"'

zed load github.com/zpm-zsh/colorize
zed load github.com/zpm-zsh/ls

zed load github.com/zsh-users/zsh-completions
zed load github.com/zsh-users/zsh-autosuggestions
zed load github.com/zsh-users/zsh-syntax-highlighting

Generated Script:

if (( ${+commands[zoxide]} )); then
  zed load github.com/MunifTanjim/null name:'zoxide' \
    onpull:'zoxide init zsh > zoxide.plugin.zsh'
fi

if (( ${+commands[starship]} )); then
  zed load github.com/MunifTanjim/null name:'starship' \
    onpull:'starship init zsh --print-full-init > starship.plugin.zsh'
fi

Local Script:

zed load "${HOME}/.helpers.sh"

Oh My Zsh Plugin:

zed load github.com/ohmyzsh/ohmyzsh dir:'plugins/macos'

Finalization:

zed done

Commands

The main function is named zed.

You don't like that name?!

In case you already have another function with the same name, for example: the zed command line editor, just set the ZED[name] variable to something else before sourcing the zed.zsh file.

ZED[name]=zedi

Then zed will become zedi, and you can do:

zedi load "${HOME}/darkside.sh"

zed init

Initialize

zed load

Load plugin

zed done

Finalize

zed list

List plugin-ids

zed pull [plugin-id]

Pull latest changes for plugins

zed pull-self

Pull latest changes for zed itself

Alternatives

(In alphabetical order of repository names)

FAQ

  • Q: There are so many zsh plugin managers! Why should I care about this one?

    A: You probably shouldn't.

  • Q: What does this this offer that the others don't?

    A: Well, possibly nothing.

  • Q: What does this do differently?

    A: It doesn't really matter.

  • Q: Why does this freaking exist?

    A: Because, it does.

License

Licensed under the MIT License. Check the LICENSE file for details.

zed's People

Contributors

muniftanjim avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.