NativeScript / NativeScript/nativescript-cli

`tns migrate` clears the platforms and next build fails if a custom android runtime was used

未关闭
#4,877 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

known limitation
主要语言
JavaScript
星标
1.1k
派生
204
平均合并
1 天 9 小时
30 天内合并 PR
8

描述

If tns migrate was ran on an app with a custom android runtime (tns platform add android --frameworkPath /test/runtime.tgz), next build would fail. This is because the platforms/android folder is deleted and the version of the tns-android package was previously set in the package.json to the literal next version of the runtime. This runtime, of course, couldn't be found in npm and thus the build fails. Couldn't runtimes added with --frameworkPath be handled differently and in some way marked as such in the package.json? Also, couldn't a simple gradlew clean do the dirty work instead of deleting the whole platforms folder?

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

首先跟踪 tns migrate 的入口点及其对 --frameworkPath 的处理,然后检查 package.json 如何记录 tns-android 的版本,以及如何删除 platforms/android。将该行为与提到的 gradlew clean 选项进行比较。当迁移使用自定义 runtime 的应用能够保留可用的 runtime 引用,并且下一次构建成功时,即表示完成。

由索引模型根据 Issue 内容生成。

评估

技术栈
android, javascript
领域
cli, mobile-dev
Issue 类型
缺陷
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
35/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。