Skip to content

Commit

Permalink
Merge branch 'master' of github.com:python-poetry/tomlkit
Browse files Browse the repository at this point in the history
  • Loading branch information
frostming committed Jul 24, 2024
2 parents 507ca76 + c35ab33 commit b1b38b3
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 8 deletions.
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ repos:
args: [--py37-plus]

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: 'v0.5.1'
rev: 'v0.5.4'
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix, --show-fixes]
Expand Down
13 changes: 6 additions & 7 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions tomlkit/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,11 @@ def dump(data: Mapping, fp: IO[str], *, sort_keys: bool = False) -> None:
:param data: a dict-like object to dump
:param sort_keys: if true, sort the keys in alphabetic order
:Example:
>>> with open("output.toml", "w") as fp:
... tomlkit.dump(data, fp)
"""
fp.write(dumps(data, sort_keys=sort_keys))

Expand Down

0 comments on commit b1b38b3

Please # to comment.