From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id GLfKKUdo6V7yagAA0tVLHw (envelope-from ) for ; Wed, 17 Jun 2020 00:48:07 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id GOBzJUdo6V6oKwAAbx9fmQ (envelope-from ) for ; Wed, 17 Jun 2020 00:48:07 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 0B05D940C04 for ; Wed, 17 Jun 2020 00:48:07 +0000 (UTC) Received: from localhost ([::1]:42350 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jlMFK-0008Mu-04 for larch@yhetil.org; Tue, 16 Jun 2020 20:48:06 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:45618) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jlMDs-0007zx-7O for emacs-orgmode@gnu.org; Tue, 16 Jun 2020 20:46:36 -0400 Received: from memebeam.org ([80.68.89.71]:41271 helo=jvb.vm.bytemark.co.uk) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jlMDp-0004Ux-S2 for emacs-orgmode@gnu.org; Tue, 16 Jun 2020 20:46:35 -0400 Received: from silver (dhcp-68-142-47-225.greenmountainaccess.net [::ffff:68.142.47.225]) (AUTH: PLAIN acarrico@memebeam.org, TLS: TLS1.3, 256bits, ECDHE_RSA_AES_256_GCM_SHA384) by jvb.vm.bytemark.co.uk with ESMTPSA id 0000000000184063.5EE967BD.00000454; Tue, 16 Jun 2020 20:45:49 -0400 Date: Tue, 16 Jun 2020 20:45:45 -0400 From: Anthony Carrico To: emacs-orgmode@gnu.org Subject: [PATCH] Org-mode publish avoids inserting licensed content into target documents. Message-ID: <20200617002335.l4lg3slfxm74vx3h@silver> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Content-Disposition: inline Received-SPF: pass client-ip=80.68.89.71; envelope-from=acarrico@memebeam.org; helo=jvb.vm.bytemark.co.uk X-detected-operating-system: by eggs.gnu.org: First seen = 2020/06/16 20:45:50 X-ACL-Warn: Detected OS = Linux 3.1-3.10 X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Spam-Score: -0.01 X-TUID: QxBsdqdZlor3 * It is customary for compilers to avoid claiming authorship over target code. However, the org-mode publish document publisher silently inserted licensed content into target documents. This patch replaces the GPL-V3 licensed highlighter script with a public domain version to resolve this issue. The public domain version works in a different way than the original. It adds(removes) highlighting rather than replacing the original format. In contrast, the old version caches(restores). Because the new add(remove) method is idempotent, the public domain version avoids a potential bug in the original: the cached value would be lost if it was called twice in succession. This entire patch is released to the public domain by its author, Anthony Carrico. TINYCHANGE --- lisp/ox-html.el | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/lisp/ox-html.el b/lisp/ox-html.el index 32996c2c2..6a4555bc7 100644 --- a/lisp/ox-html.el +++ b/lisp/ox-html.el @@ -233,25 +233,23 @@ property on the headline itself.") (defconst org-html-scripts "