[network/konversation] /: Remove broken "mail" script
Friedrich W. H. Kossebau
null at kde.org
Wed Oct 28 16:54:53 GMT 2020
Git commit 3e9bd5b35fb5244c8e8a8da9905a13acd6f87c63 by Friedrich W. H. Kossebau.
Committed on 28/10/2020 at 16:54.
Pushed by kossebau into branch 'master'.
Remove broken "mail" script
No one has shown interest to fix it in years
M +0 -1 data/scripts/CMakeLists.txt
M +0 -4 data/scripts/README
D +0 -70 data/scripts/mail
M +0 -12 doc/index.docbook
https://invent.kde.org/network/konversation/commit/3e9bd5b35fb5244c8e8a8da9905a13acd6f87c63
diff --git a/data/scripts/CMakeLists.txt b/data/scripts/CMakeLists.txt
index dc1b0120..7c12cbe4 100644
--- a/data/scripts/CMakeLists.txt
+++ b/data/scripts/CMakeLists.txt
@@ -3,7 +3,6 @@ install(PROGRAMS
cmd
fortune
gauge
- mail
media
sayclip
sysinfo
diff --git a/data/scripts/README b/data/scripts/README
index de4628c0..aeed81b2 100644
--- a/data/scripts/README
+++ b/data/scripts/README
@@ -38,10 +38,6 @@ media Plays the currently played media.
Supports amaroK,JuK,Noatun,Kaffeine
Usage: /media
-mail Print the number of unread emails in your inbox folder in
- kmail. Kmail or kontact must be running.
- Usage: /mail [folder-substring]
-
google Use Google services
Usage: /google (--search) <query> # Search <query> in Google
/google --spell <word> # Spellcheck <word> using Google
diff --git a/data/scripts/mail b/data/scripts/mail
deleted file mode 100755
index 49dd5268..00000000
--- a/data/scripts/mail
+++ /dev/null
@@ -1,70 +0,0 @@
-#!/bin/bash
-#
-# SPDX-License-Identifier: GPL-2.0-or-later
-#
-# SPDX-FileCopyrightText: 2005 John Tapsell <john.tapsell at kdemail.net>
-
-SERVER=$1;
-TARGET=$2;
-
-FOLDER=$3;
-
-
-if [ "$FOLDER" = "" ] ; then
- FOLDER="inbox"
-fi
-
-
-getmails()
-{
-
- qdbus org.kde.kmail > /dev/null || {
- qdbus org.kde.konversation /irc info "Sorry kmail is not running"
- exit
- }
-
- for f in $(qdbus org.kde.kmail /KMail folderList) ; do
- qdbus org.kde.kmail /KMail getFolder $f > /dev/null
- MAILFOLDER=$(qdbus org.kde.kmail /Folder "displayPath" | grep -i $FOLDER)
- if [ "$MAILFOLDER" != "" ] ; then
- FOUNDFOLDER=1
- MAILCOUNT=$(qdbus org.kde.kmail /Folder unreadMessages )
- MAILTOTALCOUNT=$(qdbus org.kde.kmail /Folder messages )
- MAILTOTALCOUNT=$(($MAILCOUNT + $MAILTOTALCOUNT))
- if [[ -z "$MAILCOUNT" ]] ; then MAILCOUNT = "0" ; fi
- if [ "$MAILCOUNT" != 0 ] ; then
- FOUNDEMAIL=1
- echo "Email folder %B$MAILFOLDER%B has %B$MAILCOUNT%B unread messages, out of %B$MAILTOTALCOUNT%B"
- fi
- fi
- done
-
- if [[ -z "$FOUNDEMAIL" ]] ; then
- if [[ -z "$FOUNDFOLDER" ]] ; then
- qdbus org.kde.konversation /irc info "No email folders were found that had a name containing '$FOLDER'"
- exit
- else
- echo "No new emails in any folders matching '$FOLDER'"
- fi
- fi
-
-}
-
-if [[ -z "$2" ]] ; then
- echo "Scripts are not meant to be called from the command line."
- echo "This script should be installed to $KDEDIR/share/apps/konversation/scripts"
- echo "Then executed with /exec mail from the konversation"
- echo
- echo The output is:
- getmails
- exit
-fi
-
-#LINECOUNT=$(getmails | wc -l)
-#if [[ "$LINECOUNT" -gt 5 ]] ; then
-# dcop $PORT default info "There are more than 5 matches. Cancelling to avoid flooding the server"
-# exit
-#fi
-
-getmails | head -n 3 | while read line; do qdbus org.kde.konversation /irc say $SERVER "$TARGET" "$line"; done
-
diff --git a/doc/index.docbook b/doc/index.docbook
index e2599c05..ddb2e9e8 100644
--- a/doc/index.docbook
+++ b/doc/index.docbook
@@ -2666,18 +2666,6 @@ kernel bug report</replaceable></para>
<para>Sample output: <replaceable>Beer load [ | ] 50%</replaceable></para>
</listitem>
</varlistentry>
-<!--FIXME Error: No email folders were found that had a name containing 'foo'
-<varlistentry>
-<term><userinput><command>/exec </command> <replaceable>mail</replaceable> [<replaceable>KMail Email Folder</replaceable>]</userinput>
-</term>
-<listitem>
-<para>This script is used to show the current unread mail and total mail count in KMail.</para>
-<para>Example: To output the current unread mail count in your inbox folder.</para>
-<para><userinput><command>/exec </command> <replaceable>mail inbox</replaceable></userinput></para>
-<para>Sample output: <replaceable>Email folder inbox has 30 unread messages, out of 800</replaceable></para>
-</listitem>
-</varlistentry>
--->
<varlistentry>
<term><userinput><command>/exec </command> <replaceable>media</replaceable> [<replaceable>audio|video|{player}</replaceable>]</userinput>
</term>
More information about the kde-doc-english
mailing list