1 Star 0 Fork 1K

openwjh / amis

forked from 百度开源 / amis 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
publish-to-internal.sh 880 Bytes
一键复制 编辑 原始数据 按行查看 历史
wuduoyi 提交于 2022-07-22 15:20 . chore: 修复编译 warnning
#!/bin/bash
set -e
npm run build --workspaces
rm -rf npm
mkdir npm
# 如果有问题可以注释掉这两行,不知道为啥会导致 cp -rf 挂掉
# rm -rf packages/amis/node_modules/.bin
# rm -rf packages/amis-ui/node_modules/.bin
cp -rf packages npm
cp package.json npm
cd npm
# package.json 里面把包名称换了
for f in $(find ./packages -name "package.json"); do
sed -i '' -e 's/\"name\": \"amis/\"name\": \"@fex\/amis/g' $f
sed -i '' -e 's/\"amis-/\"@fex\/amis-/g' $f
done
# 把代码里面import的部分换成内部包名称
for f in $(find ./packages/*/lib -type f -name "*.[tj]s"); do
sed -i '' -e "s/\'amis/\'@fex\/amis/g" $f
done
for f in $(find ./packages/*/esm -type f -name "*.[tj]s"); do
sed -i '' -e "s/\'amis/\'@fex\/amis/g" $f
done
npm publish --workspaces --registry=http://registry.npm.baidu-int.com --ignore-scripts
cd ..
rm -rf npm
TypeScript
1
https://gitee.com/wangjinhang/amis.git
git@gitee.com:wangjinhang/amis.git
wangjinhang
amis
amis
master

搜索帮助