OVTCJNBLEVXDO2B6TKJY2TUSJAR6Z5QUUXCNN5WV7WGH76AD5UOQC
5FI6SBEZ6RERERUAIWQJVAY66BEZ7YQOYOUNK2DPOLRGS2X326RAC
IUH7IMWES3KQTHVWA5UNHAO7QWVCC5PQJ6VLK3RC3T4F2MS74P3AC
VO5OQW4W2656DIYYRNZ3PO7TQ4JOKQ3GVWE5ALUTYVMX3WMXJOYQC
fn change_message<C: ChangeStore>(changes: &C, change: &Hash) -> String { match changes.get_header(change) { // unwrap safe: will always be at least one line Ok(h) => h.message.lines().next().unwrap().to_string(), Err(e) => format!("[couldn't get change description: {}]", e), } }
fn change_message<C: ChangeStore>(changes: &C, change: &Hash) -> String {
match changes.get_header(change) {
// unwrap safe: will always be at least one line
Ok(h) => h.message.lines().next().unwrap().to_string(),
Err(e) => format!("[couldn't get change description: {}]", e),
}
writeln!(w, "[{}] {}", i, dep.to_base32())?;
writeln!( w, "[{}] {} # {}", i, dep.to_base32(), change_message(changes, dep) )?;
writeln!(
w,
"[{}] {} # {}",
i,
dep.to_base32(),
change_message(changes, dep)
)?;
writeln!(w, "[{}]+{}", i, change.to_base32())?;
writeln!( w, "[{}]+{} # {}", i, change.to_base32(), change_message(changes, &change) )?;
"[{}]+{} # {}",
change.to_base32(),
change_message(changes, &change)
writeln!(w, "[*] {}", dep.to_base32())?;
writeln!( w, "[*] {} # {}", dep.to_base32(), change_message(changes, dep) )?;
"[*] {} # {}",
}pub fn parse_comment(i: &str) -> IResult<&str, ()> { let (i, _) = char('#')(i)?; let (i, _) = take_until("\n")(i)?; Ok((i, ()))
pub fn parse_comment(i: &str) -> IResult<&str, ()> {
let (i, _) = char('#')(i)?;
let (i, _) = take_until("\n")(i)?;
Ok((i, ()))
pair(space0, char('\n')),
tuple((space0, opt(parse_comment), char('\n'))),