# nlts

> CommandLine Tool for Node LTS

Latest version **1.0.3** (published 2020-07-10) · ISC license · 0 weekly downloads

## Install

```sh
npm install nlts
pnpm add nlts
yarn add nlts
bun add nlts
```

Provides the command `nlts`.

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.3 |
| Published | 2020-07-10 |
| First published | 2020-07-10 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 6 |
| Unpacked size | 680 KB |
| Known vulnerabilities | 0 (+25 in 1 direct dependencies) |
| Install scripts | no |
| Author | mojie |
| Maintainers | sunjunjie |
| Keywords | Node, LTS |

## Links

- npm: https://www.npmjs.com/package/nlts
- Repository: https://gitlab.iblack7.com/G000076/L0-R5-T000076
- npm.io page: https://npm.io/package/nlts

## Dependencies (6)

- [axios](https://npm.io/package/axios.md) ^0.19.2
- [cli-color](https://npm.io/package/cli-color.md) ^2.0.0
- [cli-table](https://npm.io/package/cli-table.md) ^0.3.1
- [commander](https://npm.io/package/commander.md) ^5.1.0
- [terminal-link](https://npm.io/package/terminal-link.md) ^2.1.1
- [compare-versions](https://npm.io/package/compare-versions.md) ^3.6.0

## Alternatives

- [@expo/fingerprint](https://npm.io/package/@expo/fingerprint.md) — 6.2M weekly downloads
- [@azure/monitor-opentelemetry-exporter](https://npm.io/package/@azure/monitor-opentelemetry-exporter.md) — 850.0K weekly downloads
- [@azure/monitor-opentelemetry](https://npm.io/package/@azure/monitor-opentelemetry.md) — 624.0K weekly downloads
- [@posthog/ai](https://npm.io/package/@posthog/ai.md) — 423.3K weekly downloads
- [fakefilter](https://npm.io/package/fakefilter.md) — 63.9K weekly downloads

## Recent versions

- 1.0.3 (latest) — 2020-07-10
- 1.0.2 — 2020-07-10
- 1.0.1 — 2020-07-10
- 1.0.0 — 2020-07-10

## README

# L0-R5-T000076
    项目编号:
      L0-R5-T000076
    项目名称:
      LTS 查看工具
    项目说明:
      实现 Node.js 历代 LTS 版本维护情况
    项目技术栈说明:
      Node.js + axios「学习  HTTP 网络请求收发」

## LTS 查看工具
### 知识点
1. axios发送HTTP网路请求
```
const axios = require('axios');
async function query(url) {
    const { data } = await axios.get(url);
    console.log(data);
}
const url = 'https://www.baidu.com/';
query(url);

```

2. 解析process.argv
``process.argv.slice(2)``后为node xx.js 后面的参数 
```
console.log(process.argv.slice(2));

/************* console.log **********/

node bin/nlts.js 12.15 -l
['12.15', '-l']
```
3. 主逻辑
* 获取所有的Node 版本
* 把目标版本的 LTS 都挑选出来
* 过滤字段
* 建立表格

### Npm 发布流程
```
npm login
npm publish
```

### 实际运行结果
1. ``$ nlts -h``  ``$ nlts -V``
![](./asset/1.png)

2. ``$ nlts 11.2`` ``$ nlts -l 11.2``
![](./asset/2.png)

### 版本信息
#### 1.0.0 
* 实现 Node.js 历代 LTS 版本维护情况
#### 1.0.1 
* 添加解析version为任意版本号，即可以缩小版本范围``$ nlts 12.5``
#### 1.0.2 
* 添加本地数据，由于获取网络慢 ``$ nlts 12.5 -l``直接访问本地数据。
* 使用commander重新构建

#### 1.0.3 
* 修改bug，axios result 数据格式错误

---
_Source: https://npm.io/package/nlts · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
