Introduction
Eiipm is a fast and eligant plugin manager made in rust for Ewwii. It helps automate and manage your ewwii plugins with ease!
Installation
Download the latest release from:
https://github.com/Ewwii-sh/eiipm/releases/latest/
or build from source:
git clone https://github.com/Ewwii-sh/eiipm
cd eiipm
cargo build --release
# copy target/release/eiipm somewhere on your PATH
Basics
Ewwii supports plugins which allow extending the core functionality of the ewwii engine. The plugins go into the plugins/ directory inside an ewwii configuration. For example, let's say you have an ewwii configuration at ~/.config/ewwii/. To add and use a plugin, you have to create a plugins/ directory inside ~/.config/ewwii/ and place the plugin there.
~/.config/ewwii/plugins/
|- libxyz.so
|- libabc.so
Although this is straightforward, things can get messy quickly when you have a lot plugins. This is where eiipm comes in. Just run eiipm init in the ~/.config/ewwii/ directory and the basic plugin manager setup, including the plugins/ directory will be automatically created. After this, all the plugins can be maintained either by editing the plugins.toml file or using the eiipm commands shown in later sections.
Even if you don't use many plugins, eiipm can still be useful as it automates downloading and compiling the plugins.
Commands
Eiipm offers many commands which users can use to manage plugins.
# Init plugin manager
eiipm init
# Add plugins
eiipm add user/repo
eiipm add user/repo --ref v1.2.0 # pin to a tag
eiipm add user/repo --prebuilt # prefer prebuilt binary if available
eiipm add user/repo --build "cargo build --release" --artifact "target/release/libmy-plugin.so"
# Install plugins
eiipm install
# Update Plugins
eiipm update # update all plugins
eiipm update user/repo # update only this plugin
# Remove plugins
eiipm remove user/repo
# List plugins
eiipm list
# Cleaning
eiipm clean # remove untracked artifacts from 'plugins/'
eiipm cache-clean # wipe the global source cache (~/.cache/eiipm/)
Authoring Pluign
If you are writing a plugin for ewwii and want it to be compatible with eiipm, then add a plugin.toml file at the root of your repository:
[plugin]
build = "cargo build --release"
artifact = "target/release/libmyplugin.so"
# optional: provide a prebuilt binary for users who don't want to build
[plugin.prebuilt]
url = "https://github.com/user/repo/releases/download/{version}/libmyplugin-{arch}-{os}.so"
Even if plugin.toml is not present, eiipm will try to still attempt to compile the plugin and find the artifact based on assumptions. Although it can work, it is highly recommended to add a plugin.toml to avoid issues.
Examples
Installing yucky-ewwii:
# initialize
eiipm init
# add yucky-ewwii
eiipm add yucky-ewwii --prebuilt
# install
eiipm install
Explanation:
eiipm initwill initialize the necessary directories and files.eiipm add yucky-ewwii --prebuiltwill add yucky-ewwii to your configuration (by adding it insideplugins.toml) and tries to use the prebuilt artifact to avoid compilation which can be slow.eiipm installwill install all the plugins that you added, that being theyucky-ewwiiplugin.