Skip to content
Snippets Groups Projects
Commit b0e7a176 authored by iliya.saroukha's avatar iliya.saroukha
Browse files

removed redundant prints

parent f5500096
Branches
No related tags found
No related merge requests found
mod c_templates; mod c_templates;
use ptree::{self, print_tree, print_tree_with, TreeBuilder}; use ptree::{print_tree, TreeBuilder};
use std::fs::File; use std::fs::File;
use std::io::{stdin, stdout, Write}; use std::io::{stdin, stdout, Write};
use std::process::Command; use std::process::Command;
...@@ -75,8 +75,7 @@ fn create_project() { ...@@ -75,8 +75,7 @@ fn create_project() {
} }
fn algo_tree() { fn algo_tree() {
println!(); let tree = TreeBuilder::new("data_struct".to_string())
let tree = TreeBuilder::new("name_of_project".to_string())
.begin_child("struct".to_string()) .begin_child("struct".to_string())
.add_empty_child("struct.h".to_string()) .add_empty_child("struct.h".to_string())
.add_empty_child("struct.c".to_string()) .add_empty_child("struct.c".to_string())
...@@ -89,23 +88,13 @@ fn algo_tree() { ...@@ -89,23 +88,13 @@ fn algo_tree() {
} }
fn exam_tree() { fn exam_tree() {
println!();
let tree = TreeBuilder::new("prog_seq_exam_<month>".to_string()) let tree = TreeBuilder::new("prog_seq_exam_<month>".to_string())
.begin_child("ex1".to_string()) .begin_child("ex1".to_string())
.add_empty_child("ex1.c".to_string()) .add_empty_child("ex1.c".to_string())
.add_empty_child("Makefile".to_string()) .add_empty_child("Makefile".to_string())
.end_child() .end_child()
.begin_child("ex2".to_string()) .begin_child("ex...".to_string())
.add_empty_child("ex2.c".to_string()) .add_empty_child("etc...".to_string())
.add_empty_child("Makefile".to_string())
.end_child()
.begin_child("ex3".to_string())
.add_empty_child("ex3.c".to_string())
.add_empty_child("Makefile".to_string())
.end_child()
.begin_child("ex4".to_string())
.add_empty_child("ex4.c".to_string())
.add_empty_child("Makefile".to_string())
.end_child() .end_child()
.build(); .build();
...@@ -128,7 +117,6 @@ fn print_menu() { ...@@ -128,7 +117,6 @@ fn print_menu() {
algo_tree(); algo_tree();
println!("2) Exam"); println!("2) Exam");
exam_tree(); exam_tree();
println!();
} }
fn main() { fn main() {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment