Skip to content

Commit 1a1f2f9

Browse files
committed
fix copy
1 parent 3ab76e9 commit 1a1f2f9

File tree

1 file changed

+4
-10
lines changed

1 file changed

+4
-10
lines changed

scripts/deploy_to_hf.sh

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -169,22 +169,16 @@ fi
169169

170170
# Create staging directory
171171
CURRENT_STAGING_DIR="${STAGING_DIR}/${HF_NAMESPACE}/${ENV_NAME}"
172+
# Ensure clean staging directory
173+
rm -rf "$CURRENT_STAGING_DIR"
172174
mkdir -p "$CURRENT_STAGING_DIR/src/core"
173175
mkdir -p "$CURRENT_STAGING_DIR/src/envs/$ENV_NAME"
174176

175-
# Copy src/__init__.py if it exists
176-
if [ -f "src/__init__.py" ]; then
177-
cp src/__init__.py "$CURRENT_STAGING_DIR/src/__init__.py"
178-
fi
179-
180177
# Copy core files
181-
cp -R src/core/ "$CURRENT_STAGING_DIR/src/core/"
178+
cp -R src/core/* "$CURRENT_STAGING_DIR/src/core/"
182179

183180
# Copy environment files
184-
cp -R "src/envs/$ENV_NAME/" "$CURRENT_STAGING_DIR/src/envs/$ENV_NAME/"
185-
186-
# Create __init__.py for envs package (needed for Python imports)
187-
touch "$CURRENT_STAGING_DIR/src/envs/__init__.py"
181+
cp -R src/envs/$ENV_NAME/* "$CURRENT_STAGING_DIR/src/envs/$ENV_NAME/"
188182

189183
echo "📁 Copied core and $ENV_NAME environment files to $CURRENT_STAGING_DIR"
190184

0 commit comments

Comments
 (0)