Skip to content

Commit

Permalink
igluctl: use UTC in header generation of Redshift DDL files (close #223)
Browse files Browse the repository at this point in the history
  • Loading branch information
oguzhanunlu committed Feb 7, 2018
1 parent 4c03c1a commit acbfa82
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ package com.snowplowanalytics.iglu.ctl

// Java
import java.io.File
import java.text.SimpleDateFormat
import java.util.Calendar
import java.time.{ZoneOffset, ZonedDateTime}
import java.time.format.DateTimeFormatter

// Iglu Core
import com.snowplowanalytics.iglu.core.SchemaMap
Expand Down Expand Up @@ -143,7 +143,7 @@ case class GenerateCommand(
def redshiftDdlHeader = CommentBlock(Vector(
s"AUTO-GENERATED BY ${generated.ProjectSettings.name} DO NOT EDIT",
s"Generator: ${generated.ProjectSettings.name} ${generated.ProjectSettings.version}",
s"Generated: ${new SimpleDateFormat("YYYY-MM-dd HH:mm").format(Calendar.getInstance.getTime)}"
s"Generated: ${ZonedDateTime.now(ZoneOffset.UTC).format(DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm"))} UTC"
))

// Header section with additional space
Expand Down

0 comments on commit acbfa82

Please sign in to comment.