diff --git a/website/copy-api.sh b/website/copy-api.sh index 838c9b83..8a9bbdf7 100755 --- a/website/copy-api.sh +++ b/website/copy-api.sh @@ -56,8 +56,8 @@ process_subpackage() { local title="$(kebab_to_title_case "$pkg_name")" fi - escaped_name="${name//@/\\@}" - escaped_name="${escaped_name//\//\\/}" + escaped_name=$(echo "$name" | sed 's/@/\\@/g') + escaped_name=$(echo "$escaped_name" | sed 's/\//\\/g') sed -i -e "s/title: \(.*\)/title: \"$escaped_name\"/" "$dir/index.mdx" sed -i -e "s/## Index/ /" "$dir/index.mdx" echo "{ \"title\": \"$title\" }" >"$dir/meta.json"