Quest to see rust project in game of trees
Had a rust project and wanted to see game of trees working.
I made backup copy of my rust project before starting this to be safe.
I have no ideal how .git folder ended up in my rust project unless its used internally ?
Remove the .git folder in rust project if its there. This is very important because the g.o.t. don't like .git in your work tree. You can leave .gitignore.
~/ is your home directory /home/someone
// -p make all directories
mkdir -p ~/got-repos/bin
// -b stands for branch
gotadmin init -b main ~/got-repos/bin/project.git
open a text editor and save got.conf file into ~/got-repos/bin/project.git containing
author "your name <someone@somewhere.com>"
space between your name and email is important.
// -m stands for message
// -r repository directory
// . means all
got import -m "Setup" -r ~/got-repos/bin/project.git ~/rust_project/.
// -E file already exist
got checkout -E ~/got-repos/bin/project.git
Now you should see a new directory in ~/got-repos/bin/project folder next to your project.git folder containing your Cargo.toml and src/main.rs.
While inside this project folder run ls -a you should see .got directory
got commands should be run in this directory: ex. got add src/another.rs
got status .got show list of information am still learning.
New to git and g.o.t. this was neat seeing it track changes in the code and showing the format changes.