latest changes
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
@echo off
|
||||
REM ================================================================
|
||||
REM SPS_SKEL - FB_Main-Geruest als SCL erzeugen
|
||||
REM ================================================================
|
||||
REM Aufruf:
|
||||
REM bin\tro_flow.bat --file mubea.csv
|
||||
REM bin\tro_flow.bat --file mubea.csv --tosvg
|
||||
REM bin\tro_flow.bat --file mubea.csv --tosvg --doc
|
||||
REM
|
||||
REM Die JSON-Datei wird in %SKEL_RESULTS% gesucht, die SCL-Datei wird
|
||||
REM ebenfalls dort abgelegt.
|
||||
REM
|
||||
REM Schwesterprogramm: bin\material_flow.bat (Materialfluss der Objekte)
|
||||
REM ================================================================
|
||||
|
||||
setlocal
|
||||
|
||||
REM Umgebung setzen (SKEL_DATA, SKEL_RESULTS, SKEL_LIB, PYTHONPATH ...)
|
||||
call "%~dp0setenv.bat" >nul
|
||||
|
||||
REM Virtuelle Umgebung nutzen, falls vorhanden (pydantic wird benoetigt)
|
||||
if exist "%SPS_SKEL%\.venv\Scripts\activate.bat" (
|
||||
call "%SPS_SKEL%\.venv\Scripts\activate.bat"
|
||||
)
|
||||
|
||||
REM Python-Interpreter bestimmen (py-Launcher bevorzugt, sonst python)
|
||||
set "PY=py"
|
||||
py --version >nul 2>&1 || set "PY=python"
|
||||
|
||||
"%PY%" "%SKEL_LIB%\scl_skeleton.py" %*
|
||||
set "RC=%ERRORLEVEL%"
|
||||
|
||||
endlocal & exit /b %RC%
|
||||
@@ -0,0 +1,34 @@
|
||||
#!/usr/bin/env bash
|
||||
# ================================================================
|
||||
# SPS_SKEL - FB_Main-Geruest als SCL erzeugen
|
||||
# ================================================================
|
||||
# Aufruf:
|
||||
# bash bin/scl_skeleton.sh
|
||||
# bash bin/scl_skeleton.sh --json export_tro.json
|
||||
# bash bin/scl_skeleton.sh --json export_tro.json --out FB_Main.scl
|
||||
#
|
||||
# Die JSON-Datei wird in $SKEL_RESULTS gesucht, die SCL-Datei wird
|
||||
# ebenfalls dort abgelegt.
|
||||
#
|
||||
# Vorstufe: bin/tro_extract.sh (Zeichnung -> JSON)
|
||||
# ================================================================
|
||||
|
||||
set -eu
|
||||
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
|
||||
# Umgebung setzen (SKEL_DATA, SKEL_RESULTS, SKEL_LIB, PYTHONPATH ...)
|
||||
# shellcheck source=/dev/null
|
||||
. "$SCRIPT_DIR/setenv.sh" >/dev/null
|
||||
|
||||
# Virtuelle Umgebung nutzen, falls vorhanden (pydantic wird benoetigt)
|
||||
if [ -f "$SPS_SKEL/.venv/bin/activate" ]; then
|
||||
# shellcheck source=/dev/null
|
||||
. "$SPS_SKEL/.venv/bin/activate"
|
||||
fi
|
||||
|
||||
# Python-Interpreter bestimmen
|
||||
PY="python3"
|
||||
command -v python3 >/dev/null 2>&1 || PY="python"
|
||||
|
||||
exec "$PY" "$SKEL_LIB/scl_skeleton.py" "$@"
|
||||
@@ -0,0 +1,33 @@
|
||||
@echo off
|
||||
REM ================================================================
|
||||
REM SPS_SKEL - TROs aus der annotierten Zeichnung nach JSON lesen
|
||||
REM ================================================================
|
||||
REM Aufruf:
|
||||
REM bin\tro_flow.bat --file mubea.csv
|
||||
REM bin\tro_flow.bat --file mubea.csv --tosvg
|
||||
REM bin\tro_flow.bat --file mubea.csv --tosvg --doc
|
||||
REM
|
||||
REM Die Zeichnung wird in %SKEL_RESULTS% gesucht, die JSON-Datei wird
|
||||
REM ebenfalls dort abgelegt.
|
||||
REM
|
||||
REM Schwesterprogramm: bin\material_flow.bat (Materialfluss der Objekte)
|
||||
REM ================================================================
|
||||
|
||||
setlocal
|
||||
|
||||
REM Umgebung setzen (SKEL_DATA, SKEL_RESULTS, SKEL_LIB, PYTHONPATH ...)
|
||||
call "%~dp0setenv.bat" >nul
|
||||
|
||||
REM Virtuelle Umgebung nutzen, falls vorhanden (pydantic wird benoetigt)
|
||||
if exist "%SPS_SKEL%\.venv\Scripts\activate.bat" (
|
||||
call "%SPS_SKEL%\.venv\Scripts\activate.bat"
|
||||
)
|
||||
|
||||
REM Python-Interpreter bestimmen (py-Launcher bevorzugt, sonst python)
|
||||
set "PY=py"
|
||||
py --version >nul 2>&1 || set "PY=python"
|
||||
|
||||
"%PY%" "%SKEL_LIB%\tro_extract.py" %*
|
||||
set "RC=%ERRORLEVEL%"
|
||||
|
||||
endlocal & exit /b %RC%
|
||||
@@ -0,0 +1,34 @@
|
||||
#!/usr/bin/env bash
|
||||
# ================================================================
|
||||
# SPS_SKEL - TROs aus der annotierten Zeichnung nach JSON lesen
|
||||
# ================================================================
|
||||
# Aufruf:
|
||||
# bash bin/tro_extract.sh
|
||||
# bash bin/tro_extract.sh --dxf export_annotated.dxf
|
||||
# bash bin/tro_extract.sh --dxf export_annotated.dxf --out tros.json
|
||||
#
|
||||
# Die Zeichnung wird in $SKEL_RESULTS gesucht, die JSON-Datei wird
|
||||
# ebenfalls dort abgelegt.
|
||||
#
|
||||
# Gegenrichtung zu: bin/tro_annotate.sh (JSON <- Zeichnung)
|
||||
# ================================================================
|
||||
|
||||
set -eu
|
||||
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
|
||||
# Umgebung setzen (SKEL_DATA, SKEL_RESULTS, SKEL_LIB, PYTHONPATH ...)
|
||||
# shellcheck source=/dev/null
|
||||
. "$SCRIPT_DIR/setenv.sh" >/dev/null
|
||||
|
||||
# Virtuelle Umgebung nutzen, falls vorhanden (pydantic wird benoetigt)
|
||||
if [ -f "$SPS_SKEL/.venv/bin/activate" ]; then
|
||||
# shellcheck source=/dev/null
|
||||
. "$SPS_SKEL/.venv/bin/activate"
|
||||
fi
|
||||
|
||||
# Python-Interpreter bestimmen
|
||||
PY="python3"
|
||||
command -v python3 >/dev/null 2>&1 || PY="python"
|
||||
|
||||
exec "$PY" "$SKEL_LIB/tro_extract.py" "$@"
|
||||
Reference in New Issue
Block a user