Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Libre
Nginx Config Tools
Commits
544beb35
Commit
544beb35
authored
Mar 23, 2020
by
Michał Woźniak
Browse files
creating the tempdir only when needed now
parent
9da6e7ed
Changes
1
Hide whitespace changes
Inline
Side-by-side
nginx-conf-flatten
View file @
544beb35
...
...
@@ -324,17 +324,18 @@ debug " config directory: 'NGINX_CONFIG_DIR'"
cd
"
$NGINX_CONFIG_DIR
"
TMP_WORKDIR
=
"
$(
mktemp
-d
/tmp/nginx-conf-flatten.XXXX
)
"
debug
"+-- TMP_WORKDIR:
$TMP_WORKDIR
"
# the list of files whose includes we have not copied yet
NGINX_CONFIG_ELEMENTS
=(
"
$NGINX_CONFIG
"
)
# what are we doing, eh?
if
[
"
$1
"
==
"flatten"
]
;
then
TMP_WORKDIR
=
"
$(
mktemp
-d
/tmp/nginx-conf-flatten.XXXX
)
"
debug
"+-- TMP_WORKDIR:
$TMP_WORKDIR
"
nginx-flatten
elif
[
"
$1
"
==
"clean-directory"
]
;
then
TMP_WORKDIR
=
"
$(
mktemp
-d
/tmp/nginx-conf-flatten.XXXX
)
"
debug
"+-- TMP_WORKDIR:
$TMP_WORKDIR
"
nginx-clean-directory
elif
[
"
$1
"
==
"tree"
]
;
then
nginx-tree
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment