mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2024-12-24 10:07:21 +02:00
24 lines
430 B
Go
24 lines
430 B
Go
|
package migrate
|
||
|
|
||
|
type Rev1 struct{}
|
||
|
|
||
|
var RenamePrivelegedToPrivileged = &Rev1{}
|
||
|
|
||
|
func (r *Rev1) Revision() int64 {
|
||
|
return 201402200603
|
||
|
}
|
||
|
|
||
|
func (r *Rev1) Up(op Operation) error {
|
||
|
_, err := op.RenameColumns("repos", map[string]string{
|
||
|
"priveleged": "privileged",
|
||
|
})
|
||
|
return err
|
||
|
}
|
||
|
|
||
|
func (r *Rev1) Down(op Operation) error {
|
||
|
_, err := op.RenameColumns("repos", map[string]string{
|
||
|
"privileged": "priveleged",
|
||
|
})
|
||
|
return err
|
||
|
}
|