#!/bin/zsh
rm -rf ./esm
mkdir esm
cp ./*.ts esm
cp ./*.js esm
cp -r ./eq-next esm
cp -r ./genshiro esm
cp -r ./equilibrium esm
cp -r ./lite esm
for f in esm/**/*.js
do
  mv "$f" "${f%.js}.mjs"
done
for f in esm/**/*.d.ts
do
  mv "$f" "${f%.d.ts}.d.mts"
done