---
title: Read rustfmt.toml TOML file
timestamp: 2024-04-02T12:50:01
author: szabgab
published: true
description: Read a TOML file
tags:
    - toml
    - Table
    - parse
    - read_to_string
todo:
    - get rid of the quotes
    - handle lists in square bracket
---

## Dependencies

Using the [toml](https://crates.io/crates/toml) crate.

{% include file="examples/read-rustfmt-toml/Cargo.toml" %}

{% include file="examples/read-rustfmt-toml/src/main.rs" %}

{% include file="examples/read-rustfmt-toml/sample-rustfmt.toml" %}




