29 lines
592 B
Bash
Executable File
29 lines
592 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
#!/usr/bin/env bash
|
|
|
|
echo "Building"
|
|
|
|
bun run build:tsc
|
|
|
|
# Declare array with proper syntax
|
|
filesToCopy=("index.html" "styles.css")
|
|
destination="dist"
|
|
|
|
# Create destination directory if it doesn't exist
|
|
mkdir -p "${destination}"
|
|
|
|
# Copy files from public directory
|
|
for file in "${filesToCopy[@]}"; do
|
|
echo "[public/${file}] --> [${destination}/public]"
|
|
|
|
# Check if source file exists
|
|
if [ -f "public/${file}" ]; then
|
|
cp "public/${file}" "${destination}/public"
|
|
else
|
|
echo "Warning: public/${file} not found, skipping..."
|
|
fi
|
|
done
|
|
|
|
echo "Build complete"
|