source: src/mapservice/codegen/code_generator@ bd0cb38

debian/bullseye
Last change on this file since bd0cb38 was bd0cb38, checked in by Joachim Langenbach <joachim.langenbach@…>, 7 years ago
  • Added license activated to User object and database table
  • Registering a user is now working
  • Property mode set to 100755
File size: 1.0 KB
RevLine 
[3a89adb]1#!/bin/bash
2
3DIR=`dirname "$0"`
[ec9e811]4SRC_GEN="${DIR}/../src-gen"
5TARGET="${SRC_GEN}/openapi_server/"
6
7echo "Cleaning directory"
8rm -R "${SRC_GEN}"
[3a89adb]9
10echo "Preparing symlinks"
[13cbe66]11mkdir -p "${TARGET}"
12cd "${TARGET}"
[3a89adb]13if [ ! -L server_impl ]; then
14 ln -s ../../src/server_impl/
15fi
16
[be25db1]17#echo "Copying static files"
18#cp -a ../../src/templates ./
19#cp -a ../../src/static ./
[ec9e811]20mkdir -p static/css/
21mkdir -p static/js/
22mkdir -p static/resources/
23cp -a ../../../common/css/* static/css/
24cp -a ../../../common/js/* static/js/
25cp -a ../../../common/resources/* static/resources/
26cp -a ../../../common/icon/* static/resources/
[bd0cb38]27mkdir -p templates
28cp -a ../../templates/* templates/
[3a89adb]29
[be25db1]30echo "Generating backend and client API code"
[3a89adb]31cd ../../
[be25db1]32# backend
[3a89adb]33codegen/openapi-generator-cli generate -i openapi.yaml -g python-flask -t codegen/templates/ -o src-gen
[be25db1]34# client
35#codegen/openapi-generator-cli generate -i openapi.yaml -g javascript -o src-gen/openapi_server/static/
36#rm -R src-gen/openapi_server/static/.openapi*
37
[3a89adb]38
39cd src-gen/
[be25db1]40tox > /tmp/openapi_tox.log
[3a89adb]41python3 -m openapi_server
Note: See TracBrowser for help on using the repository browser.