Cmd test sub packages
This commit is contained in:
parent
8f4340dfb2
commit
9ad1743810
13
cmd/cfyne/main.go
Normal file
13
cmd/cfyne/main.go
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
package main
|
||||||
|
|
||||||
|
import (
|
||||||
|
"fyne.io/fyne/v2/app"
|
||||||
|
"fyne.io/fyne/v2/widget"
|
||||||
|
)
|
||||||
|
|
||||||
|
func main() {
|
||||||
|
myApp := app.New()
|
||||||
|
myWindow := myApp.NewWindow("Hello")
|
||||||
|
myWindow.SetContent(widget.NewLabel("Hello, Fyne!"))
|
||||||
|
myWindow.ShowAndRun()
|
||||||
|
}
|
19
cmd/http-server/main.go
Normal file
19
cmd/http-server/main.go
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
package main
|
||||||
|
|
||||||
|
import (
|
||||||
|
"fmt"
|
||||||
|
"net/http"
|
||||||
|
|
||||||
|
"git.qowevisa.me/Qowevisa/gonuts/db"
|
||||||
|
)
|
||||||
|
|
||||||
|
func main() {
|
||||||
|
dbc := db.Connect()
|
||||||
|
if dbc != nil {
|
||||||
|
fmt.Printf("yay\n")
|
||||||
|
}
|
||||||
|
http.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) {
|
||||||
|
fmt.Fprintf(w, "Hello, World!")
|
||||||
|
})
|
||||||
|
http.ListenAndServe(":8080", nil)
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user