changing output formating
This commit is contained in:
parent
4f0170f8fd
commit
92e08c60f8
14
src/main.rs
14
src/main.rs
@ -66,9 +66,9 @@ impl Env {
|
|||||||
print!("{:?} :", key);
|
print!("{:?} :", key);
|
||||||
match val {
|
match val {
|
||||||
Value::Tags(tags) => {
|
Value::Tags(tags) => {
|
||||||
print!("\"[");
|
print!("[");
|
||||||
fmt_tags(*tags);
|
fmt_tags(*tags);
|
||||||
print!("]\"");
|
print!("]");
|
||||||
}
|
}
|
||||||
Value::Title(title) => {
|
Value::Title(title) => {
|
||||||
print!("{:?}", title);
|
print!("{:?}", title);
|
||||||
@ -150,9 +150,9 @@ fn main() {
|
|||||||
{
|
{
|
||||||
if let Some(status_manager) = &env.status_manager {
|
if let Some(status_manager) = &env.status_manager {
|
||||||
make = make.replace(' ', "").to_string();
|
make = make.replace(' ', "").to_string();
|
||||||
let tags_key = format!("Tags.{}", make);
|
let tags_key = format!("Tags_{}", make);
|
||||||
let urgent_key = format!("UrgentTags.{}", make);
|
let urgent_key = format!("UrgentTags_{}", make);
|
||||||
let views_key = format!("ViewsTags.{}", make);
|
let views_key = format!("ViewsTags_{}", make);
|
||||||
let output_status =
|
let output_status =
|
||||||
status_manager.get_river_output_status(&output);
|
status_manager.get_river_output_status(&output);
|
||||||
output_status.quick_assign(move |_, event, mut env| {
|
output_status.quick_assign(move |_, event, mut env| {
|
||||||
@ -268,11 +268,11 @@ fn fmt_tags(tagmask: u32) {
|
|||||||
tag += 1;
|
tag += 1;
|
||||||
if current != tagmask && (tagmask / current) % 2 != 0 {
|
if current != tagmask && (tagmask / current) % 2 != 0 {
|
||||||
fmt_tags(tagmask - current);
|
fmt_tags(tagmask - current);
|
||||||
print!(" ");
|
print!(", ");
|
||||||
break;
|
break;
|
||||||
} else if tag == 32 {
|
} else if tag == 32 {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
print!("{}", tag);
|
print!("\"{}\"", tag);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user