Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-24976] Appc-CLI: Creating a new module throws error, but succeeds

GitHub Issuen/a
TypeBug
PriorityNone
StatusOpen
ResolutionUnresolved
Affected Version/sn/a
Fix Version/sn/a
Componentsn/a
Labelscb-tooling
ReporterHans Knöchel
AssigneeUnknown
Created2017-07-18T16:17:20.000+0000
Updated2020-01-30T23:11:40.000+0000

Description

When creating a new module with the appc new -d . -n test --id com.example.test command (from the Wiki), an error is thrown, but the generated module looks ok:
Hans-Macbook-Pro:Desktop hknoechel$ appc new -d . -n test --id com.example.test
Appcelerator Command-Line Interface, version 6.2.2
Copyright (c) 2014-2017, Appcelerator, Inc.  All Rights Reserved.

? What type of project are you creating? Titanium Module (timodule)
? Do you want to overwrite? Yes
MobileWeb platform has been deprecated in 5.4.0 and will be removed in 7.0.0.
An uncaught exception was thrown!
EINVAL: invalid argument, rename 'test' -> '.'
EINVAL: invalid argument, rename 'test' -> '.'
I never used that combination of arguments so far, it was ported from ti create -d . -n test --id com.example.test. If there is a different way to create a module with given name, ID and directory, let me know and resolve as invalid!

Comments

  1. Ewan Harris 2017-07-18

    [~hknoechel] This is probably due to CLI-424. Titanium CLI and Appc CLI have differing behaviour on the -d flag * Titanium says workspace directory, so you're saying create it in my cwd * Appc CLI says project directory, so you're saying create it in a folder called . Drop the -d flag and you'll be good, in this instance it's unnecessary from appc-cli perspective unless you want to have the folder named differently to the module name Also add --type timodule if you want to avoid the prompt
  2. Hans Knöchel 2017-07-18

    Cool, thx! I am fine with the prompt, just wonder if the EINVAL: invalid argument, rename 'test' -> '.' could be prevented.

JSON Source