Only recently have I figured out what I think is a reasonable coding scheme for tunes that will handle the 17th century tunes on my website as well as those in my Irish tune index. Among the latter its pretty common to have both major and mixolydian version of the same tune, the difference being the 7th natural and flatted, respectively. But there are many 8 note tunes which seem to bounce between with two with the 7th occurring both as natural and flat. I've just started coding the 17th century broadside ballad tunes on my website, but I've already been struck by the many basically dorian and aeolian, with the 7th is nomally flat, but where it's either natural (i.e., sharp with respect to normal for the mode) or both flat and natural. "Greensleeves" has a lot of relatives prior to 1700, but these seem to be rather rare among later tunes I've coded. [The number of different notes in tunes is rather higher in music prior to 1700, than in later ones, also, on the average.
The white key notes are used to represent the modes in 'The Sources of Irish Traditional Music', 1998, and in the code indexes on my website, i.e., (in order of increasing flats) f- lydian, c-ionian, g-mixolydian, d-dorian, a-aeolian, e-phygian, and b-locrian. The white note system is convenient, but Bertrand Bronson pointed out that if you don't transpose these to a common keynote, it's not terribly obvious what the difference is (looking at the music that is, not listening).