Is it safe to look at a mercury gas discharge tube?
Could it have caused irritation or injury? Possibly, but not likely, depending on a few factors:

The intensity of the emitted ultraviolet.
Proximity to the light source.
Length of exposure.

You'd need to calculate the dosage integrated over time.
That said, it is very unlikely any harm was done, because of the following:

The power supplies are limited to to only a few mA current. The total power is the arc voltage drop, ~30 to 100 VAC, times the current. For the supply abvove, that would be 100 VAC * 0.01 A = 1 W. One watt is low power for a mercury lamp.
Demonstration spectral lamps, such as this capillary mercury vapor lamp, usually have thick borosilicate glass capillaries. Borosilicate glass does not transmit shorter wavelengths well. Most of the UV would have been absorbed by the thick capillary wall.
The length of time was given as &quot;several minutes&quot;, so the integrated intensity over time (i.e., total energy absorbed) was low.
That you state you were, &quot;within one foot of the discharge tube,&quot; ~30 cm, is of concern, because some older discharge tube power supplies had exposed high voltage terminals. Though limited to 10 mA, considered below a dangerous current for electric shock, in most cases, one could still get burnt by the ~10,000 VAC arc, should one come in contact with exposed terminals, or could be startled and hurt by a muscular reflex action. Likely, though, the ends of the tube and associated wiring were safely enclosed.

So, all things considered, there might have been fumes in the lab or other cause of irritation, but I believe the UV light was not likely an issue.