Cmd test sub packages

This commit is contained in:
qowevisa 2024-08-02 00:03:51 +03:00
parent 8f4340dfb2
commit 9ad1743810
2 changed files with 32 additions and 0 deletions

13
cmd/cfyne/main.go Normal file
View 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
View 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)
}