A fast package manager for NodeJS written in Rust.

Related tags

Miscellaneous click
Overview

click

A fast package manager for NodeJS written in Rust.

How fast?

Benchmark of bun vs click clean install: Benchmark of bun vs click

Based on benchmarks done with hyperfine, click is more or less the same speed as Bun for clean installs. Due to the nature of HTTP, it is hard to give an accurate answer as to who is "faster", as there are occassions where bun is faster than click. Once caching is implemented, I hope for it to be as fast if not faster than Bun.

What can it do?

At the moment it can perform an efficient clean install of a package which is stored in the {CACHE_DIR}/node-cache folder. This package manager does not yet utilize the cache or work as an out of the box package manager, see here for more details.

Why is it fast?

  • Efficient version resolution which minimizes the HTTP throughput by using {registry}/{package}/{version} instead of {registry}/{package} which has a significantly larger body size
  • Use of reqwest to create a HTTP connection pool
  • Parallel and asyncronous HTTP requests to the NPM Registry API
  • Use of the Accept: application/vnd.npm.install-v1+json; q=1.0, application/json; q=0.8, */* header which results in smaller HTTP body sizes
  • Duplicate avoidance by storing pre-installed versions in a HashMap for clean installs

What's missing?

These are the primary functioning features required for this to pass as a "NodeJS package manager". There are plenty more quality of life and utlility features that will be neccessary:

  • Use of the cache to avoid re-installing packages
  • Creation and maintainence of a package.json in the working directory
  • Creation and maintainence of a package-lock.json in the working directory as well as for each package in the cache
  • Creation and maintainence of a node_modules folder in the working directory that contains symlinks to the cached packages
  • An uninstall command
  • An update command
  • There is also an off case where some packages contain an operator at the end of their version like this < [email protected] > 1.1.2 which is not tolerated by semver
  • Use checksums to verify file downloads
  • Proper error handling everywhere
  • Checking in the cache if a version is not marked as latest when it should be - to save redownloading a package
You might also like...
Rust package for constructing and analyzing phylogenies.

Rust-Phylogeny, a Rust library for phylogenetic trees Currently this library provides three algorithms: UPGMA and Neighbor-Joining for constructing a

Solidity-Compiler Version Manager

Solidity Compiler Version Manager

SPWN extension manager.

XTND SPWN extension manager. Important Disclaimer As this will allow any module to run as builtins, with little to no limitations, use of XTND may be

A simple clipboard manager for wayland.

Wpilman A simple clipboard manager for wayland. Installation Just compile it yourself or install the AUR package: paru -S wlipman-git # or yay -S wlip

Wayland clipboard manager that will make you clap πŸ‘

Clapboard - clipboard manager that makes you clap πŸ‘ Clapboard is a simple clipboard manager for Wayland, built in Rust. It saves a history of your cl

A blazingly fast πŸ”₯ Discord bot written in Rust

rusty-bot πŸ¦€ A blazingly fast πŸ”₯ Discord bot written in Rust. Commands name use !rm count deletes old messages !meme subreddit sends a random meme

A fast, powerful and configurable interpreter written in Rust

brainfuck-interpreter Overview A fast, powerful and configurable interpreter written in Rust, which allows various options to meet different demends,

A blazinlgy fast πŸš€ transpiler written in rust πŸ¦€ that fixes (pun intended) your problems

Pissfix πŸš€ Pissfix is a blazingly fast πŸš€ programming language that transpiles to a "interesting" and not well known programming language called "Post

πŸš€ Fast and 100% API compatible postcss replacer, built in Rust

πŸš€ Fast and 100% API compatible postcss replacer, built in Rust

Comments
  • Possible rename

    Possible rename

    Click is already the name of a Python CLI-building library so I'd like to suggest a rename as this project is a CLI with the same name.

    I suggest:

    conch

    from:

    con: con aticus ch: ch anneling

    As the manager uses channels to work.

    opened by AquaQuokka 1
Owner
Sam
Programmer & content creator Business Enquiries: [email protected]
Sam
A shiny new package manager written in rust explicitly for gemlock/linux and it's distributions

Gem A shiny new package manager written in rust explicitly for gemlock/linux and it's distributions. List of content How to setup Systems Ubuntu Arch

Gemlock 1 Feb 22, 2022
πŸ₯³Yet another crate to create native nodejs addons :)

nodex Yet another crate to create native nodejs addons :) This crate aims to make creating native nodejs addons very easy and comfortable. It is in a

uuhan 4 Mar 29, 2022
Cargo - The Rust package manager

Cargo downloads your Rust project’s dependencies and compiles your project.

The Rust Programming Language 9.5k Jan 4, 2023
πŸ’‘ Use the right package manager by rust

n ?? Use the right package manager by rust ?? Inspired by ni Why ni is nice , but ni is based on Node. it is difficult to collaborate well with node v

SHEIN 3 Jul 24, 2023
basic multiple package manager

baka basic multiple package manager Docs Env baka_root_setting Windows: %USERPROFILE%/.baka/config Linux, Mac: $HOME/.baka/config baka_plugins (Just u

null 8 Dec 29, 2021
Wally is a modern package manager for Roblox projects inspired by Cargo

Wally is a package manager for Roblox inspired by Cargo (Rust) and npm (JavaScript). It brings the familiar, community-oriented world of sharing code from other communities into the Roblox ecosystem.

Uplift Games 194 Jan 3, 2023
Plow - The ontology package manager

Plow - Ontology package manager Plow is package management solution for OWL ontologies, with support for specifying dependencies between packages via

Field 33 12 Dec 21, 2022
A little bit fast and modern Ruby version manager written in Rust

A little bit fast and modern Ruby version manager written in Rust Features Pure Rust implementation not using ruby-build Cross-platform support (macOS

Takayuki Maeda 510 Jan 5, 2023
Fast and simple PHP version manager written in rust

[WIP] phpup (PHP-up): Fast and Simple PHP version manager ⚑ Fast and simple PHP version manager, written in rust Features No requirements for system P

null 27 Dec 25, 2022
DWARF packaging utility, written in Rust, supporting GNU extension and DWARF 5 package formats.

thorin thorin is an DWARF packaging utility for creating DWARF packages (*.dwp files) out of input DWARF objects (*.dwo files; or *.o files with .dwo

David Wood 19 Nov 16, 2022