mirror of
1
Fork 0
gotosocial/scripts/generateswagger.sh

10 lines
202 B
Bash
Executable File

#!/bin/bash
set -eu
SWAGGER_FILE="docs/api/swagger.yaml"
GTS_VERSION="$(cat version)"
swagger generate spec -o "${SWAGGER_FILE}" --scan-models
sed -i "s/REPLACE_ME/${GTS_VERSION}/" "${SWAGGER_FILE}"