We present a novel framework for the fabrication of geometrically complex structures at the micro- and nano-scale which relies on the synergy of integrated computer-aided design and manufacturing systems (CAD/CAM) and focused ion beam (FIB) technology in a scanning electron microscope. Here we utilise industry standard G-code syntax, for the first time, to FIB machining by designing geometries with CAD, defining machining strategies and exporting G-codes with CAM and generating a coordinate list-based beam path by using a custom-built interpreter program. This allows the fabrication of complex structures from CAD models using syntax which is readily understood in the general fabrication industry. The use of G-code allows optimization of the beam path towards a reduction of beam blanking operations and tracing of contours, leading to minimized re-deposition of material. We give a detailed description of the method, use an application example to demonstrate advantages and prospects of the approach and provide the free and open-source interpreter program CAM2FIB for application of this method. We contrast and compare various existing available milling strategies and demonstrate the versatility of G-code based programming.