This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
for commit in $(git rev-list origin/master | tail -r) | |
do | |
git reset --hard $commit | |
read -p "Press enter to continue..." | |
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Grab(group='mysql', module='mysql-connector-java', version='5.1.6') | |
@GrabConfig(systemClassLoader = true) | |
import groovy.sql.Sql | |
def sql = Sql.newInstance("jdbc:mysql://localhost:3306/noonu?sessionVariables=time_zone='-8:00'", 'root', '', 'com.mysql.jdbc.Driver') | |
println sql.firstRow("select now()") | |
def sql2 = Sql.newInstance("jdbc:mysql://localhost:3306/noonu?sessionVariables=time_zone='%2B8:00'", 'root', '', 'com.mysql.jdbc.Driver') | |
println sql2.firstRow("select now()") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
changeSet(author: "bryanchug", id: "1383792606533-1") { | |
grailsChange { | |
change { | |
sql.executeUpdate('UPDATE user SET name = :name', [name: 'Bryan Chug']) | |
} | |
} | |
} |
OlderNewer