mirror of
https://github.com/gentoo-mirror/gentoo-zh.git
synced 2025-04-10 20:08:43 -04:00
34 lines
896 B
Bash
34 lines
896 B
Bash
# Copyright 1999-2021 Gentoo Authors
|
|
# Distributed under the terms of the GNU General Public License v2
|
|
|
|
EAPI=7
|
|
|
|
DESCRIPTION="trash-put made compatible to GNUs rm and rmdir"
|
|
HOMEPAGE="https://github.com/PhrozenByte/rmtrash"
|
|
SRC_URI="https://github.com/PhrozenByte/rmtrash/archive/v${PV}.tar.gz -> ${PN}-${PV}.tar.gz"
|
|
|
|
LICENSE="GPL-3"
|
|
SLOT="0"
|
|
KEYWORDS="~amd64"
|
|
|
|
RESTRICT="mirror"
|
|
|
|
RDEPEND="app-misc/trash-cli"
|
|
|
|
src_install() {
|
|
insinto /usr/bin
|
|
insopts -m755
|
|
doins rmtrash
|
|
doins rmdirtrash
|
|
}
|
|
|
|
pkg_postinst() {
|
|
elog "It is suggested to add following code into ~/.bashrc:"
|
|
elog "--------------------------------------------------------------------"
|
|
elog " alias rm='rmtrash'"
|
|
elog " alias rmdir='rmdirtrash'"
|
|
elog " alias sudo='sudo '"
|
|
elog "--------------------------------------------------------------------"
|
|
elog "see https://github.com/PhrozenByte/rmtrash for more information"
|
|
}
|