We wanted to create a tool to fix yamls...then we got a community

adriens - Mar 24 '22 - - Dev Community

๐Ÿ‘‰ Intro

Recently we built a library that would lint & fix yamls, that we also did embed as a Github Action so we could use this tool as part of our CI pipeline :

What we did not know at that time is that...

that was just the beginning of a journey.

๐Ÿ“ฆ Release the cli

Progressively we started to focus on yamlfixer cli user experience, features, packaging and delivery.

So the context slowly started to shift from a background hidden tool to a full tool, with more features and more integrations.

We started to automate package delivery on pypi, make install process much easier, create demo scenarios, create one liners, plug into jq , plug it into gomplate template engine, ...integration scenarios and many other exciting things, very efficiently around our Dev & OPS pipeline, all that very naturally.

While the collaboration through GH issues was fully remote, we even did an internal (30' minutes long) meetup to share about vision and issues.

At the end of the first week I was mesmerized :

we wanted a cli tool to fix yamls but finally we built a community !

๐ŸŽž๏ธ Video demo

Find below first live demo video (in French) with a lot of more details about what we did :

๐ŸŽฌ asciinema demos

Below some dedicated asciinema demos :

Feel free to contribute yours on the GH project ๐Ÿ‘‡

๐Ÿง‘โ€๐Ÿคโ€๐Ÿง‘ Contributors

Many thanks to the core team I really enjoy working with on a daily basis on many other DevOPS challenges, helping pushing disruptive new ideas :

๐Ÿ”– Project repo

For more about the project just :

GitHub logo opt-nc / yamlfixer

Automates the fixing of problems reported by yamllint by parsing its output

License Build

Docker Image

PyPI PyPI - Python Version PyPI - Downloads

yamlfixer's logo yamlfixer

โ” About

yamlfixer automates the fixing of problems reported by yamllint by parsing its output.

๐Ÿ–ผ๏ธ Screenshot

Here'a screenshot of yamlfixer launched on yaml-test-suite :

yamlfixer's screenshot

๐Ÿ“‘ Installation

The easiest way to install yamlfixer is from pypi, as described below.

๐Ÿง Linux install

python3 -m pip install yamlfixer-opt-nc
Enter fullscreen mode Exit fullscreen mode

๐ŸชŸ Windows install

python -m pip install yamlfixer-opt-nc
Enter fullscreen mode Exit fullscreen mode

pipx setup

For an optimal experience we recommand using pipx.

To install :

pipx install yamlfixer-opt-nc
pipx list
Enter fullscreen mode Exit fullscreen mode

To upgrade :

pipx upgrade yamlfixer-opt-nc
Enter fullscreen mode Exit fullscreen mode

To uninstall :

pipx uninstall yamlfixer-opt-nc

๐Ÿš€ Usage

This software automatically fixes some errors and warnings reported by yamllint.

usage: yamlfixer [-h] [-v] [-b] [-B BACKUPSUFFIX] [-d] [-D DIFF_FILE] [-e EXTENSIONS] [-f]
                 [-F] [-l] [-N] [-n] [-r LEVEL] [-j | -p | -s] [-t TABSIZE]
                 [-c CONFIG_FILE | -C CONFIG_DATA]
                 [FILE_or_DIR [FILE_or_DIR ...]]
Fix formatting problems in YAML documents. If no file is specified, then reads
โ€ฆ
Enter fullscreen mode Exit fullscreen mode
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .