Created
April 15, 2020 22:02
-
-
Save isitgeorge/ca3186f9f5d886e8b9413e1d48312539 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| PORT=3000 | |
| DIRECTORYPORTPAIRS="" | |
| for i in * | |
| do | |
| if [[ $i =~ "service-" ]]; then | |
| DIRECTORYPORTPAIRS="${DIRECTORYPORTPAIRS} --directory $i --port $PORT" | |
| ((++PORT)) | |
| fi | |
| done || exit 1 | |
| printf "\n%s\n" "Using command: ${DIRECTORYPORTPAIRS}" | |
| serverless-offline-multi $DIRECTORYPORTPAIRS |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment