Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
R
RIOT
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
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
cm-projects
RIOT
Commits
5810e10d
Commit
5810e10d
authored
6 years ago
by
Kaspar Schleiser
Browse files
Options
Downloads
Patches
Plain Diff
murdock: add hook support
parent
dc8c983d
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
.murdock
+17
-0
17 additions, 0 deletions
.murdock
with
17 additions
and
0 deletions
.murdock
+
17
−
0
View file @
5810e10d
...
...
@@ -27,6 +27,22 @@ error() {
exit
1
}
# if MURDOCK_HOOK is set, this function will execute it and pass on all it's
# parameters. should the hook script exit with negative exit code, hook() makes
# this script exit with error, too.
# hook() will be called from different locations of this script.
# currently, the only caller is "run_test", which calls "hook run_test_pre".
# More hooks will be added as needed.
hook
()
{
if
[
-n
"
${
MURDOCK_HOOK
}
"
]
;
then
echo
"- executing hook
$1
"
"
${
MURDOCK_HOOK
}
"
"
$@
"
||
{
error
"
$0
: hook
\"
${
MURDOCK_HOOK
}
$@
\"
failed!"
}
echo
"- hook
$1
finished"
fi
}
# true if word "$1" is in list of words "$2", false otherwise
# uses grep -w, thus only alphanum and "_" count as word bounderies
# (word "def" matches "abc-def")
...
...
@@ -175,6 +191,7 @@ run_test() {
local
board
=
$2
print_worker
echo
"-- executing tests for
$appdir
on
$board
:"
hook run_test_pre
BOARD
=
$board
make
-C
$appdir
flash-only
test
}
...
...
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