查看 Node 所有版本:
查看所有 Node.JS 的版本: https://nodejs.org/dist/index.json
下载到本地:
$ curl -O https://nodejs.org/dist/index.json
Powershell:
# 查询 npm 为 7 版本的对象
PS> $ [System.IO.File]::ReadAllText("./index.json") | ConvertFrom-Json | Where-Object npm -Like "7*"
# 查询最开始5条
PS> $ [System.IO.File]::ReadAllText("./index.json") | ConvertFrom-Json | Select-Obejct -First 5
# silent mode(静默模式): 也就是不将 index.json 下载下来
PS> $ curl -s https://nodejs.org/dist/index.json | ConvertFrom-Json | ...
本文介绍如何使用curl命令和PowerShell脚本查询Node.js的所有版本信息,并提供了查询特定版本及前几个版本的具体方法。
149

被折叠的 条评论
为什么被折叠?



