aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Deutschmann <whissi@gentoo.org>2019-03-11 02:13:53 +0100
committerThomas Deutschmann <whissi@gentoo.org>2019-03-11 05:56:21 +0100
commit66c4c263a0f983bfb456e43cc674a25323ea189c (patch)
tree8676d63a633fa13b75f9f3180d464cb8cd6be7d5
parentAdd cleanup action (diff)
downloadeselect-rust-66c4c263.tar.gz
eselect-rust-66c4c263.tar.bz2
eselect-rust-66c4c263.zip
Mark "unset" action as deprecated
As long as one Rust implementation is installed, there should be always a Rust implementation marked as default. However, we need to keep this function until all ebuilds which are calling "eselect rust unset" are gone. So make this action an alias of new cleanup action. Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>
-rw-r--r--rust.eselect.in30
1 files changed, 2 insertions, 28 deletions
diff --git a/rust.eselect.in b/rust.eselect.in
index 1360dc2..0ecf87a 100644
--- a/rust.eselect.in
+++ b/rust.eselect.in
@@ -284,37 +284,11 @@ do_update() {
### unset action ###
describe_unset() {
- echo "Unset active Rust version"
-}
-
-describe_unset_options() {
- echo "--if-invalid : Unset only if symlink is invalid (e.g. package was uninstalled)"
+ echo 'DEPRECATED: Use "cleanup" action instead!'
}
do_unset() {
- local if_invalid="0"
- while [[ $# > 0 ]]; do
- case "$1" in
- --if-invalid)
- if_invalid="1"
- ;;
- *)
- die -q "Unrecognized argument '$1'"
- ;;
- esac
- shift
- done
-
- if [[ "${if_invalid}" == "1" ]]; then
- local missing_symlinks=( $(find_missing_broken_symlinks) )
- if [[ ${#missing_symlinks[@]} -eq 0 ]]; then
- return
- else
- echo "Not all symlinks set. Will unset current symlinked Rust binaries!"
- fi
- fi
-
- unset_version || die -q "Couldn't unset active version"
+ do_cleanup
}
# vim: set ft=eselect :