mirror of
https://github.com/ueberdosis/tiptap.git
synced 2026-09-14 16:14:40 +08:00
1d205165bd
* chore!: remove deprecated package aliases Remove the legacy package workspace and all build, alias, release, and test references before v4. BREAKING CHANGE: v4 no longer publishes the deprecated package aliases from packages-deprecated. * update changeset * chore: change changeset bump type * fix: fix README link * chore: update changeset
54 lines
1.2 KiB
Bash
Executable File
54 lines
1.2 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
set -euo pipefail
|
|
|
|
SCRIPT_DIR="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" && pwd)"
|
|
REPO_ROOT="$(cd -- "$SCRIPT_DIR/.." && pwd)"
|
|
|
|
shopt -s nullglob
|
|
|
|
declare -a missing_paths=()
|
|
declare -a package_dirs=()
|
|
declare -a empty_paths=()
|
|
|
|
for package_json in "$REPO_ROOT"/packages/*/package.json; do
|
|
package_dirs+=("${package_json%/package.json}")
|
|
done
|
|
|
|
if [ "${#package_dirs[@]}" -eq 0 ]; then
|
|
echo "No package directories found."
|
|
exit 1
|
|
fi
|
|
|
|
for package_dir in "${package_dirs[@]}"; do
|
|
dist_dir="$package_dir/dist"
|
|
|
|
if [ ! -d "$dist_dir" ]; then
|
|
missing_paths+=("${dist_dir#"$REPO_ROOT"/}")
|
|
continue
|
|
fi
|
|
|
|
dist_entries=("$dist_dir"/*)
|
|
|
|
if [ "${#dist_entries[@]}" -eq 0 ]; then
|
|
empty_paths+=("${dist_dir#"$REPO_ROOT"/}")
|
|
fi
|
|
done
|
|
|
|
if [ "${#missing_paths[@]}" -eq 0 ] && [ "${#empty_paths[@]}" -eq 0 ]; then
|
|
echo "All ${#package_dirs[@]} package dist directories exist and contain build artifacts."
|
|
exit 0
|
|
fi
|
|
|
|
if [ "${#missing_paths[@]}" -gt 0 ]; then
|
|
echo "Missing dist directories:"
|
|
printf ' - %s\n' "${missing_paths[@]}"
|
|
fi
|
|
|
|
if [ "${#empty_paths[@]}" -gt 0 ]; then
|
|
echo "Empty dist directories:"
|
|
printf ' - %s\n' "${empty_paths[@]}"
|
|
fi
|
|
|
|
exit 1
|