From nobody Sun Aug 06 15:27:46 2023 X-Original-To: hackers@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4RJjy82cBSz4Ttl7 for ; Sun, 6 Aug 2023 15:28:00 +0000 (UTC) (envelope-from bakul@iitbombay.org) Received: from mail-pf1-x431.google.com (mail-pf1-x431.google.com [IPv6:2607:f8b0:4864:20::431]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RJjy75Nl2z3LQJ for ; Sun, 6 Aug 2023 15:27:59 +0000 (UTC) (envelope-from bakul@iitbombay.org) Authentication-Results: mx1.freebsd.org; none Received: by mail-pf1-x431.google.com with SMTP id d2e1a72fcca58-6873a30d02eso2431452b3a.3 for ; Sun, 06 Aug 2023 08:27:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=iitbombay-org.20221208.gappssmtp.com; s=20221208; t=1691335678; x=1691940478; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=tlE/zy0zrbtJFVJaawo7xKVVCLdnvTtImB/9UVJSF/A=; b=FRZyCjvNui4MwHpcy6iRlh6wQWarf6WFab2S/wBH0HV4ztR1JDIGcMXRluYbfPdmYO 2xjHL1cne8cTsyFjjSC2Ne6y/aO8I7uPBsvu9QEUye2wsBccJFwgIYQYkGPcyAVXeuGB hzVnTlvq4PA6uhMdDJcj3R2m+lE4rsIM97UzPXO2dw62ycK6weCcR4PeTjC4Gs+kCBxz sWGUbN+dYhzOsyd7bjyQWFza5SLf1U/dwFX/2UsCBXMAyQ+ibpQhM1M/cDZ+LKzCoRkm KrXHsQh6ZE92azVF5sKId6JgZestsFwM+7FKTA/6ZFMxogd1ie8TRCBlvSWniHbFx0UQ Jqkg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691335678; x=1691940478; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=tlE/zy0zrbtJFVJaawo7xKVVCLdnvTtImB/9UVJSF/A=; b=fHsdbE6t2E4v2mAOXpw7JSHGBjr57faRU3x+q3mUQHhVVO7iSYf/JIHff9uQqxvPH4 uy7sTokf+H5Re1eOtb+3ZYgy8O20HaGTR6GlwZl/Txc5Rilmse/APRqBx/QxV9JNt5pO nf2wqlwxKEbL30KhTdKaSpb5UJ3v9vqPsqXI1LW7ejC8j6Lj1FliebcI8xxl1LJpz4F8 zuCtI1bhowh0P+31YEM635wGS8HMZYF2kk4mj4ep/ELWcj63sd9IrVPP2hy0tuDhxZDk dnZeqdKUktyHPmbqFPJY5LrfDnYceymIGX22mNTDOqL8r0FvZYUPARfp/LCWD2UOwK07 Kk+g== X-Gm-Message-State: AOJu0YzGtOVkGZ+7+YPn0yHd3NOWAuf5xKOHlWQ+6J2X+2rjo1QD5m4m n/69VJYwNa8nzNihWbpKU7Frs7wJwpOQgWk8vnU= X-Google-Smtp-Source: AGHT+IG6wkPzkPzY/USFaBNgj1yEkxF7hXGRuDoQUdKcfmIfidx/a1R/8A7+Yr0rnme94x/sno0w7g== X-Received: by 2002:a05:6a00:2305:b0:686:2b60:3348 with SMTP id h5-20020a056a00230500b006862b603348mr6899572pfh.21.1691335677849; Sun, 06 Aug 2023 08:27:57 -0700 (PDT) Received: from smtpclient.apple (107-215-223-229.lightspeed.sntcca.sbcglobal.net. [107.215.223.229]) by smtp.gmail.com with ESMTPSA id t7-20020aa79387000000b00687087d3647sm4679985pfe.142.2023.08.06.08.27.57 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Sun, 06 Aug 2023 08:27:57 -0700 (PDT) Content-Type: text/plain; charset=utf-8 List-Id: Technical discussions relating to FreeBSD List-Archive: https://lists.freebsd.org/archives/freebsd-hackers List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-hackers@freebsd.org Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3731.600.7\)) Subject: Re: deroff(1) and deroff (1b) with mdoc(7) (was: demandoc(1)) From: Bakul Shah In-Reply-To: <238083d9-c937-930c-9f15-7f8708c4205a@freebsd.org> Date: Sun, 6 Aug 2023 08:27:46 -0700 Cc: freebsd-hackers Content-Transfer-Encoding: quoted-printable Message-Id: References: <0345d177-0da2-e41b-6a49-b3fe06e52be0@freebsd.org> <79117D20-0A32-4548-9250-27CCF6650403@iitbombay.org> <238083d9-c937-930c-9f15-7f8708c4205a@freebsd.org> To: Graham Perrin X-Mailer: Apple Mail (2.3731.600.7) X-Rspamd-Queue-Id: 4RJjy75Nl2z3LQJ X-Spamd-Bar: ---- X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US] On Aug 6, 2023, at 4:32 AM, Graham Perrin = wrote: >=20 > deroff(1) /usr/local/heirloom/usr/5bin/deroff is potentially more = useful than > deroff(1b) /usr/local/heirloom/usr/ucb/deroff however > deroff(1) removes a little too much; = . Heirloom deroff was derived from plan9 deroff. >=20 > >=20 > deroff(1) in Plan 9 from User Space has: >=20 > - a manual page that differs from deroff(1) and deroff(1b) in the = Heirloom Toolchest >=20 > - the same glitch (below). >=20 >=20 > % cat /usr/src/share/man/man8/rc.8 | grep Operation\ of > .Ss Operation of Nm > .Ss Operation of Nm rc.shutdown > % /usr/local/plan9/bin/deroff /usr/src/share/man/man8/rc.8 | grep = Operation > Operation > Operation rc.shutdown > % Why not try to fix deroff to also support mdoc just as it supports mm = and ms macros? I hope you are not talking about adding demandoc to the base! Incidentally FreeBSD man fails at properly formatting deroff.1 man page. It produces -mm Remove titles, attachments, etc., as well as ordinary = troff constructs, from or mm documents. nroff -man produces this: -mm Remove titles, attachments, etc., as well as ordinary = troff con=E2=80=90 structs, from ms(7) or mm(7) documents. 9 man -mm Remove titles, attachments, etc., as well as ordinary troff constructs, from ms(7) or mm documents.=20 =09 mandoc man page says: By default, the input language is automatically detected for each file: if = the first macro is Dd or Dt, the mdoc(7) parser is used; = otherwise, the man(7) parser is used. With other arguments, -m is = silently ignored. So either it is using the wrong parser or the parser is doing the wrong = thing!=