code.gitea.io/gitea@v1.21.7/models/migrations/v1_21/v265.go (about) 1 // Copyright 2023 The Gitea Authors. All rights reserved. 2 // SPDX-License-Identifier: MIT 3 4 package v1_21 //nolint 5 6 import ( 7 "xorm.io/xorm" 8 ) 9 10 func AlterActionArtifactTable(x *xorm.Engine) error { 11 // ActionArtifact is a file that is stored in the artifact storage. 12 type ActionArtifact struct { 13 RunID int64 `xorm:"index unique(runid_name_path)"` // The run id of the artifact 14 ArtifactPath string `xorm:"index unique(runid_name_path)"` // The path to the artifact when runner uploads it 15 ArtifactName string `xorm:"index unique(runid_name_path)"` // The name of the artifact when 16 } 17 18 return x.Sync(new(ActionArtifact)) 19 }