Only doing nuclear research for military purposes is frowned upon by your neighbours and makes you look suspicous, and only having a civilian program is super complex and expensive and doesn't even make you untouchable. Luckily building the infrastructure for a nuclear arsenal goes hand in hand with building the infrastructure for civilian uses, so you have a buy one, get one free situation.
>> The National Assembly approved the initial nuclear energy plan for a five-year term on July 24, 1952. The plan sought to build two experimental reactors at the Marcoule nuclear site, and construction began in 1955. Shortly thereafter, the construction of a third reactor commenced. In addition to generating electricity, these reactors would produce plutonium in sufficient quantities to support a civil advanced reactor program and potentially a military one, at a cost three times lower than highly enriched uranium.[69][70][71]
https://en.wikipedia.org/wiki/History_of_France%27s_civil_nu...
>> In 1957 Euratom was created, and under cover of the peaceful use of nuclear power the French signed deals with West Germany and Italy to work together on nuclear weapons development.[18] The Chancellor of West Germany Konrad Adenauer told his cabinet that he "wanted to achieve, through EURATOM, as quickly as possible, the chance of producing our own nuclear weapons".
https://en.wikipedia.org/wiki/France_and_weapons_of_mass_des...