Bug 237389 - net-p2p/deluge-cli: /usr/local/etc/rc.d/deluge_web syntax error
Summary: net-p2p/deluge-cli: /usr/local/etc/rc.d/deluge_web syntax error
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: Ruslan Makhmatkhanov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-04-19 14:56 UTC by Delan Azabani
Modified: 2019-04-23 09:23 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (rm)


Attachments
patch for net-p2p/deluge-cli/files/deluge_web.in (489 bytes, patch)
2019-04-19 14:56 UTC, Delan Azabani
no flags Details | Diff
patch for net-p2p/deluge-cli/files/deluge_web.in (1.10 KB, patch)
2019-04-19 15:33 UTC, Delan Azabani
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Delan Azabani 2019-04-19 14:56:37 UTC
Created attachment 203800 [details]
patch for net-p2p/deluge-cli/files/deluge_web.in

ports r494743 (bug #234902) improves the deluge_web rc(8) script, but the patch wasn’t applied correctly and the `fi` on line 62 was lost, yielding this error on deluge-cli-1.3.15_8:

```
storage% service deluge_web status
/usr/local/etc/rc.d/deluge_web: 67: Syntax error: "}" unexpected (expecting "fi")
```
Comment 1 Delan Azabani 2019-04-19 15:33:37 UTC
Created attachment 203801 [details]
patch for net-p2p/deluge-cli/files/deluge_web.in

Even with my initial patch, the script doesn’t work because the parameter expansion for `$deluge_web_confdir` on line 80 tries to read `$deluge_web_home` before it’s set on line 48 via run_rc_command on line 87 (new patch attached):

```
storage% sudo service deluge_web start
/usr/local/etc/rc.d/deluge_web: WARNING: /.config/deluge is not a directory.
/usr/local/etc/rc.d/deluge_web: WARNING: failed precmd routine for deluge_web
```
Comment 2 commit-hook freebsd_committer 2019-04-23 09:19:35 UTC
A commit references this bug:

Author: rm
Date: Tue Apr 23 09:18:53 UTC 2019
New revision: 499737
URL: https://svnweb.freebsd.org/changeset/ports/499737

Log:
  net-p2p/deluge-cli: fix deluged rc-script

  PR:		237389
  Submitted by:	Delan Azabani <delan@azabani.com>
  MFH:		2019Q2

Changes:
  head/net-p2p/deluge-cli/Makefile
  head/net-p2p/deluge-cli/files/deluge_web.in
Comment 3 commit-hook freebsd_committer 2019-04-23 09:23:40 UTC
A commit references this bug:

Author: rm
Date: Tue Apr 23 09:23:06 UTC 2019
New revision: 499738
URL: https://svnweb.freebsd.org/changeset/ports/499738

Log:
  MFH: r499737

  net-p2p/deluge-cli: fix deluged rc-script

  PR:		237389
  Submitted by:	Delan Azabani <delan@azabani.com>

  Approved by:	portmgr (blanket approval)

Changes:
_U  branches/2019Q2/
  branches/2019Q2/net-p2p/deluge-cli/Makefile
  branches/2019Q2/net-p2p/deluge-cli/files/deluge_web.in
Comment 4 Ruslan Makhmatkhanov freebsd_committer 2019-04-23 09:23:59 UTC
Committed, thank you!