1. fork上游仓库
fork仓库https://github.com/apache/dubbo-js
git clone已fork的仓库 https://github.com/xxx/dubbo-js.git
2. typescript编译打包
进入到./packages/dubbo
子目录
修改tsconfig.json
新增
"compilerOptions": {
// ...
"allowJs": true
}
安装typescript进行代码编译
npm install typescript -g
npm install --save-dev @types/node
rm -rf ./es7 # 删除之前编译的目录
tsc
3. npm包发布
然后登陆npm账号进行发布,有修改的发布需要修改package.json版本号
npm login
npm publish
4. merge上游仓库master分支最新代码
git remote -v
git remote add upstream https://github.com/apache/dubbo-js
git fetch upstream
git merge upstream/master
git push
其它分支改下命令git merge upstream/其它分支
即可。
网友评论