The best way is to use a 12v relay , connect a live from the switched side of the fuse box to one of the trigger contacts & the other to the thin wire leaving the alternator , that trips the warning light on the dash . When the alteranto begins to charge the wire goes to ground & completes the circuit energising the relay .
You then simply use a suitable guage fo wire from the vehicle battery to the relay WITH A FUSE IN LINE ! & continue from the relay to your second battery .
If you want to be really lazy car accessorie shops & caravan/camping stores sell split chrge relay kits that are pre wired .
Use of he relay stops your secondary battery supplying power when starting the vehicle
hope it helps
Oh 35+ years working on cars / trucks / boats Etc.