Settings

Theme

Show HN: Wu – a tiny utility written in Go for running command on file changes

github.com

9 points by ant_sz 9 years ago · 6 comments

Reader

ant_szOP 9 years ago

I write it because many of Go's web server are very lightweight so that they do not have the auto reloading function. It will be more convenient that we have a tool to stop the old process and start a new one after we saved some source code.

After searched and reviewed some similar solutions like that of Gulp and Grunt (many solutions are from NodeJS community), I think writing a universal command line tool with Go might be cool.

The advantages of this command is that it does not need any external dependencies and the precompiled binary can run directly on linux and macOS. It is useful not only for running dev server with `go run server.go` or `python server.py` but also when you want to rebuild your go project after any changes of source code. It is designed to be extremely simple and I have already been enjoying it during the development of itself!

Although it is lack of unit tests yet, I think it might be good for you to try it out now :)

  • johncoltrane 9 years ago

    Wu looks nice and simple. Did you know https://github.com/cortesi/modd when you started work on Wu?

    • ant_szOP 9 years ago

      Aha, seems I reinvented a wheel again. But I think the simplicity might be an advantage of wu. modd seems to be too complex for someone to getting started at the first glance.

      • metakirby5 9 years ago

        I've been using http://entrproject.org for awhile, which accomplishes a similar task. I do love your -save flag though :)

      • hawkice 9 years ago

        I've also been using entr but I think I like this better. Piping file names into entr doesn't make a lot of sense to me, I like the ability to use patterns.

        I've downloaded it given it a shot and now realize I actually like it a lot more than entr because I don't have to have development environment instructions in my Deploy readme, I can commit the .wu.json file. :) Much better to have that in version control.

gernest 9 years ago

Have you also taken a look at fresh https://github.com/pilu/fresh ?

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection