

Google code went down a few years ago, not sure if anyone predicted that. Also, what about using devices with unsigned drivers? For old unmaintained devices the logical thing is to dedicate an XP machine for those. While this is pretty specific it can be indicative of the things to come. An example: I cannot maintain an old Windows Phone 7 project because the MS tools require me to build for the latest WP iteration and the new tools only run on windows 10. One VM per project is a bit overkill, a better approach is to build a new VM every few years or so when the tools and OSs change significantly. For example my last big client had the USB ports blocked on all computers but they were accessible through the VM. Probably because they don't want to deal with the hassle of securing, storing and transferring gigabytes on the slow corporate network.

Back to the topic of VMs: I use them a lot for my personal projects but I find that in large companies they are seldom used.

This is why I'm advocating that, for a project which you don't want to constantly maintain, you keep a local copy of all the dependencies. However, after some years I find that some library updates break existing projects or the needed dependencies cannot be found. For Java (offtopic, but a bit related) you have the choice of using Maven repositories - which is nice when it works - and the libraries are usually more mature. Sometimes they have bugs or unperformant code that needs to be modified, other times you cannot just rely on free hosting to be available 3 years from now.

As an extra step, for all my Arduino and Javascript project,s I'm pushing the small 3rd party libraries as well. I'm also pushing datasheets to my git repositories, as well as all measurements, notes, prototype photos, everything. Debuggers can be attached to VMs, most USB devices can be redirected to the VM, at least Oracle VBox and VMWare (the ones I'm using).
