aboutsummaryrefslogtreecommitdiff
path: root/docs/markdown/snippets/versionfile.md
blob: 6071f2cfb3d1c78c7fb530334881b20a63e7198e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
## Project version can be specified with a file

Meson can be instructed to load project's version string from an
external file like this:

```meson
project('foo', 'c' version: files('VERSION'))
```

The version file must contain exactly one line of text and that will
be set as the project's version. If the line ends in a newline
character, it is removed.