Skip to content

fix(packager): normalize Windows path separators in zip entries#180

Open
ShubhamS2005 wants to merge 1 commit intoRocketChat:masterfrom
ShubhamS2005:Windows-rc-apps-deploy-fails
Open

fix(packager): normalize Windows path separators in zip entries#180
ShubhamS2005 wants to merge 1 commit intoRocketChat:masterfrom
ShubhamS2005:Windows-rc-apps-deploy-fails

Conversation

@ShubhamS2005
Copy link

@ShubhamS2005 ShubhamS2005 commented Mar 15, 2026

Fix: Windows deployment - normalize TypeScript import paths

Problem

When deploying Rocket.Chat Apps on Windows using rc-apps deploy, the packaging step fails with a TypeScript error:
File 'RoomPersistence.ts' not found.

  • The project compiles correctly with tsc.
  • Deploys fine on macOS.
  • The error occurs only when the main app entry imports additional modules.
  • Root cause: the CLI Language Service cannot resolve Windows-style \ paths during packaging.

Solution

  • Normalize all module paths in the packager to use POSIX-style / separators.
  • Ensures TypeScript can locate all source files on Windows.
  • Cross-platform safe: macOS and Linux deployments remain unaffected.
  • But this thing require CLI installation fails on Windows because package.json scripts use Unix rm command #179 to be done , as it give Cross-Platforem safe work with help of remref (in Windows):
  • "postpack": "rimraf oclif.manifest.json",
    "prepack": "rimraf lib && tsc && oclif-dev manifest && oclif-dev readme",
    "prepare": "rimraf lib && tsc",

Impact

  • Windows deployments now succeed even with additional module imports in the main app entry.
  • Deployment behavior is consistent across Windows, macOS, and Linux.

Testing

  • Verified packaging succeeds on Windows with module imports.
  • Verified macOS deployment continues to work as expected.

Related Issue

Screenshot 2026-03-15 223841

Final Result

Screenshot 2026-03-15 223552

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Windows: rc-apps deploy fails with File 'X.ts' not found while tsc compiles successfully

1 participant