Bug 281591 - [PATCH] sysutils/zrepl-dsh2dsh: update to 0.8.3
Summary: [PATCH] sysutils/zrepl-dsh2dsh: update to 0.8.3
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Robert Clausecker
URL: https://github.com/dsh2dsh/zrepl/rele...
Keywords:
Depends on:
Blocks:
 
Reported: 2024-09-19 17:46 UTC by Denis Shaposhnikov
Modified: 2024-09-25 06:35 UTC (History)
1 user (show)

See Also:


Attachments
zrepl-dsh2dsh-0.8.3.patch (10.68 KB, patch)
2024-09-19 17:46 UTC, Denis Shaposhnikov
dsh: maintainer-approval+
Details | Diff
zrepl-dsh2dsh-0.8.3.patch (11.01 KB, patch)
2024-09-21 13:40 UTC, Denis Shaposhnikov
dsh: maintainer-approval+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Denis Shaposhnikov 2024-09-19 17:46:45 UTC
Created attachment 253668 [details]
zrepl-dsh2dsh-0.8.3.patch

Him,

this patch updates sysutils/zrepl-dsh2dsh to the latest release.
Comment 1 Robert Clausecker freebsd_committer freebsd_triage 2024-09-20 14:13:39 UTC
Thank you for the update.

Please don't put extra blank lines into pkg-descr.  The file is already over length and should not be made longer without a good reason.

Is there a particular reason for the gracefulstop command?  Can't you just modify the stop command to work like this?  I'm not an expert on rc scripts, so maybe there's something I missed here.
Comment 2 Denis Shaposhnikov 2024-09-20 14:25:22 UTC
(In reply to Robert Clausecker from comment #1)

> The file is already over length

Oops, sorry. I didn't know pkg-descr has so small limit.

> Is there a particular reason for the gracefulstop command?
> Can't you just modify the stop command to work like this?

That's up to user. For instance I have this in /etc/rc.conf:

zrepl_enable="YES"
zrepl_gracefully="YES"
zrepl_priority="warning"
zrepl_control_group="operator"
zrepl_control_mode="0750"

and `service zrepl stop` does graceful stop on system shutdown. But I believe somebody else wants force stop on system shutdown and wants to

`service zrepl gracefulstop && service zrepl start`

for restart after config change or like that.
Comment 3 Robert Clausecker freebsd_committer freebsd_triage 2024-09-20 14:53:02 UTC
The recommended pkg-descr limit is ~25 lines.

I understand your reasoning and will commit your patch with some light copy-editing.

Also please remember to set your editor to a tab-width of 8 when editing ports Makefiles.  It's all nicely aligned if you do so.

I'll also go ahead and reset the commit author to what you use here on Bugzilla.
Comment 4 Denis Shaposhnikov 2024-09-20 14:57:28 UTC
(In reply to Robert Clausecker from comment #3)
> to set your editor to a tab-width of 8

Oh, I tried to find tab-width in porters handbook and no luck. But I found

  tab-width: 4

in bsd.port.mk. Looks like your advise conflicts with it. I'd like to know what is official recommendation for tab-width in Makefiles, 8 or 4? Right now I'm using 4.
Comment 5 Robert Clausecker freebsd_committer freebsd_triage 2024-09-20 14:59:39 UTC
For ports Makefiles, 8 columns is correct.
bsd.port.mk is an infrastructure Makefile that doesn't follow the same formatting.
Comment 6 Robert Clausecker freebsd_committer freebsd_triage 2024-09-21 12:03:27 UTC
Build fails during check-plist:

====> Checking for pkg-plist issues (check-plist)
===> Parsing plist
===> Checking for items in STAGEDIR missing from pkg-plist
Error: Orphaned: @dir /var/run/zrepl
===> Checking for items in pkg-plist which are not in STAGEDIR
===> Error: Plist issues found.

Shall I re-add this entry?
Comment 7 Denis Shaposhnikov 2024-09-21 12:06:13 UTC
(In reply to Robert Clausecker from comment #6)
> Shall I re-add this entry?

No, no. I'll handle it. Thank you.
Comment 8 Denis Shaposhnikov 2024-09-21 13:40:55 UTC
Created attachment 253720 [details]
zrepl-dsh2dsh-0.8.3.patch
Comment 9 Denis Shaposhnikov 2024-09-21 13:42:22 UTC
(In reply to Robert Clausecker from comment #6)
> Shall I re-add this entry?

I uploaded new patch with the fix. Also I reformated it using tab-width 8 and I removed extra empty lines from pkg-descr, so it's now < 25 lines.
Comment 10 commit-hook freebsd_committer freebsd_triage 2024-09-25 06:31:18 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=664fa9b2fe89d886243f58a81f6109063bf208ea

commit 664fa9b2fe89d886243f58a81f6109063bf208ea
Author:     Denis Shaposhnikov <dsh@bamus.cz>
AuthorDate: 2024-09-21 13:38:04 +0000
Commit:     Robert Clausecker <fuz@FreeBSD.org>
CommitDate: 2024-09-25 06:28:04 +0000

    sysutils/zrepl-dsh2dsh: update to 0.8.3

    Changelog: https://github.com/dsh2dsh/zrepl/releases/tag/v0.8.3

    PR:             281591
    Event:          EuroBSDcon 2024

 sysutils/zrepl-dsh2dsh/Makefile        |  11 ++--
 sysutils/zrepl-dsh2dsh/distinfo        |  10 +--
 sysutils/zrepl-dsh2dsh/files/zrepl.in  | 116 ++++++++++++++++++++-------------
 sysutils/zrepl-dsh2dsh/files/zrepl.yml |  12 ----
 sysutils/zrepl-dsh2dsh/pkg-descr       |   8 ++-
 sysutils/zrepl-dsh2dsh/pkg-plist       |   1 -
 6 files changed, 85 insertions(+), 73 deletions(-)
Comment 11 Robert Clausecker freebsd_committer freebsd_triage 2024-09-25 06:35:02 UTC
Thank you for your contribution.