Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions pkg_comp.conf.5
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,10 @@ In other words, they are run under a shell configured with
.Pp
The following hooks can be defined:
.Bl -tag -width post_build_hookXX
.It Fn post_build_hook
Function executed right after the set of packages have been built by the
.Sq build
command.
.It Fn post_fetch_hook
Function executed right after all source trees have been updated by the
.Sq fetch
Expand Down
3 changes: 3 additions & 0 deletions pkg_comp.sh
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ pkg_comp_set_defaults() {
shtk_config_set UPDATE_SOURCES "true"
shtk_config_set VARBASE "/var"

post_build_hook() { true; }
post_fetch_hook() { true; }
}

Expand Down Expand Up @@ -500,6 +501,8 @@ pkg_comp_build() {
run_sandboxctl run /pkg_comp/pbulk/bin/bulkbuild || \
shtk_cli_error "bulkbuild failed; see ${root}/pkg_comp/work/bulklog/" \
"for possible details"

shtk_config_run_hook post_build_hook
}


Expand Down