The general trend at the end appeared to be that, but the reality was far more complicated. There were elements on both sides that espoused the Sonno-Joi ideology, and there were elements that were trying to get their respective side to adopt Western technology. A look through the major incidents of the Bakamatsu era shows that the perpetrators were often from domains that would end up on both sides of the conflict.
The assassination of Ii Naosuke in 1860 was committed by a mixed group of Mito and Satsuma samurai. While Satsuma was a hotbed for Sonno-Joi sentiment for much of this era, Mito stands out at a glance because that region was one of the inner houses of the Tokugawa and the home of the last Shogun, Yoshinobu. Mito, despite being a Tokugawa loyalist province, would see a huge amount of anti-foreign sentiment through the era, and, although it would not participate in the Choshu-Satsuma alliance of the Boshin War, an anti-foreign rebellion would break out in 1864 that the Shogunate would have to crush.
The Shinsengumi are another nuanced example. They started as a group of ronin in Edo commissioned to protect Shogunate interests in Kyoto, but their organizers were very much driven by Sonno-Joi. Even after they morphed into the Shinsengumi and became more of a Tokugawa loyalist secret police than the protectors of Kyoto they were officially commissioned as, they were hardly pro-foreign, and in fact continued to espouse Sonno-Joi ideology and rely on the supposed superiority of traditional methods until they were faced with the disastrous defeats at Toba-Fushimi and Koshu-Katsunuma. Only once the Imperial forces were at the gates of Edo that the remnants of the Shinsengumi that remained Tokugawa loyalists would finally attempt to adopt Western methods and weapons.
Taking a step back from specific incidents and looking at the events of the Boshin War, one sees that the Sonno-Joi sentiment, while likely truly held by many, was more of a means to an end for the Satsuma and Choshu forces leading the anti-Bakufu alliance. Emperor Komei's insistence on removing the foreigners and the Bakufu's inability to do so undermined the Shogun's authority and provided an in for dissident elements to further undermine and eventually overthrow the Bakufu. Just look at the major engagements of the Boshin War, for example. The Choshu-Satsuma forces, for all their previous emphasis on Sonno-Joi, didn't let the ideology keep them from adopting western methods and technology on a wider scale than the Bakufu. Following the bombardments of Shimonoseki and Kagoshima, Choshu and Satsuma were enthusiastically procuring Western weapons and adopting Western methods of war.
The fact that British merchants were arming the imperial side while the French were drilling the (ex)Shogunate side is a good example how things were not nearly so clear-cut.
Some of the threads on our FAQ about the Bakumatsu and Meiji Restoration might also interest you.