# @opensumi/vscode-ripgrep

> Downloads the ripgrep binary shipped in OpenSumi

Latest version **1.4.0** (published 2021-12-30) · MIT license · 0 weekly downloads

> **Deprecated.** This package is deprecated.

## Install

```sh
npm install @opensumi/vscode-ripgrep
pnpm add @opensumi/vscode-ripgrep
yarn add @opensumi/vscode-ripgrep
bun add @opensumi/vscode-ripgrep
```

## Health

**Score 10/100 (F)** — status: deprecated.

Negative: deprecated.

## Facts

| | |
|---|---|
| Version | 1.4.0 |
| Published | 2021-12-30 |
| First published | 2021-12-23 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 9.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | yes |
| Maintainers | jinboker, ensorrow, sakuraash, erha19, lengthmin |

## Links

- npm: https://www.npmjs.com/package/@opensumi/vscode-ripgrep
- Repository: https://github.com/opensumi/vscode-ripgrep
- Homepage: https://github.com/opensumi/vscode-ripgrep#readme
- Issues: https://github.com/opensumi/vscode-ripgrep/issues
- npm.io page: https://npm.io/package/@opensumi/vscode-ripgrep

## Dependencies (1)

- [@types/node](https://npm.io/package/@types/node.md) ^10.12.0

## Recent versions

- 1.4.0 (latest) — 2021-12-30
- 1.3.2-patch.2 — 2021-12-29
- 1.3.2-patch.1 — 2021-12-29
- 1.3.2 — 2021-12-23
- 1.3.2-beta.3 — 2021-12-23
- 1.3.2-beta.2 — 2021-12-23
- 1.3.2-beta.1 — 2021-12-23

## README

# @opensumi/vscode-ripgrep

`vscode-ripgrep` 对应的预编译包，因 `ripgrep` 通过 `github` 在国内下载有很大失败率，所以发布预编译包，并通过国内 cdn 下载。

## 注意

* 同版本号的 `vscode-ripgrep` 下载安装的 `ripgrep` 版本号必须一致

## 实现原理

1. 运行 `./scripts/generatePreBuiltPkg.js` 生成 `@opensumi/vscode-ripgrep-prebuilt` 包。
    在这一步会自动下载 <https://github.com/microsoft/ripgrep-prebuilt/releases> 中的编译好的 `ripgrep` 文件下载到 `./prebuilt/build/` 目录。
2. 在 `postinstall` 时下载 CDN 上的 `@opensumi/vscode-ripgrep-prebuilt` 对应平台的 `ripgrep` 并解压缩到 `./bin/` 目录
3. 通过 `rgPath` 拿到 `ripgrep` 即可执行

## 发包步骤

1. 执行 `npm install`。
2. 修改 `package.json` 的 `rgVersion` 字段为 <https://github.com/microsoft/ripgrep-prebuilt/releases> 的 tag 号。
3. 修改 `package.json` 的 `version` 字段。
4. 首先发布 `@opensumi/vscode-ripgrep-prebuilt`。
   1. 执行 `node ./scripts/generatePreBuiltPkg.js`
   2. 打开到 `prebuilt` 目录，执行 `npm publish`。
5. 再回到当前的 `vscode-ripgrep` 目录，执行 `npm publish`。

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