From nobody Thu Oct 01 08:08:03 2026 X-Original-To: dev-commits-src-all@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 4hwPfx36qKz6vF9F for ; Thu, 01 Oct 2026 08:08:09 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "YR2" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4hwPfx0d3pz4bk3 for ; Thu, 01 Oct 2026 08:08:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1790842089; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=YFdbozDX8HdP0pWvwOFmGaOypJv6XGRoBs62hdka/Kw=; b=bIatQQ3b055eGZtu6L9kzbzL5w6gX2c9hr9CKvYea0ewuinP8iNflGKe2hMndwlzHKnqOe iPluuUZFeSd4e/eMICq5huJ0qyFPVLHln8crRBGSMTEPl/cDvy/iHMSj6H5ipkhH2EI+T8 sEDGKyZeMR0GAGh4JJ58L3c6jEp0Z4Lvc1/QHQUROu7VHC8e4EbhmorOQOE88op+Rk7x9N q3Oxfs9Z/YetTv3HZfl1efMwqbLTn1yU7l2RKKdJNky1JE9QEBNnpDX1lG/9vt4jyEPQnw bvUIt8Keud9UcyKJiitWXZc+xjf19jmcxbWBfAH/ETT42DJN+6sjaqeltCfgeQ== ARC-Seal: i=1; a=rsa-sha256; d=freebsd.org; s=dkim; cv=none; t=1790842089; b=sp+uA0FoN/yTufuP0jMBJnWDO6kUhN9hX+9axT1DpY6QMCHU56rSkLPdQXKW6/+NR23E0J JCF9IU8Y9n2ELTXsPFJxn6uhSUMmiCotaGINx5PzVDHucwqFAqOxnExMAgm+Vpfnwcs7SY erEZcMsqZMp7dSJw95OElebhiZQIfSHIKPUmZviSWsJgPJujZ2DJ1Eler+D44IRCRI13JG y4DOWX//ySCquejOmART1Ay3KbJL2Zfn+2r//pYMCZn2WQjJlfYESs0iTc+TfDGlzFSyQX pZlbtPIEdgHDN6gs1ZWb+1mL77UIy0IoEKAd5FH9ZtDzXQV44mqDnbq8M9rVaA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1790842089; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=YFdbozDX8HdP0pWvwOFmGaOypJv6XGRoBs62hdka/Kw=; b=B8bBtWEAV7SHeGJ8pEjVRTkmD4ARVtbrJogaZKJkYrjSeJxhJ+YKkt/XTUIQp0M8OWG/Rz CVhUEu2oN2VWPOWTl8sAHfsapr8ALDy2fZ2EBa4MddbaLLRWWIsuzgp2oETCoqkrQ6t5Nh zDPUTY2DaxZp2KhRP56Av04yKjdDZcl4qfz/qFB3P3YWhKcCxk19JosQkCsSLD2SfvgI2U P6FF+TuTC3rHjJFak63TaE4tsRnnnjbCzdaF24obrPqbt5I330dj8ns5N69MEbu1O8g0T+ K/TNmjfdMEDeAh3nwrlMqnSA8uZCyGWw9TblWGkA+GbNFcIeZUHbAYGcwOUi7Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4hwPfw6p9qzMW7 for ; Thu, 01 Oct 2026 08:08:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 23bc1 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 01 Oct 2026 08:08:03 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 2670aa4807f0 - stable/15 - sdiff.1: Document exit status and --help List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 2670aa4807f04c484c4f5449b6fa25d98c4b8961 Auto-Submitted: auto-generated Date: Thu, 01 Oct 2026 08:08:03 +0000 Message-Id: <6abe14e3.23bc1.3e322f1e@gitrepo.freebsd.org> The branch stable/15 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=2670aa4807f04c484c4f5449b6fa25d98c4b8961 commit 2670aa4807f04c484c4f5449b6fa25d98c4b8961 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2026-09-23 14:19:05 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2026-10-01 08:07:56 +0000 sdiff.1: Document exit status and --help MFC after: 3 days Approved by: bnovkov (mentor) Sponsored by: fme AG Differential Revision: https://reviews.freebsd.org/D59927 (cherry picked from commit 14c7492637ec0644b5bb88da114e8cc76b9bf629) --- usr.bin/sdiff/sdiff.1 | 23 ++++++++++++++++++++++- usr.bin/sdiff/sdiff.c | 1 + 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/usr.bin/sdiff/sdiff.1 b/usr.bin/sdiff/sdiff.1 index e228ece64331..ced741eec31e 100644 --- a/usr.bin/sdiff/sdiff.1 +++ b/usr.bin/sdiff/sdiff.1 @@ -3,7 +3,7 @@ .\" Written by Raymond Lai . .\" Public domain. .\" -.Dd February 16, 2024 +.Dd September 23, 2026 .Dt SDIFF 1 .Os .Sh NAME @@ -17,6 +17,8 @@ .Op Fl w Ar width .Ar file1 .Ar file2 +.Nm sdiff +.Fl -help .Sh DESCRIPTION .Nm displays two files side by side, @@ -85,6 +87,8 @@ Print a maximum of .Ar width characters on each line. The default is 130 characters. +.It Fl -help +Print the usage message and exit. .El .Pp Options passed to @@ -153,6 +157,23 @@ Specifies a directory for temporary files to be created. The default is .Pa /tmp . .El +.Sh EXIT STATUS +The +.Nm +utility exits with one of the following values: +.Pp +.Bl -tag -width Ds -offset indent -compact +.It 0 +No differences were found. +.It 1 +Differences were found. +.It >1 +An error occurred. +.El +.Pp +The +.Fl -help +option exits with a status of 0. .Sh SEE ALSO .Xr cmp 1 , .Xr diff 1 , diff --git a/usr.bin/sdiff/sdiff.c b/usr.bin/sdiff/sdiff.c index b796bb4224a8..628e6cde46d9 100644 --- a/usr.bin/sdiff/sdiff.c +++ b/usr.bin/sdiff/sdiff.c @@ -117,6 +117,7 @@ static struct option longopts[] = { static const char *help_msg[] = { "usage: sdiff [-abdilstW] [-I regexp] [-o outfile] [-w width] file1 file2\n", + " sdiff --help\n", "-l, --left-column: only print the left column for identical lines.", "-o OUTFILE, --output=OUTFILE: interactively merge file1 and file2 into outfile.", "-s, --suppress-common-lines: skip identical lines.",