use anyhow::Result;
use crate::test_utils::TestGitRepository;
pub fn create_files_with_gitignore(repo: &TestGitRepository) -> Result<()> {
repo.create_file(".gitignore", "target/\n*.log\n.DS_Store\ntmp/\n")?;
repo.create_file(
"src/main.rs",
"fn main() {\n println!(\"Hello, world!\");\n}\n",
)?;
repo.create_file(
"Cargo.toml",
"[package]\nname = \"test\"\nversion = \"0.1.0\"\n",
)?;
repo.stage_all()?;
repo.commit("Add initial files")?;
repo.create_file("src/lib.rs", "pub fn lib_function() {}\n")?;
repo.create_file("README.md", "# Test Project\n")?;
repo.create_file("debug.log", "Debug log content\n")?;
repo.create_file(".DS_Store", "Mac system file\n")?;
repo.create_file("target/debug/binary", "Binary content\n")?;
repo.create_file("tmp/temp.txt", "Temporary file\n")?;
repo.create_file(".tsk/config.json", "{\"test\": true}\n")?;
repo.create_file(".tsk/tsk.toml", "stack = \"rust\"\n")?;
Ok(())
}