From dcb6406b55f7e337137f8902082aa410ef550528 Mon Sep 17 00:00:00 2001 From: Philipp Stephani Date: Thu, 27 Aug 2026 11:59:08 +0200 Subject: [PATCH] Explicitly require batch mode for a few more tools --- elisp/private/tools/gen-proto.el | 1 + tests/proto/integration/cat.el | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/elisp/private/tools/gen-proto.el b/elisp/private/tools/gen-proto.el index 04e7ee67e..7f7e28b1d 100644 --- a/elisp/private/tools/gen-proto.el +++ b/elisp/private/tools/gen-proto.el @@ -166,6 +166,7 @@ enumeration type, and VALUES is a list of (NAME NUMBER) pairs." (cons output-file (buffer-substring-no-properties (point-min) (point-max)))))) +(unless noninteractive (user-error "This file works only in batch mode")) (set-binary-mode 'stdin :binary) (set-binary-mode 'stdout :binary) (let* ((standard-output #'external-debugging-output) diff --git a/tests/proto/integration/cat.el b/tests/proto/integration/cat.el index 3b96f4678..5c16f4c3e 100644 --- a/tests/proto/integration/cat.el +++ b/tests/proto/integration/cat.el @@ -1,6 +1,6 @@ ;;; cat.el --- helper binary for module test -*- lexical-binding: t; -*- -;; Copyright 2024, 2025 Philipp Stephani +;; Copyright 2024-2026 Philipp Stephani ;; ;; Licensed under the Apache License, Version 2.0 (the "License"); ;; you may not use this file except in compliance with the License. @@ -24,6 +24,7 @@ (require 'elisp/proto/module) +(unless noninteractive (user-error "This file works only in batch mode")) (set-binary-mode 'stdin :binary) (set-binary-mode 'stdout :binary)