From 34535086d291a648f10fb2966cfe7899a774c2fe Mon Sep 17 00:00:00 2001 From: tibvdm Date: Tue, 23 Apr 2024 11:45:32 +0200 Subject: [PATCH] maintest for new build --- fa-compression/src/main.rs | 27 +-------------------------- 1 file changed, 1 insertion(+), 26 deletions(-) diff --git a/fa-compression/src/main.rs b/fa-compression/src/main.rs index af7ccbc..a1d8db9 100644 --- a/fa-compression/src/main.rs +++ b/fa-compression/src/main.rs @@ -14,33 +14,8 @@ pub fn main() { let line = line.unwrap(); let splitted_line = line.split("\t").collect::>(); - let ec = splitted_line[7].replace("n", ""); - let go = splitted_line[8]; - let interpro = splitted_line[9]; - - let mut string = String::new(); - if !ec.is_empty() { - let ec_corrected = ec.split(';').map(|s| format!("EC:{}", s)).collect::>().join(";"); - string.push_str(&ec_corrected); - string.push(';'); - } - if !go.is_empty() { - string.push_str(go); - string.push(';'); - } - if !interpro.is_empty() { - let interpro_corrected = interpro.split(';').map(|s| format!("IPR:{}", s)).collect::>().join(";"); - string.push_str(&interpro_corrected); - string.push(';'); - } - if !string.is_empty() { - string.pop(); - } - - //eprintln!("{}", string); - writer.write_all(format!("{}\t{}\t{}\t", splitted_line[1], splitted_line[3], splitted_line[6]).as_bytes()).unwrap(); - writer.write_all(encode(&string).as_slice()).unwrap(); + writer.write_all(encode(&splitted_line[7]).as_slice()).unwrap(); writer.write_all(b"\n").unwrap(); } }