Can you use a rust binary crate as a library?

This page summarizes the projects mentioned and recommended in the original post on /r/rust

CodeRabbit: AI Code Reviews for Developers
Revolutionize your code reviews with AI. CodeRabbit offers PR summaries, code walkthroughs, 1-click suggestions, and AST-based analysis. Boost productivity and code quality across all major languages with each PR.
coderabbit.ai
featured
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
www.saashub.com
featured
  1. fd

    A simple, fast and user-friendly alternative to 'find'

    I'd like to use fd's features in a program I am writing. Is it possible to use a crate with a main.rs and no lib.rs as a library? Is there some trick I can do to make that work?

  2. CodeRabbit

    CodeRabbit: AI Code Reviews for Developers. Revolutionize your code reviews with AI. CodeRabbit offers PR summaries, code walkthroughs, 1-click suggestions, and AST-based analysis. Boost productivity and code quality across all major languages with each PR.

    CodeRabbit logo
  3. Cargo

    The Rust package manager

    Crates like bindgen work around #1982 still being unsolved by making the feature for the CLI a default feature and expecting things which depend on the library to opt out of default features.

  4. rfcs

    RFCs for changes to Rust

    As it would be a change to Cargo.toml, it requires an RFC and there's currently one under discussion so the first thing you'd want to do is look through what's been said there.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts

  • Can Rust do every low level stuff C/C++ do?

    7 projects | /r/rust | 9 Mar 2022
  • I started daily driving Manjaro a while ago. Loving it so far

    3 projects | /r/ManjaroLinux | 29 Oct 2021
  • Rust Coreutils 0.0.29 Release

    1 project | news.ycombinator.com | 19 Jan 2025
  • Watchexec: Execute commands in response to file modifications

    1 project | news.ycombinator.com | 6 Aug 2024
  • Eza: A modern, maintained replacement for ls

    15 projects | news.ycombinator.com | 21 Jul 2024