Skip to content

Commit

Permalink
feat(updateManager): use info_tag desc for the name (#1959)
Browse files Browse the repository at this point in the history
* feat(updateManager): use info_tag desc for the name

Signed-off-by: Stefan Dej <[email protected]>

* fix: fix output when description is only desc=

Signed-off-by: Stefan Dej <[email protected]>

---------

Signed-off-by: Stefan Dej <[email protected]>
  • Loading branch information
meteyou authored Aug 7, 2024
1 parent e75a7aa commit f856cac
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/components/panels/Machine/UpdatePanel/Entry.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<div>
<v-row class="py-2">
<v-col class="pl-6">
<strong>{{ repo.name }}</strong>
<strong>{{ name }}</strong>
<br />
<template v-if="type === 'git_repo' && commitsBehind.length">
<a class="info--text cursor--pointer" @click="boolShowCommitList = true">
Expand Down Expand Up @@ -159,6 +159,11 @@ export default class UpdatePanelEntry extends Mixins(BaseMixin) {
@Prop({ required: true }) readonly repo!: ServerUpdateManagerStateGitRepo
get name() {
const info_tags = this.repo.info_tags ?? []
const description = info_tags.find((tag) => tag.startsWith('desc='))
if (description && description.trim() !== 'desc=') return description.replace('desc=', '').trim()
return this.repo.name ?? 'UNKNOWN'
}
Expand Down

0 comments on commit f856cac

Please sign in to comment.