mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
write header only once
This commit is contained in:
parent
c855b14b14
commit
c956ca1863
@ -210,6 +210,12 @@ pub fn test_specific_localizations(
|
||||
let output = path.root_path().join("translation_analysis.csv");
|
||||
let mut f = std::fs::File::create(output).expect("couldn't write csv file");
|
||||
|
||||
use std::io::Write;
|
||||
writeln!(
|
||||
f,
|
||||
"country_code,file_name,translation_key,status,git_commit"
|
||||
)
|
||||
.unwrap();
|
||||
//printing
|
||||
for (language_identifier, (state_map, stats)) in &analysis {
|
||||
if csv_enabled {
|
||||
|
@ -146,12 +146,6 @@ pub(crate) fn print_translation_stats(
|
||||
}
|
||||
|
||||
pub(crate) fn print_csv_stats<W: std::io::Write>(state_map: &LocalizationAnalysis, output: &mut W) {
|
||||
writeln!(
|
||||
output,
|
||||
"country_code,file_name,translation_key,status,git_commit"
|
||||
)
|
||||
.unwrap();
|
||||
|
||||
for state in &ALL_LOCALIZATION_STATES {
|
||||
state_map.csv(*state, output);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user