GitHub has officially announced that the engineering team responsible for github.com has migrated its development environment to Codespaces.
GitHub.com’s codebase is nearly 14 years old. When the first commit of github.com was pushed, Rails was only two years old, AWS was only a year old, and Azure and GCP were not yet available. In those 14 years, GitHub.com’s core repository (github/github) has received over a million commits, the vast majority of which have come from developers building and testing on macOS.
GitHub says their development platform continues to evolve, and in the last few months the engineering team has moved from macOS to using Codespaces for much of their github.com development. This is a fundamental shift in the day-to-day development process for engineers, and GitHub feels that this move has made Codespaces more powerful and they are ready for the future of github.com.
GitHub says they have invested a lot of time and effort over the long term to build an “out-of-the-box” local development environment for teams, so that new employees can quickly configure and run local instances of github.com.
The reality, however, is that despite much effort, such a development environment remains very fragile. Any seemingly innocuous change can cause the local environment to fail, and worse, this often takes hours of precious development time to recover.
Given that engineers have different development environments, and that everyone has their own particular fetishes that they are used to, GitHub was inspired by Codespaces to treat development environments like infrastructure, meaning that nothing is irreplaceable or indispensable, and that if something unexpected happens, a new one can be provided in a known good state Codespaces and then start working again.
GitHub says that the migration to Codespaces has addressed shortcomings in the existing development environment, inspired them to push further to improve the product, and enhanced the overall development experience. While this migration of the development environment ended fairly well, it was challenging at first. The GitHub.com codebase was described as using approximately 13GB of space on disk. Cloning the repository alone took about 20 minutes, and with setting up dependencies and such, bootstrapping GitHub.com’s Codespaces would take over 45 minutes.
Change is often difficult, especially for development environments.
GitHub says that they had a lot of challenges moving to Codespaces as their default development environment, but they are happy with the end result and will continue to optimize their development experience on it in the future.