ATSAMD21G18 programming hex file via JTAG

I am trying to program the ATSAMD21G18 which is on my own board but based on the feather m0 by adafruit. I can successfully upload the feather m0 bootloader by jtag and then program it using the arduino ide over usb.

However I would like to be able to program it without the bootloader as the delay it causes when first switched on is undesirable. I have tried using the jtag to upload the .hex file produced by the arduino ide to the flash memory but the program does not execute.

Any advice would be much appreciated on why it might not be executing or an alternative method.