Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-28137] CLI: EEXIST error when reinstalling an SDK/module

GitHub Issuen/a
TypeBug
PriorityNone
StatusClosed
ResolutionFixed
Resolution Date2020-09-15T17:35:27.000+0000
Affected Version/stitanium 5.2.4
Fix Version/stitanium 5.2.5
ComponentsCLI
Labelsn/a
ReporterEwan Harris
AssigneeEwan Harris
Created2020-09-15T15:57:18.000+0000
Updated2020-09-15T17:42:15.000+0000

Description

Description

When installing an SDK if a module has symlinks and that version of the module already existed on the system we will get the below error. I think we need to check if the file exists and either remove it first, or not create the symlink.
Error: EEXIST: file already exists, symlink 'Versions/Current/Resources' -> '/Users/awam/Library/Application Support/Titanium/modules/iphone/ti.applesignin/2.0.0/TiApplesignin.xcframework/ios-arm64_x86_64-maccatalyst/TiApplesignin.framework/Resources'
    at Object.symlinkSync (fs.js:909:3)
    at ReadStream.readStream.on (/Users/awam/git/titanium/node_modules/node-appc/lib/zip.js:94:11)
    at ReadStream.emit (events.js:198:13)
    at endReadableNT (_stream_readable.js:1145:12)
    at process._tickCallback (internal/process/next_tick.js:63:19)

Steps to reproduce

1. Install the latest SDK ti sdk install -b master -d 2. Remove that SDK 3. Install it again ti sdk install -b master -d

Actual

Above error

Expected

No error

Comments

  1. Ewan Harris 2020-09-15

    https://github.com/appcelerator/node-appc/pull/285
  2. Lokesh Choudhary 2020-09-15

    Verified the fix with CLI 8.1.1-master.9

JSON Source