2 releases

0.1.9 May 11, 2025
0.1.8 May 10, 2025
0.1.7 Feb 16, 2025
0.1.6 Nov 18, 2024

#245 in Web programming

Download history 4/week @ 2025-02-25 4/week @ 2025-03-04 6/week @ 2025-03-11 215/week @ 2025-05-06 62/week @ 2025-05-13 4/week @ 2025-05-20

588 downloads per month

MIT license

39KB
855 lines

vsixHarvester

VSCode Extension Downloader in Rust

This Rust program reads the recommendations array from an extensions.json file and downloads the corresponding VSIX packages for Visual Studio Code extensions.

Features

  • Reads a list of extensions from extensions.json.
  • Downloads the latest version of each extension as a VSIX package.
  • Supports proxy configuration.
  • Option to force re-download even if the file already exists.
  • Provides verbose output for detailed logging.
  • Downloads a single extension by its ID.

Prerequisites

  • Rust and Cargo installed on your system. You can install them from rustup.rs.

Installation

cargo install vsixHarvester

Usage

vsixHarvester [OPTIONS]

Options

  • -i, --input <INPUT>: Path to the extensions.json file. Default is ./.vscode/extensions.json.
  • -d, --destination <DESTINATION>: Destination folder to save the VSIX files. Default is ./.vscode/extensions.
  • -f, --force: Force re-download even if the extension file already exists.
  • --proxy <PROXY>: Proxy URL to use for HTTP requests.
  • -v, --verbose: Enable verbose output for detailed logging.
  • -h, --help: Print help information.
  • -a, --arch <ARCHITECTURE>: OS architecture to install the extensions for.
  • -s, --single <EXTENSION_ID>: Download a single extension by its ID (e.g., publisher.extensionName). If this option is used, --input is ignored.

Example

vsixHarvester \
  --input ./your/path/to/extensions.json \
  --destination ./your/path/to/extensions \
  --force \
  --arch win32-x64 \
  --verbose

To download a single extension:

vsixHarvester \
  --single publisher.extensionName \
  --force \
  --arch win32-x64 \
  --destination ./extensions \
  --verbose
Architecture options
  • win32-x64
  • win32-arm64
  • darwin-x64
  • darwin-arm64
  • linux-x64
  • linux-arm64
  • alpine-x64
  • alpine-arm64
  • win32-ia32
  • linux-armhf
  • web

Platform-specific

extensions.json Format

The extensions.json file should have the following structure:

{
  "recommendations": [
    "publisher.extensionName",
    "anotherPublisher.anotherExtensionName",
    // Add more extensions as needed
  ]
}

Thanks

Dependencies

~42–77MB
~1.5M SLoC