#!/bin/bash

# dpkg-remove -- command line tool to flag package(s) for removal.
#
# by Craig Sanders, 1998-10-26.  This script is hereby placed into the
# public domain.
#
# 2017-09-06 update: apt-mark does this better.  My dpkg-hold etc
# scripts are now wrappers around apt-mark and continue to exist only so
# that any existing scripts that depend on them don't break..

PROGNAME=$(basename "$0")

. /usr/share/dpkg/sh/dpkg-error.sh

setup_colors

warning "deprecated program; use 'dpkg --set-selections' or 'apt-mark'"

if [ -z "$*" ]; then
  echo "Usage: dpkg-deinstall <package>..."
  exit 1
fi

#for i in $@; do
#  echo "$i	deinstall"
#done | dpkg --set-selections

apt-mark remove "$@"
