https://github.com/gschier/will-you-please
✨ The easiest way to run scripts during development
https://github.com/gschier/will-you-please
cli developer-tools
Last synced: over 1 year ago
JSON representation
✨ The easiest way to run scripts during development
- Host: GitHub
- URL: https://github.com/gschier/will-you-please
- Owner: gschier
- License: mit
- Created: 2020-05-28T03:41:40.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2023-02-25T02:14:10.000Z (over 3 years ago)
- Last Synced: 2025-02-28T13:49:12.512Z (over 1 year ago)
- Topics: cli, developer-tools
- Language: Go
- Homepage:
- Size: 1.42 MB
- Stars: 40
- Watchers: 3
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# Will You Please [](https://github.com/gschier/will-you-please/actions?query=workflow%3ARelease)
Will you please is a script runner for local development.

## Getting Started
Install the `wyp` binary:
```bash
go install github.com/gschier/wyp@latest
```
Generate a config file:
```bash
wyp init # Generate ./wyp.yaml
```
Run some commands!
```bash
wyp run # Prompt for script to run
wyp run [name] # Execute script by name
wyp run [name] --watch # Prompt and restart on file change
wyp run [name] --watch-dir ./src # Watch specific directory
wyp combine [name...] # Execute scripts in parallel
wyp start # Shorthand for `wyp run start`
```
## Configuration
Configuration is defined in `wyp.(yaml|toml|json)`. An sample config can be generated by running `wyp init`.
```yaml
# ~~~~~~~~ #
# wyp.yaml #
# ~~~~~~~~ #
# Scripts are defined in a map of [name] => [config]
scripts:
backend:
help: run the backend
run: go run main.go
watch: .
backend:
help: run the frontend
run: npm start
watch: ./frontend
start:
help: run backend and frontend
combine:
- backend
- frontend
```
Here's a dummy config that showcases all possible options.
```yaml
# Complete example
everything-example:
# Help text for command
help: command with all options
# Make available under "wyp [name]" vs default "wyp run [name]"
root: true
# Execute other scripts by name
combine:
- command1
- command2
# Code to execute for script
run: echo "Hello World"
# Define environment variables for run context
env:
- NAME=value
- ANOTHER='something that needs quotes'
# Change the directory the command is run in (default ./)
dir: './some/other/directory'
# Hide command from help output
hide: true
# Select between bash/zsh/sh (default: current shell)
shell: bash
# Restart when file change detected (recursive)
watch: .
```