Parse gecos csv
This commit is contained in:
parent
8645382110
commit
8a9d83632e
2 changed files with 6 additions and 3 deletions
|
|
@ -508,8 +508,9 @@ impl cosmic::Application for App {
|
||||||
}
|
}
|
||||||
match &user.gecos {
|
match &user.gecos {
|
||||||
Some(gecos) => {
|
Some(gecos) => {
|
||||||
|
let full_name = gecos.split(",").next().unwrap_or("");
|
||||||
column = column.push(
|
column = column.push(
|
||||||
widget::container(widget::text::title4(gecos))
|
widget::container(widget::text::title4(full_name))
|
||||||
.width(Length::Fill)
|
.width(Length::Fill)
|
||||||
.align_x(alignment::Horizontal::Center),
|
.align_x(alignment::Horizontal::Center),
|
||||||
);
|
);
|
||||||
|
|
@ -541,8 +542,9 @@ impl cosmic::Application for App {
|
||||||
}
|
}
|
||||||
match &user.gecos {
|
match &user.gecos {
|
||||||
Some(gecos) => {
|
Some(gecos) => {
|
||||||
|
let full_name = gecos.split(",").next().unwrap_or("");
|
||||||
column = column.push(
|
column = column.push(
|
||||||
widget::container(widget::text::title4(gecos))
|
widget::container(widget::text::title4(full_name))
|
||||||
.width(Length::Fill)
|
.width(Length::Fill)
|
||||||
.align_x(alignment::Horizontal::Center),
|
.align_x(alignment::Horizontal::Center),
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -529,8 +529,9 @@ impl cosmic::Application for App {
|
||||||
}
|
}
|
||||||
match &self.flags.current_user.gecos {
|
match &self.flags.current_user.gecos {
|
||||||
Some(gecos) => {
|
Some(gecos) => {
|
||||||
|
let full_name = gecos.split(",").next().unwrap_or("");
|
||||||
column = column.push(
|
column = column.push(
|
||||||
widget::container(widget::text::title4(gecos))
|
widget::container(widget::text::title4(full_name))
|
||||||
.width(Length::Fill)
|
.width(Length::Fill)
|
||||||
.align_x(alignment::Horizontal::Center),
|
.align_x(alignment::Horizontal::Center),
|
||||||
);
|
);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue