Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-16851] CLI: force module project creation even if path already exists is not respected inside an app project

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionFixed
Resolution Date2014-04-18T21:55:50.000+0000
Affected Version/sRelease 3.2.3
Fix Version/s2014 Sprint 08, 2014 Sprint 08 Tooling, Release 3.3.0
ComponentsCLI
Labelsqe-3.2.3, qe-closed-3.3.0, qe-testadded
ReporterOlga Romero
AssigneeChris Barber
Created2014-04-16T16:31:47.000+0000
Updated2014-06-19T12:43:00.000+0000

Description

It is not a regression. This issue occurs only if a module project is being created inside an app project.

To reproduce

1. Create a project, using
ti create 
Enter all prompted options 2. Inside the project's directory run
ti create -t module
Enter all prompted options 3. Run
ti create -f -t module
use same id and name

Actual result

[ERROR] Failed to run command "create"
[ERROR] Error: EEXIST, file already exists '/Users/oromero/dream/snow/module'
    at fs.mkdirSync (fs.js:642:18)
    at exports.run (/Users/oromero/Library/Application Support/Titanium/mobilesdk/osx/3.2.3.v20140415094118/blackberry/cli/commands/_create.js:68:7)
    at ModuleCreator.<anonymous> (/Users/oromero/Library/Application Support/Titanium/mobilesdk/osx/3.2.3.v20140415094118/cli/commands/create.js:373:21)
    at CLI._fireHookCallback (/usr/local/lib/node_modules/titanium/lib/hook.js:245:12)
    at /usr/local/lib/node_modules/titanium/lib/hook.js:224:10
    at /usr/local/lib/node_modules/titanium/node_modules/async/lib/async.js:232:13
    at /usr/local/lib/node_modules/titanium/node_modules/async/lib/async.js:142:25
    at /usr/local/lib/node_modules/titanium/node_modules/async/lib/async.js:229:17
    at /usr/local/lib/node_modules/titanium/node_modules/async/lib/async.js:556:34
    at /usr/local/lib/node_modules/titanium/lib/hook.js:215:9


Note: If a module project created outside an app project, force to create option works as expected.

Comments

  1. Chris Barber 2014-04-18

    This works now that TIMOB-10752 is done, but I have idea WHY you would want to do this.
  2. Olga Romero 2014-04-21

    it does work :) Mac osx 10.9.2 Maverics Node.JS Version: v0.10.13 NPM Version: 1.3.2 ├── acs@1.0.14 ├── alloy@1.3.1 ├── node-appc@0.2.0 ├── npm@1.3.2 ├── titanium@3.2.3-beta2 └── titanium-code-processor@1.1.1-beta1
  3. Olga Romero 2014-04-21

    This is the Titanium SDK build I used 3.3.0.v20140418162516

JSON Source