Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[教程-图文] 关于在Window里面使用WSL(Liunx子系统)来开发gaea-editor #60

Open
jhoneybee opened this issue Jun 26, 2019 · 2 comments

Comments

@jhoneybee
Copy link

jhoneybee commented Jun 26, 2019

环境要求

  • 操作系统 Window 10 19H1或更高版本

开启Window中的liunx子系统功能

  1. 在控制面板-> 程序和功能中开启-子系统功能

image

  1. 在Window商城中下载对应的liunx镜像 - (我这边直接使用的Debian进行开发)

image

安装环境

git 安装命令

sudo apt-get install git 

nodejs 安装

# Using Debian, as root
curl -sL https://deb.nodesource.com/setup_12.x | bash -
apt-get install -y nodejs

下载源码&运行

以上默认已经安装好运行环境

# /mnt/d/ 表示是window下的d盘

cd  /mnt/d/dev/code/github
git clone https://github.com/ascoders/gaea-editor.git
cd gaea-editor 
npm install # 等待下载完成
npm run docs  # window浏览器会自动打开http://127.0.0.1:8000/地址提供预览

用vscode 或者其他编辑器打开d盘的gaea-editor 目录下的文件进行编辑保存即可

@625781186
Copy link

625781186 commented Jan 11, 2020

emmm..
因为我的win系统是ltsb版本 , 没有window store , 装好之后 系统太低 又不让装子系统 ..
所以无奈之下只能去看下 pri 的运行逻辑了 ..
SO :

在window下 提供一种更快捷的办法 :

(The second method) :

step 1:
Comment out this line :

image

step 2:
npm run docs

step 3:
Repair path parameters ( Beacuse the generated file path is error.)

const DocsWrapper = require('D:\\CodePro\\JS\\gaea-editor\\node_modules\\pri\\built\\built-in-plugins\\command-docs\\plugin\\docs-wrapper')
  .default;

import * as Doc0 from '..\\docs\\basic';
const Doc0Text = require('-!raw-loader!..\\docs\\basic');

image

@GitChenM
Copy link

emmm..
因为我的win系统是ltsb版本 , 没有window store , 装好之后 系统太低 又不让装子系统 ..
所以无奈之下只能去看下 pri 的运行逻辑了 ..
SO :

在window下 提供一种更快捷的办法 :

(The second method) :

step 1:
Comment out this line :

image

step 2:
npm run docs

step 3:
Repair path parameters ( Beacuse the generated file path is error.)

const DocsWrapper = require('D:\\CodePro\\JS\\gaea-editor\\node_modules\\pri\\built\\built-in-plugins\\command-docs\\plugin\\docs-wrapper')
  .default;

import * as Doc0 from '..\\docs\\basic';
const Doc0Text = require('-!raw-loader!..\\docs\\basic');

image

神奇,能不能转成其它的,用这样偏门的,很头疼啊。

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

No branches or pull requests

3 participants