function writeDosDateTime(writer, date) {
  const dosTime =
    date !== undefined && date !== null
      ? (((date.getUTCFullYear() - 1980) & 0x7f) << 25) | // year
        ((date.getUTCMonth() + 1) << 21) | // month
        (date.getUTCDate() << 16) | // day
        (date.getUTCHours() << 11) | // hour
        (date.getUTCMinutes() << 5) | // minute
        (date.getUTCSeconds() >> 1) // second
      : 0; // Epoch origin by default.
  writer.writeUint32(dosTime, true);
}
@param {BufferWriter} writer
@param {Date?} date
@see http://www.delorie.com/djgpp/doc/rbinter/it/65/16.html
@see http://www.delorie.com/djgpp/doc/rbinter/it/66/16.html