From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: =?UTF-8?Q?Max_Zettlmei=C3=9Fl?= Newsgroups: gmane.emacs.erc.general,gmane.emacs.help Subject: Re: ERC custom IRC /command Date: Sun, 17 Mar 2019 14:55:25 +0100 Message-ID: References: <86r2b8sysx.fsf@zoho.eu> Reply-To: ERC Discussion Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="34291"; mail-complaints-to="usenet@blaine.gmane.org" Cc: help-gnu-emacs@gnu.org, Emanuel Berg To: ERC Discussion Original-X-From: erc-discuss-bounces+sf-erc-help=m.gmane.org@gnu.org Sun Mar 17 15:29:52 2019 Return-path: Envelope-to: sf-erc-help@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1h5WnQ-0008mY-5G for sf-erc-help@m.gmane.org; Sun, 17 Mar 2019 15:29:52 +0100 Original-Received: from localhost ([127.0.0.1]:56307 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h5WnO-0007Cu-Vy for sf-erc-help@m.gmane.org; Sun, 17 Mar 2019 10:29:51 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:58026) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h5WGL-0007qc-Lk for erc-discuss@gnu.org; Sun, 17 Mar 2019 09:55:42 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1h5WGK-0001Rz-KD for erc-discuss@gnu.org; Sun, 17 Mar 2019 09:55:41 -0400 Original-Received: from mail-it1-x12a.google.com ([2607:f8b0:4864:20::12a]:34455) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1h5WGK-0001RP-2I for erc-discuss@gnu.org; Sun, 17 Mar 2019 09:55:40 -0400 Original-Received: by mail-it1-x12a.google.com with SMTP id l4so7543556ite.1 for ; Sun, 17 Mar 2019 06:55:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=zettlmeissl.de; s=default; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=vN65rZMv5p6X0hitWH7WLEPP85F3LjcMN3YJwbmw80o=; b=GOssf0/tKGy9sgeB1VWcio6PkRfOEU1MYtI8T2264f1t/W9zHyr5N+eHH7VQHzhNvz HAzwk7RVuaCdPbwuK8K6OstylfDbP6lGkPpRRW5tmVZ1H/GHl3KfB3UCCNKoIRIujjHc fyPjQlZaSgmH2MUkfzyCFC1Hb5vcw8cuPy9wGp3Pzn4teFnSXCQLII96EQhIZ1hFl5N6 I+todH76YA2l253WD5j1pPtUm0ao9kBvFauTSPeEJT+fY+zRd9wxANpIhVv5npvFCvpb uIO6gj8ihe63L0+dda+aZ3zWxYEmJ8WImRBuGyqeX6rZ33WHNyMQRUqtFGArfCehaTAJ zLrg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=vN65rZMv5p6X0hitWH7WLEPP85F3LjcMN3YJwbmw80o=; b=mamdvqdydlcQz6aGMbV4+pF35G/xOannOU0AXfpTXoEpvPw9oYErvmHQSrO2P8koPa 7eutP25tIkEALmPONzVgMEEvPClXB8pXmUPhgUMho5tjxNWqfqy1yvJzOKHzBOVGUmsx 5nUhMl4e9ZY28v5Bik8PW/j+MBBl3tzLybQkOvHwoyBPrqsA8CHKRpPf6I2SyXBfCR8E lgwW4EXdp7NnVVPPeZdhM45CD5fdNyloeltFiWQz/SKB9EKg76NQAX8fQnWCExHtchvu pfKHd2qpfWQDtXP2JtD+IPWSuIDQVnn/n6hunKHrwV3M0Wf/2dq5G01RkWLdht96e1y8 EauQ== X-Gm-Message-State: APjAAAXjcQup+aJKDxVmXp5WCJP0XHtakPmft1cG2D4zHADzJb/D96vl vX85czZ+3lYSplj3PymkDXHnfJwBgnM= X-Google-Smtp-Source: APXvYqyA19xXwODGqVXSiUNtQqe9AmE4xfyFhSQ3fXwejVjR5cHHc0B2FM4jeDR4pz7N1FXkjIdODw== X-Received: by 2002:a02:8c17:: with SMTP id l23mr8751463jak.20.1552830938244; Sun, 17 Mar 2019 06:55:38 -0700 (PDT) Original-Received: from mail-it1-f179.google.com (mail-it1-f179.google.com. [209.85.166.179]) by smtp.gmail.com with ESMTPSA id t73sm4051604itt.15.2019.03.17.06.55.37 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 17 Mar 2019 06:55:37 -0700 (PDT) Original-Received: by mail-it1-f179.google.com with SMTP id l15so17477206iti.4; Sun, 17 Mar 2019 06:55:37 -0700 (PDT) X-Received: by 2002:a24:6547:: with SMTP id u68mr7480220itb.100.1552830937132; Sun, 17 Mar 2019 06:55:37 -0700 (PDT) In-Reply-To: <86r2b8sysx.fsf@zoho.eu> X-Gmail-Original-Message-ID: X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::12a X-Mailman-Approved-At: Sun, 17 Mar 2019 10:29:46 -0400 X-BeenThere: erc-discuss@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: ERC Discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: erc-discuss-bounces+sf-erc-help=m.gmane.org@gnu.org Original-Sender: "Erc-discuss" Xref: news.gmane.org gmane.emacs.erc.general:1464 gmane.emacs.help:119646 Archived-At: On Fri, Mar 15, 2019 at 2:37 AM Emanuel Berg wrote: > > How can I make a custom ERC IRC command, > By defining a function using the "erc-cmd-" prefix, e.g. using your example command "/r": erc-cmd-R (defun erc-cmd-R () ;; If you want to send something to the server you could use ;; erc-send-message or erc-message, depending on what ;; exactly you intend to do. ... nil) A look into the ERC manual would have pointed you in the right direction. The feature is named under [1] and [2] even contains an example of it's use. Using a search engine of your choice to search for "emacs erc custom command" would also have helped you. [1] https://www.gnu.org/software/emacs/manual/html_node/erc/Special-Features.html [2] https://www.gnu.org/software/emacs/manual/html_mono/erc.html#Sample-Configuration [3] https://www.emacswiki.org/emacs/ErcCommands (At the very bottom of the page.)