Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

not found error on windows #131

Open
MobinAssari opened this issue May 27, 2024 · 2 comments
Open

not found error on windows #131

MobinAssari opened this issue May 27, 2024 · 2 comments

Comments

@MobinAssari
Copy link

this is my modd.conf
**/*.go {
prep: go test @dirmods
}

**/*.go {
prep: go build -o lenslocked .
daemon +sigterm: ./lenslocked
}
and this is my main.go
package main

import (
"fmt"
"net/http"
)

func handlerFunc(w http.ResponseWriter, r *http.Request) {

fmt.Fprint(w, "<h1> welcome to my site</h1>")

}
func main() {
http.HandleFunc("/", handlerFunc)
fmt.Println("starting on :3000...")
http.ListenAndServe(":3000", nil)
}

@wader
Copy link

wader commented May 27, 2024

Hi, what says "not found"? go build, modd doing ./lenslocked or something else? all those work in windows shell?

@megz2020
Copy link

megz2020 commented Jul 4, 2024

I encountered the same error on windows , which was due to the package not being able to find the correct path when using the daemon and SIGTERM. Using the full path resolved the issue for me. You might try the following:

daemon +sigterm: bash -c 'PWD=$(pwd) ./lenslocked'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants