Metadata-Version: 2.4
Name: fatou
Version: 0.9.0
Classifier: Development Status :: 3 - Alpha
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: MacOS
Classifier: Operating System :: Microsoft :: Windows
Classifier: Operating System :: POSIX :: Linux
Classifier: Programming Language :: Rust
Classifier: Topic :: Software Development :: Quality Assurance
Classifier: Topic :: Software Development
License-File: LICENSE
Summary: A language server, formatter, and linter for Julia
Keywords: julia,language-server,formatter,linter
Home-Page: https://fatou.dev
Author-email: Johan Larsson <johan@jolars.co>
License: MIT
Requires-Python: >=3.10
Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
Project-URL: Homepage, https://github.com/jolars/fatou
Project-URL: Repository, https://github.com/jolars/fatou

# Fatou <img src='https://raw.githubusercontent.com/jolars/fatou/main/assets/logo.png' align="right" width="139" />

[![Build and
Test](https://github.com/jolars/fatou/actions/workflows/build-and-test.yml/badge.svg?branch=main)](https://github.com/jolars/fatou/actions/workflows/build-and-test.yml)
[![Documentation](https://github.com/jolars/fatou/actions/workflows/docs.yml/badge.svg?branch=main)](https://fatou.dev/)
[![Open
VSX](https://img.shields.io/open-vsx/v/jolars/fatou?logo=vsix)](https://open-vsx.org/extension/jolars/fatou)
[![VS
Code](https://vsmarketplacebadges.dev/version-short/jolars.fatou.svg?logo=vsix)](https://marketplace.visualstudio.com/items?itemName=jolars.fatou)
[![PyPI
version](https://badge.fury.io/py/fatou.svg?icon=si%3Apython)](https://pypi.org/project/fatou/)
[![npm
version](https://badge.fury.io/js/@fatou-cli%2Ffatou-cli.svg?icon=si%3Anpm)](https://www.npmjs.com/package/fatou-cli)

A language server, formatter, and linter for [Julia](https://julialang.org) that
doesn't require running Julia itself. Fatou is written in Rust and is designed
to be fast, safe, and easy to integrate into editors and tooling. It is named
after the French mathematician Pierre Fatou, whose Fatou set is the complement
of the Julia set.

Fatou follows the rust-analyzer design (a lossless
[`rowan`](https://crates.io/crates/rowan) CST,
[`salsa`](https://crates.io/crates/salsa) for incremental computation, and
[`lsp-server`](https://crates.io/crates/lsp-server) for the language-server
transport).

## Installation

Fatou is available from several sources:

- **crates.io**: `cargo install fatou`
- **npm**: `npm install -g fatou-cli` (bundles a prebuilt binary)
- **PyPI**: `uv tool install fatou`/`pipx install fatou`
- **Prebuilt binaries**: from the [releases
  page](https://github.com/jolars/fatou/releases)
- **VS Code/Open VSX**: the **Fatou** extension
  ([Marketplace](https://marketplace.visualstudio.com/items?itemName=jolars.fatou),
  [Open VSX](https://open-vsx.org/extension/jolars/fatou)); also works in
  Positron

Runs on Linux, macOS, and Windows (x86_64 and arm64).

## Usage

```sh
fatou parse <file.jl>          # print the CST (stdin if no file)
fatou format <file.jl>         # format to stdout (stdin if omitted)
fatou format --check <dir>     # check formatting; non-zero exit if any differ
fatou lint --check <dir>       # lint
fatou lsp                      # run the language server on stdio
```

Configuration lives in `fatou.toml` (`[format]` line-width/indent-width,
`[lint]` select/ignore).

## Editor integration

The language server (`fatou lsp`) provides a broad set of features over stdio:
completion, hover, go-to-definition, find references and document highlights,
rename, document and workspace symbols, call and type hierarchy, signature help,
code actions, folding and selection ranges, document links, and semantic tokens,
alongside formatting (whole-document and range) and diagnostics (push and pull).
The **Fatou** extension for VS Code/Open VSX (and Positron)
([Marketplace](https://marketplace.visualstudio.com/items?itemName=jolars.fatou),
[Open VSX](https://open-vsx.org/extension/jolars/fatou)) bundles the binary and
starts the server automatically; see [`editors/code`](editors/code).
For Neovim and other editors, see the [editor setup
guide](https://fatou.dev/guide/editors.html).

## CI integration

Run format and lint checks in GitHub Actions with
[fatou-action](https://github.com/jolars/fatou-action), which installs a
prebuilt, checksum- and provenance-verified binary:

```yaml
- uses: jolars/fatou-action@v1
```

Or as [pre-commit](https://pre-commit.com) hooks with
[fatou-pre-commit](https://github.com/jolars/fatou-pre-commit):

```yaml
repos:
  - repo: https://github.com/jolars/fatou-pre-commit
    # fatou version
    rev: v0.7.0
    hooks:
      - id: fatou-lint
      - id: fatou-format
```

## Development

```sh
cargo build
cargo test
cargo clippy --all-targets --all-features -- -D warnings
cargo fmt -- --check
```

Or via [`task`](https://taskfile.dev): `task test`, `task lint`, `task format`.
See [CONTRIBUTING.md](CONTRIBUTING.md) for details.

## License

MIT—see [LICENSE](LICENSE).

