Skip to content

Commit d169240

Browse files
committed
added a small banner with version number and repo printed
1 parent c29eebc commit d169240

File tree

2 files changed

+14
-1
lines changed

2 files changed

+14
-1
lines changed

paataka.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import (
88
)
99

1010
func main() {
11-
paatakaVersion := "Paataka v1.0"
11+
paatakaVersion := "Paataka v1.2"
1212
repo := database.NewSQLPublicationRepository(paatakaVersion)
1313
defer repo.Persist()
1414

ui/cli.go

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ type option struct {
2525
// GetInput gets user input via CLI
2626
func (c *CLI) GetInput() {
2727
c.reader = bufio.NewReader(os.Stdin)
28+
c.printBanner()
2829

2930
options := []option{
3031
option{"Add Publication", c.addPublication},
@@ -221,3 +222,15 @@ func (c *CLI) feedFetchWorker(id int, jobs <-chan entities.Publication, results
221222
}
222223
}
223224
}
225+
226+
// printBanner simply prints a silly ASCII banner
227+
func (c *CLI) printBanner() {
228+
fmt.Println("")
229+
fmt.Println(" __ __ ")
230+
fmt.Println(" ___ ___ ____ _/ /____ _/ /_____ _")
231+
fmt.Println(" / _ \\/ _ `/ _ `/ __/ _ `/ '_/ _ `/")
232+
fmt.Println(" / .__/\\_,_/\\_,_/\\__/\\_,_/_/\\_/\\_,_/")
233+
fmt.Println(" /_/", c.PublicationService.GetRepositoryVersion())
234+
fmt.Println(" https://github.com/janithl/paataka")
235+
fmt.Println("")
236+
}

0 commit comments

Comments
 (0)