Skip to content

Commit c9d832b

Browse files
committed
Add yank message migration
1 parent d036f89 commit c9d832b

File tree

4 files changed

+8
-0
lines changed

4 files changed

+8
-0
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
ALTER TABLE versions DROP yank_message;
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
ALTER TABLE versions ADD COLUMN yank_message VARCHAR(255);
2+
3+
COMMENT ON COLUMN versions.yank_message IS 'message associated with a yanked version';

src/models/version.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ pub struct Version {
3131
pub rust_version: Option<String>,
3232
pub has_lib: Option<bool>,
3333
pub bin_names: Option<Vec<Option<String>>>,
34+
pub yank_message: Option<String>,
3435
}
3536

3637
impl Version {

src/schema.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -985,6 +985,9 @@ diesel::table! {
985985
has_lib -> Nullable<Bool>,
986986
/// list of the names of all detected binaries in the version. the list may be empty which indicates that no binaries were detected in the version. the column may be NULL is the version has not been analyzed yet.
987987
bin_names -> Nullable<Array<Nullable<Text>>>,
988+
/// message associated with a yanked version
989+
#[max_length = 255]
990+
yank_message -> Nullable<Varchar>,
988991
}
989992
}
990993

0 commit comments

Comments
 (0)