
pwt ("port wait") waits for you until a tcp socket, aka port becomes available and exits cleanly once it does. Designed for
continuous integration scripts, never call sleep inside your pipeline again.


What's New
v0.1.7
- -h -v flags for cli
- bumped to go 1.20
Up and running
Homebrew
brew tap simonmittag/cli &&
brew install pwt &&
pwt
Golang
git clone https://github.com/simonmittag/pwt && cd pwt &&
go install github.com/simonmittag/pwt/cmd/pwt &&
pwt
Usage
λ pwt[v0.1.6]
Usage: pwt [-v]|[-w n] host[:port]
-h print usage instructions
-v print pwt version
-w int
time wait in seconds (default 10)
Examples
Wait for ipv4 localhost on default port
λ pwt 127.0.0.1
pwt waiting for 127.0.0.1:80 .......... aborted after 10 seconds
Wait for ipv6 localhost on port 8080 for 3 seconds
λ pwt -w 3 [::1]:8080
pwt waiting for [::1]:8080 .. connected in 2 seconds
Wait for google on port 443
λ pwt -w 60 google.com:443
pwt waiting for google.com:443 connected in <1 second
Contributions
The pwt team welcomes all contributors. Everyone interacting with the project's codebase, issue trackers, chat rooms and mailing lists
is expected to follow the code of conduct