1
1
mirror of https://github.com/go-gitea/gitea synced 2025-11-01 11:58:25 +00:00

refactor: rename to actions

This commit is contained in:
Jason Song
2022-12-06 15:16:25 +08:00
parent 56368f3963
commit 223782ca4c
50 changed files with 247 additions and 247 deletions

View File

@@ -126,8 +126,8 @@ var (
// Packages represents packages storage
Packages ObjectStorage = uninitializedStorage
// Bots represents bots storage
Bots ObjectStorage = uninitializedStorage
// Actions represents actions storage
Actions ObjectStorage = uninitializedStorage
)
// Init init the stoarge
@@ -139,7 +139,7 @@ func Init() error {
initLFS,
initRepoArchives,
initPackages,
initBots,
initActions,
} {
if err := f(); err != nil {
return err
@@ -209,12 +209,12 @@ func initPackages() (err error) {
return err
}
func initBots() (err error) {
if !setting.Bots.Enabled {
Bots = discardStorage("Bots isn't enabled")
func initActions() (err error) {
if !setting.Actions.Enabled {
Actions = discardStorage("Actions isn't enabled")
return nil
}
log.Info("Initialising Bots storage with type: %s", setting.Bots.Storage.Type)
Bots, err = NewStorage(setting.Bots.Storage.Type, &setting.Bots.Storage)
log.Info("Initialising Actions storage with type: %s", setting.Actions.Storage.Type)
Actions, err = NewStorage(setting.Actions.Storage.Type, &setting.Actions.Storage)
return err
}