nextcloud / nextcloud/notify_push
Use 'command -v' over 'which'
Open
Nobody has claimed this yet.
bug
- Dominant language
- Rust
- Stars
- 344
- Forks
- 64
- Avg merge
- 2d 10h
- Merged PRs (30d)
- 5
Description
SetupWizard calls which on systemctl and getenforce (https://github.com/nextcloud/notify_push/blob/main/lib/SetupWizard.php#L75), but which isn't necessary installed. Wasn't on my server.
Usually command -v is preferred in scripting, it's at least POSIX.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in lib/SetupWizard.php around line 75, where SetupWizard checks for systemctl and getenforce with which. Update those checks to use the requested POSIX-supported command lookup, then verify the setup path no longer depends on which being installed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php, shell
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 55/100