Hi Stewart,
You piqued my curiosity, so I had to look it up. The Oxford English Dictionary lists "trig" as a verb meaning "to make firm or fast; prevent from moving, especially [to] stop the motion of (a wheel or a cask) with a wedge or block", or as a noun referring to said wedge or block. It's attested as far back as the late 16th century and possibly derived from the Old Norse
tryggja, "to make firm or secure", which would mean it came from the Vikings. So, it's a lot older than railroading.
-Philip Marshall