A simple and fast package manager for the Fish shell written in Rust.
3.2K
A simple and fast package manager for the Fish shellā written in Rustā . š
This is an WIP Git-based "package manager" for Fish shell which is under active development.
Note: Some features are missing right now but it covers the most of functionalities needed to be usable. However feel free to contribute. See TODOā list.
username/package_name@(tag_name|branch_name).paket.tomlā ) to describe a package and copy optional non .fish files.~> paket --help
paket 0.1.0-beta.4
A simple package manager for the Fish shell š¦
USAGE:
paket [SUBCOMMAND]
FLAGS:
-h, --help Prints help information
-V, --version Prints version information
SUBCOMMANDS:
add Add a new package from a local or remote repository
help Prints this message or the help of the given subcommand(s)
rm Remove an existing package
up Update an existing package
~> paket add joseluisq/[email protected]
~> paket up joseluisq/[email protected]
~> paket rm joseluisq/gitnow
~> paket add ~/some-dir/my-pckage-dir
~> paket up ~/some-dir/my-pckage-dir
~> paket rm ~/some-dir/my-pckage-dir
Paket supports a paket.toml file in order to describe a package and copy optional non .fish files.
Here a sample file of GitNowā Fish package.
[package]
name = "gitnow"
version = "2.5.1"
authors = ["Jose Quintana <git.io/joseluisq>"]
license = "MIT OR Apache-2.0"
description = "Speed up your Git workflow. š "
repository = "https://github.com/joseluisq/gitnow"
keywords = [
"git",
"git-workflow",
"fish-shell",
"fish-packages",
"keybindings",
"bitbucket",
"github"
]
# Copy extra non Fish files (optional)
include = [
"conf.d/.gitnow"
]
# Paket events which can trigger Fish shell events (optional)
# Use the format `[package_name]_[event_name]` without the brackets and spaces (underscores instead).
# Also make sure that every value match with your package's Fish shell event (--on-event).
[events]
after-install = "gitnow_install"
after-update = "gitnow_update"
before-uninstall = "gitnow_uninstall"
[dependencies]
Paket has few events which can be used to trigger Fish shell eventsā defined in your package.
after-install: After a package is installed.after-update: After a package is updated.before-uninstall: Before a package is uninstalled.Appending a -e or --on-event flag to your function(s) tells Fish to run it when the specified named event is emitted.
Use the format [package_name]_[event_name] without the brackets and spaces (underscores instead).
Also make sure that every value match with your package's Fish shell event (--on-event).
Define a paket.toml file for your package:
[package]
name = "mypackage"
version = "0.0.0"
# ...
# Events (optional)
[events]
after-install = "mypackage_install"
before-uninstall = "mypackage_uninstall"
Optionally you can sign your corresponding functions with the --on-event (-e) value defined above.
# It will be immediately run after the package is installed
function __my_package_install -e mypackage_install
echo "Installing my package..."
end
# It will be immediately run before the package is uninstalled
function __my_package_uninstall -e mypackage_uninstall
echo "Uninstalling my package..."
end
Find out an example on GitNowā repository.
paket.toml support which describes a package.paket.toml file.~/paket.toml support.Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in current work by you, as defined in the Apache-2.0 license, shall be dual licensed as described below, without any additional terms or conditions.
Feel free to send some Pull requestā or issueā .
This work is primarily distributed under the terms of both the MIT licenseā and the Apache License (Version 2.0)ā .
Ā© 2020-present Jose Quintanaā
Content type
Image
Digest
sha256:1943a2a3aā¦
Size
16.4 MB
Last updated
over 1 year ago
docker pull joseluisq/paket