From de0bdc51173e246262a09e1b9825f38e07069d15 Mon Sep 17 00:00:00 2001 From: "F. Malina" Date: Sat, 24 Oct 2026 09:56:52 +0200 Subject: [PATCH] docs: fix pretty printing nginx configure arguments Updated the command to use sed for extracting the configuration from the output of 'nginx -V' instead of awk. Awk version breaks on colons leading to unmatched quotes. ''' $ nginx -V 2>&1 | awk -F: '/configure arguments/ {print $2}' | xargs -n1 xargs: unmatched single quote; by default quotes are special to xargs unless you use the -0 option --with-cc-opt=-g... ''' Tested on Debian --- .../basic-functionality/managing-configuration-files.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/nginx/admin-guide/basic-functionality/managing-configuration-files.md b/content/nginx/admin-guide/basic-functionality/managing-configuration-files.md index 0fe572a89..b266dcb3c 100644 --- a/content/nginx/admin-guide/basic-functionality/managing-configuration-files.md +++ b/content/nginx/admin-guide/basic-functionality/managing-configuration-files.md @@ -17,7 +17,7 @@ NGINX Open Source: location depends on the package system used to install NGINX You can verify the exact configuration file path with the `--conf-path=` parameter in the output of the `nginx -V` command: ```shell - nginx -V 2>&1 | awk -F: '/configure arguments/ {print $2}' | xargs -n1 + nginx -V 2>&1 | sed -n 's/^configure arguments: *//p' | xargs -n1 ``` Sample output: