From 8efda56a6af32c85fd6fa829415bdab0f62d2afa Mon Sep 17 00:00:00 2001 From: hiento09 <136591877+hiento09@users.noreply.github.com> Date: Thu, 1 Aug 2024 12:04:37 +0700 Subject: [PATCH] Add launchpad uninstaller prerm and postrm (#957) Co-authored-by: Hien To --- .../launchpad/cortexso/debian/postrm | 10 ++++++++++ .../launchpad/cortexso/debian/prerm | 6 ++++++ 2 files changed, 16 insertions(+) create mode 100644 package-managers-template/launchpad/cortexso/debian/postrm create mode 100644 package-managers-template/launchpad/cortexso/debian/prerm diff --git a/package-managers-template/launchpad/cortexso/debian/postrm b/package-managers-template/launchpad/cortexso/debian/postrm new file mode 100644 index 000000000..257c7375f --- /dev/null +++ b/package-managers-template/launchpad/cortexso/debian/postrm @@ -0,0 +1,10 @@ +#!/bin/sh +set +e + +for userdir in /home/*; do + if [ -d "$userdir/cortex" ]; then + rm -rf "$userdir/cortex" > /dev/null 2>&1 + fi +done + +exit 0 diff --git a/package-managers-template/launchpad/cortexso/debian/prerm b/package-managers-template/launchpad/cortexso/debian/prerm new file mode 100644 index 000000000..40b730f2b --- /dev/null +++ b/package-managers-template/launchpad/cortexso/debian/prerm @@ -0,0 +1,6 @@ +#!/bin/sh +set +e + +/usr/bin/cortex stop > /dev/null 2>&1 + +exit 0 \ No newline at end of file