Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
perun-proxy-utils
Manage
Activity
Members
Labels
Plan
Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Perun
Perun ProxyIdP
perun-proxy-utils
Commits
567b9056
Commit
567b9056
authored
6 years ago
by
Pavel Vyskočil
Committed by
Pavel Vyskočil
5 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Added php_syntax_check.sh
parent
fa46b51f
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
README.md
+8
-1
8 additions, 1 deletion
README.md
php_syntax_check.sh
+25
-0
25 additions, 0 deletions
php_syntax_check.sh
with
33 additions
and
1 deletion
README.md
+
8
−
1
View file @
567b9056
...
...
@@ -3,13 +3,20 @@
## List of Local scripts
Local scripts are located in /usr/lib/check_mk/local/
###
git_pull
_check.sh
###
php_syntax
_check.sh
*
Attributes to be filled:
<pre>
# List of paths to check separated by space
paths=""
</pre>
### git_pull_check.sh
*
Attributes to be filled:
<pre>
# The root directory to check
dir=""
</pre>
### services_running_check.sh
*
Attributes to be filled:
<pre>
...
...
This diff is collapsed.
Click to expand it.
php_syntax_check.sh
0 → 100644
+
25
−
0
View file @
567b9056
#!/bin/bash
#The root directory to check
dir
=
"/etc/simplesamlphp"
cd
$dir
paths
=
$(
find
.
-type
f
-name
"*.php"
)
globalResult
=
""
for
path
in
$paths
do
if
[[
-f
$path
]]
;
then
result
=
$(
php
-l
$path
2>&1
)
if
[[
!
$result
=
~ ^No.syntax.errors.
*
$
]]
;
then
globalResult+
=
"
$result
| "
fi
fi
done
if
[[
-z
$globalResult
]]
;
then
echo
"0 php_syntax_check - OK"
else
echo
"2 php_syntax_check -
$globalResult
"
fi
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment