Git, yes. Github, no. Github has many Github-only features such as "continuous integration". Those need to become portable, so you can run your builds on AWS or Hurricane Electric as desired.
It's become dangerous for open source to rely on anyone who can cut off your air supply. Look at the current flap over Red Hat.
I haven't personally done it much, but it seems like moving CI should be relatively straightforward as long as your pipelines are mostly just npm/make/cargo/bash/etc scripts. If all of your actual logic is in your build system, the bit of yaml that defines the infrastructure on a particular CI platform shouldn't be very complicated to move.
"Run this script in this container and cache these outputs."
It's become dangerous for open source to rely on anyone who can cut off your air supply. Look at the current flap over Red Hat.