From b6efdc1ea49a3ef4b8b904aacde98ada7a0811e9 Mon Sep 17 00:00:00 2001 From: FireWave Date: Thu, 28 Mar 2013 16:58:10 -0400 Subject: [PATCH] Add DNF module Signed-off-by: Sorin Ionescu --- modules/README.md | 5 +++++ modules/dnf/README.md | 29 +++++++++++++++++++++++++++++ modules/dnf/init.zsh | 28 ++++++++++++++++++++++++++++ 3 files changed, 62 insertions(+) create mode 100644 modules/dnf/README.md create mode 100644 modules/dnf/init.zsh diff --git a/modules/README.md b/modules/README.md index 4d247b2..d0fcdd9 100644 --- a/modules/README.md +++ b/modules/README.md @@ -26,6 +26,11 @@ Directory Sets directory options and defines directory aliases. +DNF +--- + +Defines dnf aliases. + Dpkg ---- diff --git a/modules/dnf/README.md b/modules/dnf/README.md new file mode 100644 index 0000000..0643954 --- /dev/null +++ b/modules/dnf/README.md @@ -0,0 +1,29 @@ +DNF +=== + +Defines [dnf][1] aliases. + +Aliases +------- + + - `dnfc` removes package(s) and leaves. + - `dnfi` installs package(s). + - `dnfh` displays history. + - `dnfl` lists packages. + - `dnfL` lists installed packages. + - `dnfq` displays package information. + - `dnfr` removes package(s). + - `dnfs` searches for a package. + - `dnfu` updates packages. + - `dnfU` upgrates packages. + +Authors +------- + +*The authors of this module should be contacted via the [issue tracker][2].* + + - [Sorin Ionescu](https://github.com/sorin-ionescu) + +[1]: https://fedoraproject.org/wiki/Features/DNF +[2]: https://github.com/sorin-ionescu/prezto/issues + diff --git a/modules/dnf/init.zsh b/modules/dnf/init.zsh new file mode 100644 index 0000000..7a40142 --- /dev/null +++ b/modules/dnf/init.zsh @@ -0,0 +1,28 @@ +# +# Defines dnf aliases. +# +# Authors: +# FireWave +# Sorin Ionescu +# + +# Return if requirements are not found. +if (( ! $+commands[dnf] )); then + return 1 +fi + +# +# Aliases +# + +alias dnfc='sudo dnf clean all' # Cleans the cache. +alias dnfh='dnf history' # Displays history. +alias dnfi='sudo dnf install' # Installs package(s). +alias dnfl='dnf list' # Lists packages. +alias dnfL='dnf list installed' # Lists installed packages. +alias dnfq='dnf info' # Displays package information. +alias dnfr='sudo dnf remove' # Removes package(s). +alias dnfs='dnf search' # Searches for a package. +alias dnfu='sudo dnf update' # Updates packages. +alias dnfU='sudo dnf upgrade' # Upgrades packages. +