Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gingerhot/joker
:clown_face: A commandline tool helps to check your dev environment.
https://github.com/gingerhot/joker
check-dev-env commandline-tool dev-tools
Last synced: about 2 months ago
JSON representation
:clown_face: A commandline tool helps to check your dev environment.
- Host: GitHub
- URL: https://github.com/gingerhot/joker
- Owner: gingerhot
- License: mit
- Created: 2020-02-13T08:08:17.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2020-09-10T08:24:35.000Z (over 4 years ago)
- Last Synced: 2024-05-22T23:04:14.768Z (7 months ago)
- Topics: check-dev-env, commandline-tool, dev-tools
- Language: Go
- Homepage:
- Size: 19.5 KB
- Stars: 9
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Joker - Helps to check your dev environment
Joker is a commandline tool used to check your dev environment.
If you need a lot of tools and services in your dev environment, you might miss some operation before coding and testing. Then you'll spend some time to debug an odd error, finally you figured out that it's just because you forgot starting a service or exporting a PATH. That's aweful!
Joker provides several kinds of checking as:
* **ports** (is open or not?)
* **env variables** (is matched or not with the given expected value?)
* **file paths** (exists or not?)
* **commands** (is available or not?)
* **command outputs** (does command output match with the given expected value?)## Compatibility
* macOS and Linux supported, not Windows
* Bash shell only## Installation
Just `go get` if you have a Go environment:
```
go get github.com/gingerhot/joker
```or install a binary from [Releases](https://github.com/gingerhot/joker/releases):
```
curl -sL $(curl -s https://api.github.com/repos/gingerhot/joker/releases/latest | grep "browser_download_url.*.gz" | grep $(uname -s | tr '[:upper:]' '[:lower:]') | cut -d '"' -f 4) | tar xz -C /tmp
sudo mv /tmp/joker /usr/local/bin/joker
```## Usage
You can check [example.yaml](../master/example.yaml) to get how to config to check your dev env. It's straight forward and easy to play.
When you have such a yaml-format config file, then run:
```
joker example.yaml
```if you named your config file as exact `joker.yaml`, just run `joker` and it will work perfectly.
Get more help by `joker -h`.
Joker is handy, enjoy!
## Q&A
1. Why I name it Joker?
Not special but I just watched the movie [Joker](https://www.imdb.com/title/tt7286456/), and it's more fun than to name it as `dev-env-checker`.
2. Why not add a `match` directive to undertake pattern matching as `expected` doing exact match in outputs check?
This can be achieved by some shell tricks along with the `expected` keyword, for example:
```yaml
outputs:
- name: Check Go version
cmd: go version | grep -q 'go1.13.6' && echo 'matched'
expected: matched
```And hope this example can enlighten your tremendous creativity.
## Contributing
Bug reports and pull requests are welcome. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.
## License
The software is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).