toml-echo

Crates.iotoml-echo
lib.rstoml-echo
version0.4.0
sourcesrc
created_at2019-12-16 11:52:10.310612
updated_at2023-08-01 13:15:38.604397
descriptionTool for printing toml variables
homepagehttps://github.com/nickez/toml-echo
repositoryhttps://github.com/nickez/toml-echo
max_upload_size
id189741
size12,674
Niklas (NickeZ)

documentation

README

toml-echo

This is a very simple tool for printing single values out of toml files.

It can be used when packaging rust applications to get the version from the manifest file.

If a tomfile doesn't contain any path segment separators (e.g. "Cargo.toml"), then the file will be searched after upwards from the current working dir. Otherwise, if the tomlfile argument has separators (e.g. "./Cargo.toml") it will only be searched for in the current working directory.

Example usage

#!/usr/bin/env bash

VERSION=$(toml-echo Cargo.toml package.version)
Commit count: 13

cargo fmt