Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Convert .md files to .toml files #31

Merged
merged 3 commits into from
Nov 26, 2021
Merged

Conversation

not-my-profile
Copy link
Contributor

@not-my-profile not-my-profile commented Nov 26, 2021

a407f82 split features.toml into many
.md files with TOML frontmatters. This commit converts all .md files in
the data/ directory to .toml files so that they can be more easily
processed by other software.

The files were converted with the following Python code:

#!/usr/bin/env python3
import glob

for path in glob.glob('data/**/*.md'):
    text = ''
    with open(path) as f:
        assert next(f) == '+++\n'
        line = next(f)
        while line != '+++\n':
            text += line
            line = next(f)
    with open(path.replace('.md', '.toml'), 'w') as f:
        f.write(text)

Closes #30.

a407f82 split features.toml into many
.md files with TOML frontmatters. This commit converts all .md files in
the data/ directory to .toml files so that they can be more easily
processed by other software.

Closes jplatte#30.
build.rs Outdated Show resolved Hide resolved
build.rs Outdated Show resolved Hide resolved
@jplatte jplatte merged commit d1edf37 into jplatte:main Nov 26, 2021
@jplatte
Copy link
Owner

jplatte commented Nov 26, 2021

Thanks!

@not-my-profile
Copy link
Contributor Author

You're welcome :) Huh, your squash lost my commit message.

@jplatte
Copy link
Owner

jplatte commented Nov 26, 2021

Oh yeah, that was not intentional. Shouldn't really be a big deal though.

@not-my-profile
Copy link
Contributor Author

I'm quite the stickler for commit messages^^ But yeah I guess it's fine. Out of curiosity does GitHub just do that by default?

@not-my-profile
Copy link
Contributor Author

Oh btw my commit broke your example links in #16.

@jplatte
Copy link
Owner

jplatte commented Nov 26, 2021

I'm quite the stickler for commit messages^^

Me too but not enough to rewrite history in this case.

But yeah I guess it's fine. Out of curiosity does GitHub just do that by default?

Not usually.. I don't know what went wrong in this case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Consider using .toml files instead of .md files
2 participants