mirror of
https://code.forgejo.org/forgejo/runner.git
synced 2025-08-06 17:40:58 +00:00
So that it can be used as a package. Not useful right away, but a precondition to merge the ACT repository into the runner repository. Reviewed-on: https://code.forgejo.org/forgejo/runner/pulls/747 Reviewed-by: Michael Kriese <michael.kriese@gmx.de> Co-authored-by: Earl Warren <contact@earl-warren.org> Co-committed-by: Earl Warren <contact@earl-warren.org>
19 lines
363 B
Go
19 lines
363 B
Go
// Copyright 2022 The Gitea Authors. All rights reserved.
|
|
// SPDX-License-Identifier: MIT
|
|
|
|
package main
|
|
|
|
import (
|
|
"context"
|
|
"os/signal"
|
|
"syscall"
|
|
|
|
"code.forgejo.org/forgejo/runner/internal/app/cmd"
|
|
)
|
|
|
|
func main() {
|
|
ctx, stop := signal.NotifyContext(context.Background(), syscall.SIGINT, syscall.SIGTERM)
|
|
defer stop()
|
|
// run the command
|
|
cmd.Execute(ctx)
|
|
}
|