Skip to content

Commit

Permalink
Regex description
Browse files Browse the repository at this point in the history
  • Loading branch information
Ignat Belousov authored and Ignat Belousov committed Aug 5, 2023
1 parent dc16c76 commit 72328db
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 18 deletions.
2 changes: 1 addition & 1 deletion logger/sql.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ func isPrintable(s string) bool {
return true
}

// TODO:
// A list of Go types that should be converted to SQL primitives
var convertibleTypes = []reflect.Type{reflect.TypeOf(time.Time{}), reflect.TypeOf(false), reflect.TypeOf([]byte{})}

// RegEx matches only numeric values
Expand Down
2 changes: 2 additions & 0 deletions migrator/migrator.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ import (
// -"%$#@789"
var regFullDataType = regexp.MustCompile(`\D*(\d+)\D?`)

// TODO:? Create const vars for raw sql queries ?

// Migrator m struct
type Migrator struct {
Config
Expand Down
2 changes: 1 addition & 1 deletion tests/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ require (
github.com/jinzhu/inflection v1.0.0 // indirect
github.com/mattn/go-sqlite3 v1.14.17 // indirect
github.com/microsoft/go-mssqldb v1.5.0 // indirect
golang.org/x/crypto v0.11.0 // indirect
golang.org/x/crypto v0.12.0 // indirect
golang.org/x/text v0.12.0 // indirect
)

Expand Down
16 changes: 0 additions & 16 deletions tests/tests_all.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,22 +15,6 @@ then
cd ..
fi

# Function for checking if binary is installed
check_binary() {
if ! which "$1" > /dev/null; then
( >&2 echo "$2" )
# Exit with a nonzero code so that the caller knows the script failed.
exit 1
fi
}

check_binary "sqlcmd" "$(cat <<EOF
You will need microsoft/sqlcmd to run this script.
Install it using your package manager. E.g. for homebrew:
brew install sqlcmd
EOF
)"

# SqlServer for Mac M1
if [[ -z $GITHUB_ACTION ]]; then
if [ -d tests ]
Expand Down

0 comments on commit 72328db

Please sign in to comment.