gitea源码

1234567891011121314151617181920212223
  1. // Copyright 2023 The Gitea Authors. All rights reserved.
  2. // SPDX-License-Identifier: MIT
  3. package v1_22
  4. import (
  5. "time"
  6. "xorm.io/xorm"
  7. )
  8. func AddPreviousDurationToActionRun(x *xorm.Engine) error {
  9. type ActionRun struct {
  10. PreviousDuration time.Duration
  11. }
  12. _, err := x.SyncWithOptions(xorm.SyncOptions{
  13. IgnoreIndices: true,
  14. IgnoreConstrains: true,
  15. }, &ActionRun{})
  16. return err
  17. }