feat(cli): added commands for interacting with build logs
This commit is contained in:
parent
fa6603bd45
commit
5b016df85d
7 changed files with 145 additions and 11 deletions
|
|
@ -12,6 +12,20 @@ pub:
|
|||
exit_code int [nonull]
|
||||
}
|
||||
|
||||
pub fn (bl &BuildLog) str() string {
|
||||
mut parts := [
|
||||
'id: $bl.id',
|
||||
'repo id: $bl.repo_id',
|
||||
'start time: $bl.start_time',
|
||||
'end time: $bl.end_time',
|
||||
'arch: $bl.arch',
|
||||
'exit code: $bl.exit_code',
|
||||
]
|
||||
str := parts.join('\n')
|
||||
|
||||
return str
|
||||
}
|
||||
|
||||
// get_build_logs returns all BuildLog's in the database.
|
||||
pub fn (db &VieterDb) get_build_logs() []BuildLog {
|
||||
res := sql db.conn {
|
||||
|
|
|
|||
Reference in a new issue