Question on sourcetree folder structure

This can be considered a continuation of the previous topic. Before anyone answers this, I have played around with sourcetree and git to know this: Once you remove the .git folder, you can re-create everything in sourcetree. I checked the internet and cannot find any websites. This is also not in the developer’s atlassian website. The question is:

Does anyone know the full structure of .git folder and how sourcetree reads them?
Can they be easily edited without damaging the records?

Hi Anonymous,

As this is a bit beyond the scope of the course i cannot really suggest anything of help here.

What i can suggest is maybe jumping into our discord server and asking as well in the #unity channel or #dev may be an option.

Its a little early in the day so you may find more active people there during the evening depending on your time zone.

It gets busy in there so if you dont get a reply right away trying helping with some smaller problems other students are having to build up conversations and then reintroduce your problem when people are more interactive.

I think this may also aid your learning as well as the forums here.

Discord is free to use and you can use the website, pc version or an app on your phone and i also admin the server so you know its a safe secure environment we keep to PG-13 :slight_smile:

Hope that you find an answer to your question and here is an invite to the discord server

I can’t get into the discord without a server OR i can’t use my existing email address.

It might be that your email address is already in use with discord?
You may need to make an account first or login to the account you have for discord (If email is already in use you may have an account already)
The account is with discord not with us if that helps :slight_smile:

Once you have logged in then the above link should get you in.

Let me know if you have any further issues and the error that occurs.

Marc,
Leave this for now. It’s better i complete the course then if I have time, I’ll check discord and sourcetree. I already have pending problems in this course. Sourcetree can wait. And if this topic is closed, I’ll open a new one.

1 Like

The .git folder is literally the git repository; all the indexes, history, structure of branches and tags, and the changes over time to the files themselves (broken up into chunks and assigned pseudo-random filenames in the form of a hash of the content it represents).

Simply the presence or lack of this subfolder identifies the current folder as a “git repository”. It’s one with it, and not one without it.

You should neither delete this or edit it directly, as doing so can mean an unrecoverable loss of that history unless there is another copy of the same git repo elsewhere.

Any edits to the .git folder contents should be done using the git command line tool or a UI like sourcetree. It’s rare to do otherwise, and even then you typically only alter a simple plain-text config file (which by and large the tools can process), and never get into the guts of the repo structure itself.

Just so you know, SourceTree is a GUI that drives the “git” command line under the hood. Even SourceTree by and large is clueless about how a .git folder is structured. Instead it relies upon issuing git commands behind the scenes and then reporting the results it outputs back to you, in a prettier format than the git command is generally capable of doing.

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms