mirror of
https://github.com/ivabus/pantry
synced 2024-11-10 02:25:18 +03:00
new file: projects/swagger.io/swagger-codegen/package.yml
This commit is contained in:
parent
c5145a2d76
commit
121c560474
44
projects/swagger.io/swagger-codegen/package.yml
Normal file
44
projects/swagger.io/swagger-codegen/package.yml
Normal file
|
@ -0,0 +1,44 @@
|
|||
distributable:
|
||||
url: https://github.com/swagger-api/swagger-codegen/archive/refs/tags/{{version.tag}}.tar.gz
|
||||
strip-components: 1
|
||||
|
||||
versions:
|
||||
github: swagger-api/swagger-codegen
|
||||
|
||||
dependencies:
|
||||
openjdk.org: ^11
|
||||
|
||||
build:
|
||||
dependencies:
|
||||
maven.apache.org: '*'
|
||||
script:
|
||||
- mvn clean package
|
||||
- install -D modules/swagger-codegen-cli/target/swagger-codegen-cli.jar {{prefix}}/libexec/lib/swagger-codegen-cli.jar
|
||||
- run: |
|
||||
cat > swagger-codegen <<EOF
|
||||
#!/bin/sh
|
||||
exec java -jar \$(dirname \$0)/../libexec/lib/swagger-codegen-cli.jar "\$@"
|
||||
EOF
|
||||
chmod +x swagger-codegen
|
||||
working-directory: ${{prefix}}/bin
|
||||
|
||||
provides:
|
||||
- bin/swagger-codegen
|
||||
|
||||
test:
|
||||
- run: swagger-codegen generate -i $FIXTURE -l html
|
||||
fixture:
|
||||
content: |
|
||||
openapi: 3.0.0
|
||||
info:
|
||||
version: 0.0.0
|
||||
title: Simple API
|
||||
paths:
|
||||
/:
|
||||
get:
|
||||
responses:
|
||||
200:
|
||||
description: OK
|
||||
extname: yaml
|
||||
- cat index.html | grep "Simple API"
|
||||
- swagger-codegen version | grep {{version}}
|
Loading…
Reference in a new issue