Skip to content

Commit

Permalink
Update namespace
Browse files Browse the repository at this point in the history
  • Loading branch information
aman00323 committed Nov 3, 2021
1 parent 68654aa commit e38e42a
Show file tree
Hide file tree
Showing 14 changed files with 26 additions and 23 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

> SQL Schema migration tool for [Go](https://golang.org/). Based on [gorp](https://github.com/go-gorp/gorp) and [goose](https://bitbucket.org/liamstask/goose).
[![Build Status](https://travis-ci.org/rubenv/sql-migrate.svg?branch=master)](https://travis-ci.org/rubenv/sql-migrate) [![GoDoc](https://godoc.org/github.com/rubenv/sql-migrate?status.svg)](https://godoc.org/github.com/rubenv/sql-migrate)
[![Build Status](https://travis-ci.org/aman00323/sql-migrate.svg?branch=master)](https://travis-ci.org/aman00323/sql-migrate) [![GoDoc](https://godoc.org/github.com/aman00323/sql-migrate?status.svg)](https://godoc.org/github.com/aman00323/sql-migrate)

Using [modl](https://github.com/jmoiron/modl)? Check out [modl-migrate](https://github.com/rubenv/modl-migrate).

Expand All @@ -22,7 +22,7 @@ Using [modl](https://github.com/jmoiron/modl)? Check out [modl-migrate](https://
To install the library and command line program, use the following:

```bash
go get -v github.com/rubenv/sql-migrate/...
go get -v github.com/aman00323/sql-migrate/...
```

## Usage
Expand Down Expand Up @@ -138,7 +138,7 @@ Oracle Driver is [oci8](https://github.com/mattn/go-oci8), it is not pure Go cod
To install the library and command line program, use the following:

```bash
go get -tags oracle -v github.com/rubenv/sql-migrate/...
go get -tags oracle -v github.com/aman00323/sql-migrate/...
```

```yml
Expand All @@ -158,7 +158,7 @@ To install the library and command line program, use the following:

1. Install sql-migrate
```bash
go get -tags godror -v github.com/rubenv/sql-migrate/...
go get -tags godror -v github.com/aman00323/sql-migrate/...
```

2. Download Oracle Office Client(e.g. macos, click [Instant Client](https://www.oracle.com/database/technologies/instant-client/downloads.html) if you are other system)
Expand All @@ -185,7 +185,7 @@ development:
Import sql-migrate into your application:

```go
import "github.com/rubenv/sql-migrate"
import "github.com/aman00323/sql-migrate"
```

Set up a source of migrations, this can be from memory, from a set of files, from bindata (more on that later), or from any library that implements [`http.FileSystem`](https://godoc.org/net/http#FileSystem):
Expand Down Expand Up @@ -247,7 +247,7 @@ fmt.Printf("Applied %d migrations!\n", n)

Note that `n` can be greater than `0` even if there is an error: any migration that succeeded will remain applied even if a later one fails.

Check [the GoDoc reference](https://godoc.org/github.com/rubenv/sql-migrate) for the full documentation.
Check [the GoDoc reference](https://godoc.org/github.com/aman00323/sql-migrate) for the full documentation.

## Writing migrations
Migrations are defined in SQL files, which contain a set of SQL statements. Special comments are used to distinguish up and down migrations.
Expand Down
4 changes: 2 additions & 2 deletions doc.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Installation
To install the library and command line program, use the following:
go get -v github.com/rubenv/sql-migrate/...
go get -v github.com/aman00323/sql-migrate/...
Command-line tool
Expand Down Expand Up @@ -93,7 +93,7 @@ Library
Import sql-migrate into your application:
import "github.com/rubenv/sql-migrate"
import "github.com/aman00323/sql-migrate"
Set up a source of migrations, this can be from memory, from a set of files or from bindata (more on that later):
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module github.com/rubenv/sql-migrate
module github.com/aman00323/sql-migrate

go 1.16

Expand Down
4 changes: 2 additions & 2 deletions migrate.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import (
"strings"
"time"

"github.com/rubenv/sql-migrate/sqlparse"
"github.com/aman00323/sql-migrate/sqlparse"
"gopkg.in/gorp.v1"
)

Expand Down Expand Up @@ -732,7 +732,7 @@ func (ms MigrationSet) getMigrationDbMap(db *sql.DB, dialect string) (*gorp.DbMa

// When using the mysql driver, make sure that the parseTime option is
// configured, otherwise it won't map time columns to time.Time. See
// https://github.com/rubenv/sql-migrate/issues/2
// https://github.com/aman00323/sql-migrate/issues/2
if dialect == "mysql" {
var out *time.Time
err := db.QueryRow("SELECT NOW()").Scan(&out)
Expand Down
2 changes: 1 addition & 1 deletion sql-migrate/command_common.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package main
import (
"fmt"

"github.com/rubenv/sql-migrate"
migrate "github.com/aman00323/sql-migrate"
)

func ApplyMigrations(dir migrate.MigrationDirection, dryrun bool, limit int) error {
Expand Down
2 changes: 1 addition & 1 deletion sql-migrate/command_down.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"flag"
"strings"

"github.com/rubenv/sql-migrate"
migrate "github.com/aman00323/sql-migrate"
)

type DownCommand struct {
Expand Down
2 changes: 1 addition & 1 deletion sql-migrate/command_redo.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"fmt"
"strings"

migrate "github.com/rubenv/sql-migrate"
migrate "github.com/aman00323/sql-migrate"
)

type RedoCommand struct {
Expand Down
2 changes: 1 addition & 1 deletion sql-migrate/command_skip.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"fmt"
"strings"

"github.com/rubenv/sql-migrate"
migrate "github.com/aman00323/sql-migrate"
)

type SkipCommand struct {
Expand Down
2 changes: 1 addition & 1 deletion sql-migrate/command_status.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import (
"strings"
"time"

migrate "github.com/aman00323/sql-migrate"
"github.com/olekukonko/tablewriter"
"github.com/rubenv/sql-migrate"
)

type StatusCommand struct {
Expand Down
2 changes: 1 addition & 1 deletion sql-migrate/command_up.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"flag"
"strings"

"github.com/rubenv/sql-migrate"
migrate "github.com/aman00323/sql-migrate"
)

type UpCommand struct {
Expand Down
3 changes: 2 additions & 1 deletion sql-migrate/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ import (
"io/ioutil"
"os"

"github.com/rubenv/sql-migrate"
"github.com/aman00323/sql-migrate"
migrate "github.com/aman00323/sql-migrate"
"gopkg.in/gorp.v1"
"gopkg.in/yaml.v2"

Expand Down
3 changes: 2 additions & 1 deletion sql-migrate/godror.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
//go:build godror
// +build godror

// godror is another oracle driver
Expand All @@ -9,8 +10,8 @@
package main

import (
migrate "github.com/aman00323/sql-migrate"
_ "github.com/godror/godror"
migrate "github.com/rubenv/sql-migrate"
)

func init() {
Expand Down
3 changes: 2 additions & 1 deletion sql-migrate/oracle.go
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
//go:build oracle
// +build oracle

package main

import (
migrate "github.com/aman00323/sql-migrate"
_ "github.com/mattn/go-oci8"
migrate "github.com/rubenv/sql-migrate"
)

func init() {
Expand Down
6 changes: 3 additions & 3 deletions sqlparse/sqlparse.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@ var (
func errNoTerminator() error {
if len(LineSeparator) == 0 {
return errors.New(`ERROR: The last statement must be ended by a semicolon or '-- +migrate StatementEnd' marker.
See https://github.com/rubenv/sql-migrate for details.`)
See https://github.com/aman00323/sql-migrate for details.`)
}

return errors.New(fmt.Sprintf(`ERROR: The last statement must be ended by a semicolon, a line whose contents are %q, or '-- +migrate StatementEnd' marker.
See https://github.com/rubenv/sql-migrate for details.`, LineSeparator))
See https://github.com/aman00323/sql-migrate for details.`, LineSeparator))
}

// Checks the line to see if the line has a statement-ending semicolon
Expand Down Expand Up @@ -221,7 +221,7 @@ func ParseMigration(r io.ReadSeeker) (*ParsedMigration, error) {

if currentDirection == directionNone {
return nil, errors.New(`ERROR: no Up/Down annotations found, so no statements were executed.
See https://github.com/rubenv/sql-migrate for details.`)
See https://github.com/aman00323/sql-migrate for details.`)
}

// allow comment without sql instruction. Example:
Expand Down

0 comments on commit e38e42a

Please sign in to comment.