From 92178b3fa385a4064cd52e0d23a0c9508f32a931 Mon Sep 17 00:00:00 2001 From: Lellansin Date: Wed, 24 May 2017 13:07:53 +0800 Subject: [PATCH] section: zh-cn, fix bad URL --- sections/zh-cn/event-async.md | 10 +++++----- sections/zh-cn/io.md | 18 +++++++++--------- sections/zh-cn/js-basic.md | 10 +++++----- sections/zh-cn/os.md | 2 +- 4 files changed, 20 insertions(+), 20 deletions(-) diff --git a/sections/zh-cn/event-async.md b/sections/zh-cn/event-async.md index dd882ef..74a7332 100644 --- a/sections/zh-cn/event-async.md +++ b/sections/zh-cn/event-async.md @@ -1,10 +1,10 @@ # 事件/异步 -* [`[Basic]` Promise](https://github.com/ElemeFE/node-interview/blob/master/sections/event-async.md#promise) -* [`[Doc]` Events (事件)](https://github.com/ElemeFE/node-interview/blob/master/sections/event-async.md#events) -* [`[Doc]` Timers (定时器)](https://github.com/ElemeFE/node-interview/blob/master/sections/event-async.md#timers) -* [`[Point]` 阻塞/异步](https://github.com/ElemeFE/node-interview/blob/master/sections/event-async.md#阻塞异步) -* [`[Point]` 并行/并发](https://github.com/ElemeFE/node-interview/blob/master/sections/event-async.md#并行并发) +* [`[Basic]` Promise](/sections/zh-cn/event-async.md#promise) +* [`[Doc]` Events (事件)](/sections/zh-cn/event-async.md#events) +* [`[Doc]` Timers (定时器)](/sections/zh-cn/event-async.md#timers) +* [`[Point]` 阻塞/异步](/sections/zh-cn/event-async.md#阻塞异步) +* [`[Point]` 并行/并发](/sections/zh-cn/event-async.md#并行并发) ## 简述 diff --git a/sections/zh-cn/io.md b/sections/zh-cn/io.md index 0c021b7..d9bf669 100644 --- a/sections/zh-cn/io.md +++ b/sections/zh-cn/io.md @@ -1,12 +1,12 @@ # IO -* [`[Doc]` Buffer](https://github.com/ElemeFE/node-interview/blob/master/sections/io.md#buffer) -* [`[Doc]` String Decoder (字符串解码)](https://github.com/ElemeFE/node-interview/blob/master/sections/io.md#string-decoder) -* [`[Doc]` Stream (流)](https://github.com/ElemeFE/node-interview/blob/master/sections/io.md#stream) -* [`[Doc]` Console (控制台)](https://github.com/ElemeFE/node-interview/blob/master/sections/io.md#console) -* [`[Doc]` File System (文件系统)](https://github.com/ElemeFE/node-interview/blob/master/sections/io.md#file) -* [`[Doc]` Readline](https://github.com/ElemeFE/node-interview/blob/master/sections/io.md#readline) -* [`[Doc]` REPL](https://github.com/ElemeFE/node-interview/blob/master/sections/io.md#repl) +* [`[Doc]` Buffer](/sections/zh-cn/io.md#buffer) +* [`[Doc]` String Decoder (字符串解码)](/sections/zh-cn/io.md#string-decoder) +* [`[Doc]` Stream (流)](/sections/zh-cn/io.md#stream) +* [`[Doc]` Console (控制台)](/sections/zh-cn/io.md#console) +* [`[Doc]` File System (文件系统)](/sections/zh-cn/io.md#file) +* [`[Doc]` Readline](/sections/zh-cn/io.md#readline) +* [`[Doc]` REPL](/sections/zh-cn/io.md#repl) # 简述 @@ -285,7 +285,7 @@ int printf(FILE *stream, 要打印的内容) 当你使用 ssh 在远程服务器上运行一个命令的时候, 在服务器上的命令输出虽然也是写入到服务器上 shell 的 stdout, 但是这个远程的 shell 是从 sshd 服务上 fork 出来的, 其 stdout 是继承自 sshd 的一个 fd, 这个 fd 其实是个 socket, 所以最终其实是写入到了一个 socket 中, 通过这个 socket 传输你本地的计算机上的 shell 的 stdout. -如果你理解了上述情况, 那么你也就能理解为什么守护进程需要关闭 stdio, 如果切到后台的守护进程没有关闭 stdio 的话, 那么你在用 shell 操作的过程中, 屏幕上会莫名其妙的多出来一些输出. 此处对应[守护进程](https://github.com/ElemeFE/node-interview/blob/master/sections/process.md#守护进程)的 C 实现中的这一段: +如果你理解了上述情况, 那么你也就能理解为什么守护进程需要关闭 stdio, 如果切到后台的守护进程没有关闭 stdio 的话, 那么你在用 shell 操作的过程中, 屏幕上会莫名其妙的多出来一些输出. 此处对应[守护进程](/sections/zh-cn/process.md#守护进程)的 C 实现中的这一段: ```c for (; i < getdtablesize(); ++i) { @@ -301,7 +301,7 @@ console.log(process.stdout.fd); // 1 console.log(process.stderr.fd); // 2 ``` -在上一节中的 [在 IPC 通道建立之前, 父进程与子进程是怎么通信的? 如果没有通信, 那 IPC 是怎么建立的?](https://github.com/ElemeFE/node-interview/blob/master/sections/process.md#q-child) 中使用环境变量传递 fd 的方法, 这么看起来就很直白了, 因为传递 fd 其实是直接传递了一个整型数字. +在上一节中的 [在 IPC 通道建立之前, 父进程与子进程是怎么通信的? 如果没有通信, 那 IPC 是怎么建立的?](/sections/zh-cn/process.md#q-child) 中使用环境变量传递 fd 的方法, 这么看起来就很直白了, 因为传递 fd 其实是直接传递了一个整型数字. ### 如何同步的获取用户的输入? diff --git a/sections/zh-cn/js-basic.md b/sections/zh-cn/js-basic.md index b778d42..36010a3 100644 --- a/sections/zh-cn/js-basic.md +++ b/sections/zh-cn/js-basic.md @@ -1,10 +1,10 @@ # Javascript 基础问题 -* [`[Basic]` 类型判断](https://github.com/ElemeFE/node-interview/blob/master/sections/js-basic.md#类型判断) -* [`[Basic]` 作用域](https://github.com/ElemeFE/node-interview/blob/master/sections/js-basic.md#作用域) -* [`[Basic]` 引用传递](https://github.com/ElemeFE/node-interview/blob/master/sections/js-basic.md#引用传递) -* [`[Basic]` 内存释放](https://github.com/ElemeFE/node-interview/blob/master/sections/js-basic.md#内存释放) -* [`[Basic]` ES6 新特性](https://github.com/ElemeFE/node-interview/blob/master/sections/js-basic.md#es6-新特性) +* [`[Basic]` 类型判断](/sections/zh-cn/js-basic.md#类型判断) +* [`[Basic]` 作用域](/sections/zh-cn/js-basic.md#作用域) +* [`[Basic]` 引用传递](/sections/zh-cn/js-basic.md#引用传递) +* [`[Basic]` 内存释放](/sections/zh-cn/js-basic.md#内存释放) +* [`[Basic]` ES6 新特性](/sections/zh-cn/js-basic.md#es6-新特性) ## 简述 diff --git a/sections/zh-cn/os.md b/sections/zh-cn/os.md index a8d4c31..a8ccf5d 100644 --- a/sections/zh-cn/os.md +++ b/sections/zh-cn/os.md @@ -35,7 +35,7 @@ $ ps -x 23733 ? Ssl 2:53 PM2 v1.1.2: God Daemon ``` -其中为 `?` 的是没有依赖 TTY 的进程, 即[守护进程](https://github.com/ElemeFE/node-interview/blob/master/sections/process.md#%E5%AE%88%E6%8A%A4%E8%BF%9B%E7%A8%8B). +其中为 `?` 的是没有依赖 TTY 的进程, 即[守护进程](/sections/zh-cn/process.md#%E5%AE%88%E6%8A%A4%E8%BF%9B%E7%A8%8B). 在 Node.js 中你可以通过 stdio 的 isTTY 来判断当前进程是否处于 TTY (如终端) 的环境.