LinkedIn Sourceforge

Vincent's Blog

Pleasure in the job puts perfection in the work (Aristote)

How I've transferred my projects from git to got while keeping all history

Posted on 2026-02-13 22:43:00 from Vincent in got

In this blog, I explain what I did to transfer my development projects from git on my brand new got server. Since got is based on git repository, there is nearly nothing specific to do.

Just migrate your .git folder in your got repository and it will work.


Photo by Ashley Diane Worsham on Unsplash

Migrating a Git Repository to Got (Game of Trees)

Recently, I wanted to import one of my projects from SourceForge into Got, OpenBSD's alternative version control system. While Got is designed to work seamlessly with Git repositories, I encountered an SSL issue that required a simple workaround.

The Challenge

Got is built to be compatible with Git's repository format, which means you should be able to clone any Git repository directly using got clone. However, when I tried to clone my log2table project from SourceForge, I hit an SSL error:

got clone https://git.code.sf.net/p/log2table/code

This resulted in:

got-fetch-http: bufio_read: read failed: error:0A000126:SSL routines::unexpected eof while reading
got-fetch-pack: unexpected end of file
got: unexpected end of file

The error indicates that Got's HTTP client encountered an unexpected SSL termination, likely due to compatibility issues with SourceForge's SSL implementation.

The Solution: A Two-Step Approach

The workaround is straightforward: use Git to clone the repository first, then use Got to create a work tree from it.

Step 1: Clone with Git

# on the server machine where gotd and gotwebd are running
cd /tmp 
git clone https://git.code.sf.net/p/log2table/code git_log2table

Git successfully cloned the repository without any SSL issues.

Step 2: Move the repository to his final destination

Move the repository to his final destination on my dev machine

mv git_log2table/.git /path/to/repos/log2table.git

Make sure that the repo has the correct permissions:

chmod -R 750 /path/to/repos/log2table.git
chown -R _gotd:_gotd /path/to/the/repos/log2table.git

At this stage, we do not need /tmp/git_log2table any more.

Step 3: Adapt /etc/gotd.conf

Now we have to adapt our /etc/gotd.conf by adding this somewhere in the file:

repository "log2table" {
    path "/path/to/repos/log2table.git"
    permit ro anon
    permit rw myuser
}

Where anon is anonymous user as created in this post and myuser is my normal user I'm using to manage the server.

rcctl restart gotd

There are no other updates to perform for gotwebd or nginx/httpd.

Step 4: Create a Got working environment

# on the dev machine
cd ~/got/
got clone ssh://myuser@repo.vincentdelft.be/log2table
cd ~/dev/
got checkout ~/got/log2table.git

This command creates a Got work tree from the Git repository. Got checked out all files.

Step 5: Verify the Import

cd ~/project/log2table
got log

Running got log confirmed that the entire Git history was preserved, showing all three commits from the original repository.

Before doing commit, make sure you have well the GOT_AUTHOR variable associated with your name and email.

export GOT_AUTHOR="vincent delft <vincent.delft@gmail.com>"

Now you are ready to send your changes to the server by doing:

cd ~/project/log2table
got send

Key Takeaways

  • Got and Git are compatible: Since Got uses the same underlying object format as Git, you can seamlessly work with Git repositories using Got commands
  • The history is fully preserved: All commits, branches, and metadata are maintained when importing from Git
  • Workarounds exist: When Got's network tools encounter issues, you can always fall back to Git for the initial clone
  • Best of both worlds: After the initial import, you can use Got's cleaner command interface while maintaining full Git compatibility

Why This Works

Got isn't a completely separate version control system. The repository format remains identical, which means:

  • You can switch between Git and Got at any time
  • All Git history is preserved and accessible

This compatibility makes Got an excellent choice for users who want a simpler, more BSD-focused version control tool without sacrificing access to the vast ecosystem of Git repositories.

Conclusion

While Got's direct clone functionality had trouble with SourceForge's SSL setup, the two-step process of cloning with Git and then checking out with Got worked perfectly. The entire history of my project is now accessible through Got, and I can continue development using Got's streamlined command set.

If you're interested in exploring alternatives to Git, Got is worth trying—and as this experience shows, integrating it with existing Git workflows is straightforward.



0, 0
displayed: 115



What is the first letter of the word Python?