(s: string, type: ts.server.Msg = ts.server.Msg.Err)
| 130 | } |
| 131 | |
| 132 | msg(s: string, type: ts.server.Msg = ts.server.Msg.Err) { |
| 133 | if (!this.loggingEnabled()) { |
| 134 | return; |
| 135 | } |
| 136 | |
| 137 | let prefix = ''; |
| 138 | if (!this.inGroup || this.firstInGroup) { |
| 139 | this.firstInGroup = false; |
| 140 | prefix = `${type} ${this.seq}`.padEnd(10) + `[${nowString()}] `; |
| 141 | } |
| 142 | const entry = prefix + s + '\n'; |
| 143 | |
| 144 | fs.writeSync(this.fd, entry); |
| 145 | |
| 146 | if (!this.inGroup) { |
| 147 | this.seq++; |
| 148 | } |
| 149 | } |
| 150 | } |