Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-23247] CLI: ti clean does not work for native module projects

GitHub Issuen/a
TypeNew Feature
PriorityHigh
StatusClosed
ResolutionFixed
Resolution Date2018-05-01T13:40:04.000+0000
Affected Version/sRelease 5.3.0
Fix Version/sRelease 7.3.0
ComponentsCLI
Labelsn/a
ReporterKota Iguchi
AssigneeChristopher Williams
Created2016-04-20T11:43:21.000+0000
Updated2018-06-22T15:42:41.000+0000

Description

ti clean failed when you run it under the native module project directory. It could cause issue when CMake fails and leaves broken cache files. There's no way to remove it from Titanium CLI now.
> appc new -n test --id com.example.test
> cd test\windows
> ti clean
[ERROR] Invalid project directory "."
Use the --project-dir property to specify the project's directory

Comments

  1. Christopher Williams 2016-04-20

    [~kota] Looks like we don't support ti clean for module projects for any platform. So this is a larger CLI issue. So we may want to mark this invalid or turn it into a feature request for the CLI to support clean on module projects.
  2. Christopher Williams 2018-02-06

    iOS/Android master (7.2.0): https://github.com/appcelerator/titanium_mobile/pull/9807 Windows master (7.2.0): https://github.com/appcelerator/titanium_mobile_windows/pull/1178
  3. Christopher Williams 2018-05-01

    [~bimmel] This is merged to master of the SDK (target 7.2.0). It may be useful to note in docs that this command was added but to be careful if you keep historical versions of your module in your dist directory. Hans and I discussed it here: https://github.com/appcelerator/titanium_mobile/pull/9807#discussion_r170652386 Basically there are some community members who keep old versions of their modules in their dist directory and check that into source control (or don't, which is way worse). If they run the new clean command that directory is part of what gets wiped. It is poor practice to keep releases there as a means of "archiving" them. Releases should be published to a stable location (Github release, S3, whatever). But if the developer wants to retain old releases in the module, they may want to consider using a different folder or being careful to check/commit the zip in to SCM before cleaning (and then being careful not to commit the deletion of the files, though with SCM they can easily get them back).
  4. Samir Mohammed 2018-06-22

    *Closing ticket*. fix can be seen in SDK Version: 7.3.0.v20180618062809 on Windows. Fix can also be seen on Android and IOS in SDK version: 7.3.0.v20180530072516. Fix was tested with the steps mentioned above.

JSON Source