warning about maxdepth option due to find syntax #1982

Closed
opened 2026-04-05 16:42:00 +02:00 by MrUnknownDE · 0 comments
Owner

Originally created by @luckman212 on 4/8/2023

ee4d49efaf/preinstall.sh (L178)

I get this warning when running preinstall.sh on a fresh Debian 11 system

find: warning: you have specified the global option -maxdepth after the argument -type, but global options are not positional, i.e., -maxdepth affects tests specified before it as well as those specified after it.  Please specify global options before other arguments.

I think the syntax should be

find . -maxdepth 1 -type d
*Originally created by @luckman212 on 4/8/2023* https://github.com/OneUptime/oneuptime/blob/ee4d49efafbbebd948541e579ed116b1de67d7bc/preinstall.sh#L178 I get this warning when running `preinstall.sh` on a fresh Debian 11 system ``` find: warning: you have specified the global option -maxdepth after the argument -type, but global options are not positional, i.e., -maxdepth affects tests specified before it as well as those specified after it. Please specify global options before other arguments. ``` I think the syntax should be ```shell find . -maxdepth 1 -type d ```
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github/oneuptime#1982