unofficial mirror of meta@public-inbox.org
 help / color / mirror / Atom feed
From: Eric Wong <e@80x24.org>
To: meta@public-inbox.org
Subject: [PATCH] lei_mirror: fix sh syntax error in "make help" target
Date: Sun, 26 Mar 2023 08:21:32 +0000	[thread overview]
Message-ID: <20230326082132.1842609-1-e@80x24.org> (raw)

Oops :x

Fixes: 836faf5093df ("lei_mirror: add `index' target to generated Makefile")
---
 lib/PublicInbox/LeiMirror.pm | 2 +-
 t/lei-mirror.t               | 6 +++++-
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/lib/PublicInbox/LeiMirror.pm b/lib/PublicInbox/LeiMirror.pm
index c437b789..e0709fbd 100644
--- a/lib/PublicInbox/LeiMirror.pm
+++ b/lib/PublicInbox/LeiMirror.pm
@@ -1370,7 +1370,7 @@ help :
 	@echo Rarely needed targets:
 	@echo '    make reindex      - may be needed for new features/bugfixes'
 	@echo '    make compact      - rewrite Xapian storage to save space'
-	@echo '    make index        - initial index after clone
+	@echo '    make index        - initial index after clone'
 
 fetch :
 	public-inbox-fetch
diff --git a/t/lei-mirror.t b/t/lei-mirror.t
index c172483b..2400578a 100644
--- a/t/lei-mirror.t
+++ b/t/lei-mirror.t
@@ -1,10 +1,11 @@
 #!perl -w
-# Copyright (C) 2020-2021 all contributors <meta@public-inbox.org>
+# Copyright (C) all contributors <meta@public-inbox.org>
 # License: AGPL-3.0+ <https://www.gnu.org/licenses/agpl-3.0.txt>
 use strict; use v5.10.1; use PublicInbox::TestCommon;
 use PublicInbox::Inbox;
 require_mods(qw(-httpd lei DBD::SQLite));
 require_cmd('curl');
+use PublicInbox::Spawn qw(which);
 require PublicInbox::Msgmap;
 my $sock = tcp_server();
 my ($tmpdir, $for_destroy) = tmpdir();
@@ -25,7 +26,10 @@ test_lei({ tmpdir => $tmpdir }, sub {
 	is(PublicInbox::Git::try_cat("$t1/description"),
 		"mirror of $http/t1/\n", 'description set');
 	ok(-f "$t1/Makefile", 'convenience Makefile added (v1)');
+	my $make = which('make');
+	xsys_e([$make, 'help'], undef, { -C => $t1, 1 => \(my $help) });
 	ok(-f "$t1/inbox.config.example", 'inbox.config.example downloaded');
+	isnt($help, '', 'make help worked');
 	is((stat(_))[9], $created{v1},
 		'inbox.config.example mtime is ->created_at');
 	is((stat(_))[2] & 0222, 0, 'inbox.config.example not writable');

                 reply	other threads:[~2023-03-26  8:21 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://public-inbox.org/README

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230326082132.1842609-1-e@80x24.org \
    --to=e@80x24.org \
    --cc=meta@public-inbox.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).