Skip to content

Commit

Permalink
initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
punitpandey11 committed Oct 16, 2021
1 parent dd146b6 commit b7672a9
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 11 deletions.
4 changes: 2 additions & 2 deletions command/cli/cli.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import (
"strings"
"time"

"awesomeProject2/command"
"awesomeProject2/handler"
"communication/command"
"communication/handler"
)

const (
Expand Down
11 changes: 5 additions & 6 deletions command/file/file.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package file

import (
"bufio"
"errors"
"io"
"log"
"os"
Expand All @@ -11,14 +10,13 @@ import (
"strings"
"sync"

"awesomeProject2/command"
"awesomeProject2/handler"
"communication/command"
"communication/handler"
)

const (
FileError = "error in opening file"
ExitFlag = "exit"
ReadFlag = "done"
ExitFlag = "exit"
ReadFlag = "done"
)

var (
Expand Down Expand Up @@ -98,6 +96,7 @@ func NewClient(handleProvider handler.HandleProvider, configs ...string) (comman
}
}()
once.Do(func() {
var err error
fileInstance.handler = handleProvider
if len(configs) > 0 {
fileInstance.readLocation, err = os.OpenFile(configs[0], os.O_RDONLY, 777)
Expand Down
6 changes: 3 additions & 3 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ package main
import (
"fmt"

"awesomeProject2/command"
"awesomeProject2/command/cli"
"awesomeProject2/handler"
"communication/command"
"communication/command/cli"
"communication/handler"
)

func main() {
Expand Down

0 comments on commit b7672a9

Please sign in to comment.