It's in J. Hogg's 'Jacobite Relics' (reprinted), and suspicion is that Hogg wrote it himself. It's also reprinted in one of Robert Chamber's books with the tune ["Boyne Water", earlier called "Playing among the Rashes" (1694) if I remember correctly.)]