westwood

Crates.iowestwood
lib.rswestwood
version0.0.0-alpha.1
created_at2025-06-23 00:36:36.87253+00
updated_at2025-06-23 00:36:36.87253+00
descriptionA C source code linter for Purdue's CS 240 course
homepage
repositoryhttps://github.com/kdkasad/westwood
max_upload_size
id1722067
size177,749
Kian Kasad (kdkasad)

documentation

README

Westwood

GitHub Actions Workflow Status License badge

The successor to eastwood-tidy, a linter for Purdue's CS 240 course.

Westwood is a linter for C code. It's written in Rust and uses the Tree-sitter parser library. Westwood is entirely human-made and contains no AI-generated content.

Status

This project is very new and is currently a work in progress. Development began on March 6, 2025. If there haven't been any commits made in the last few months, this project has probably been abandoned.

For users

Westwood is still under active development, so we do not yet provide releases. You'll have to follow one of the following methods to get a usable copy of Westwood.

Download from the CI workflow

Westwood's repository has a GitHub Actions workflow which builds binaries for many platforms for each Pull Request. These may not reflect the latest version of Westwood, but are likely the easiest way to obtain a copy.

  1. Go to the Build Westwood binaries action.
  2. Select a recent run.
  3. Download the artifact matching your platform.

Build from sources (using cargo install)

  1. You will need to have Rust and Cargo installed.
  2. Run the following command:
    $ cargo install --git https://github.com/kdkasad/westwood
    

To uninstall Westwood if installed with this method, just run:

$ cargo uninstall westwood

Build from sources (manually)

  1. You'll need to have Rust and Cargo installed.

  2. Clone Westwood's sources:

    $ git clone https://github.com/kdkasad/westwood
    
  3. Navigate into the repository.

    $ cd westwood
    
  4. Build in release mode.

    $ cargo build -r
    
  5. The compiled executable will be located at target/release/westwood.

For developers

Contribution guidelines

  1. Be respectful and diligent.
  2. Include documentation and unit tests.
  3. Do not contribute AI-generated content. AI-generated code is based on real humans' works, but does not contain any attribution to the people or organizations from which it is derived.

Tooling and editor integrations

To make writing Tree-sitter queries and inline C tests easier, integrations for Neovim have been added. Ensure that you have the exrc option enabled in Neovim and start Neovim in the root of this repository. This will load the .nvim.lua configuration script in this directory, which itself configures Tree-sitter by loading additional queries to provide syntax highlighting for C code and Tree-sitter queries inside of string literals in the Rust code.

Copyright, license, and contact

Westwood is written and copyrighted by Kian Kasad and its contributors. It is made a available under the terms of the Apache License 2.0.

If you have any questions about Westwood, please reach out to me (Kian). I will be happy to talk your ear off answer them.

Commit count: 112

cargo fmt