It was a warrant issued by a Spanish court that Github legally had to comply with. You can be angry at the court for issuing such a warrant but you can't be angry at Github for complying. They are not above the law, even if they may disagree with it.
US companies have no legal obligation to comply with a Spanish court order. A MLAT must be arranged and approved before US companies have a legal obligation. GitHub's compliance with the court order was voluntarily and discretionary; just like how if the North Korea courts told me to shut down my site, you have every right to say no.
Sure while they're just a US company. What happens when they open an office in Spain?