[generated] sandpack files from: codesandbox-client

This commit is contained in:
Will Chen
2025-04-12 00:09:50 -07:00
parent 4b641a3303
commit a618ec3f56
442 changed files with 393342 additions and 0 deletions

25
sandpack-generated/env.sh Executable file
View File

@@ -0,0 +1,25 @@
#!/bin/sh
# Recreate config file
envConfigFilePath=$1
rm -rf $envConfigFilePath
touch $envConfigFilePath
# Add assignment
echo "window._env_ = {" >> $envConfigFilePath
while IFS='=' read -r varname varvalue || [ -n "$varname" ]; do
value=""
if [ ! -z $(printenv | grep "$varname=") ]; then
eval "value=\"\${$varname}\""
else
# Otherwise use value from .env file
value="$varvalue"
fi
echo " $varname: \"$value\"," >> "$envConfigFilePath"
done < ".env"
echo "}" >> "$envConfigFilePath"