Run WeChat Web Dev Tools on Linux: Step‑by‑Step Guide with NW.js & Wine

Learn how to install and configure the WeChat Web Developer Tools on Linux by downloading NW.js, copying necessary files, fixing module name case issues, creating a run‑detectors file, installing Wine, and adjusting project settings for smooth development.

MaGe Linux Operations
MaGe Linux Operations
MaGe Linux Operations
Run WeChat Web Dev Tools on Linux: Step‑by‑Step Guide with NW.js & Wine

1. Download NW.js

Download the NW.js SDK from http://nwjs.io/ and extract it.

2. Copy WeChat Web Developer Tool files into NW.js

Copy package.nw, icon.ico, and the WeChat Web Developer Tool executable (or its extracted contents) from the Windows installation folder into the extracted NW.js directory.

3. Modify code to fix module names

Run NW.js from the terminal with ./nw. When errors such as “Cannot find module …” appear, edit the indicated files to correct case‑sensitive module names (e.g., change appServiceConfig to appserviceConfig).

4. Create a run-detectors file

In the WeChat mini‑program project folder, create an empty file named run-detectors. Linux treats files without extensions as directories, so this file prevents “file not found” errors.

5. Install Wine

Install Wine with sudo apt-get install wine. Then run wcc.exe (located in /home/username/.config/微信web开发者工具/WeappVendor) using Wine’s right‑click “Open with Wine” option, installing any required dependencies.

6. Load the project

Before loading, run wcc.exe and wcsc.exe under Wine once; otherwise the first load may fail. After the first load, compilation may take 3–10 seconds, then speeds up due to caching. Rename wcc.exe and wcsc.exe to remove the .exe extension, and edit the paths in commit/build.js, trans/transWxmlToJs.js, and utils/vendorManager.js accordingly.

7. Configure the editor

Use WebStorm (or another IDE) and add wxss to the CSS file type and wxml to the HTML file type in the editor’s file‑type settings. Avoid using the built‑in editor’s edit function, which may cause errors.

Note that automatic refresh after file changes takes about 3–5 seconds for compilation.

Original Source

Signed-in readers can open the original source through BestHub's protected redirect.

Sign in to view source
Republication Notice

This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactadmin@besthub.devand we will review it promptly.

LinuxWeb DevelopmentWeChatNW.jsWine
MaGe Linux Operations
Written by

MaGe Linux Operations

Founded in 2009, MaGe Education is a top Chinese high‑end IT training brand. Its graduates earn 12K+ RMB salaries, and the school has trained tens of thousands of students. It offers high‑pay courses in Linux cloud operations, Python full‑stack, automation, data analysis, AI, and Go high‑concurrency architecture. Thanks to quality courses and a solid reputation, it has talent partnerships with numerous internet firms.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.