mirror of
https://github.com/csunny/DB-GPT.git
synced 2025-09-09 04:49:26 +00:00
fix(docs): Fix document build error (#2271)
This commit is contained in:
@@ -51,6 +51,19 @@ RUN git config --global --add safe.directory /app && \
|
||||
echo "Creating version $TAG"; \
|
||||
cd /app/docs && git checkout $TAG; \
|
||||
echo "Checked out to tag: $TAG"; \
|
||||
# Check if there is a patch for the current version in app-build
|
||||
echo "Checking patch in /app-build/docs/patchs..." && \
|
||||
if [ -f "/app-build/docs/patchs/fix_${TAG/v/}.patch" ]; then \
|
||||
echo "Found patch for version $TAG in /app-build/docs/patchs, applying..."; \
|
||||
cd /app && \
|
||||
git apply "/app-build/docs/patchs/fix_${TAG/v/}.patch" && \
|
||||
echo "Patch applied successfully" || \
|
||||
echo "Failed to apply patch for $TAG"; \
|
||||
echo "Current sidebars.js content:"; \
|
||||
cat /app/docs/sidebars.js; \
|
||||
else \
|
||||
echo "No patch found for $TAG in /app-build/docs/patchs"; \
|
||||
fi; \
|
||||
# Copy the necessary files to the build directory for each tag
|
||||
rm -rf /app-build/docs/docs /app-build/docs/sidebars.js /app-build/docs/static /app-build/docs/src && \
|
||||
cp -r /app/docs/docs /app-build/docs/ && \
|
||||
|
Reference in New Issue
Block a user