Best Mac Editor For Yaml

Espresso is a gorgeous Mac-only code editor that’s powerful and smooth, like the caffeinated beverage it’s named after. This text editor has been credited with helping its users edit CSS in less. 07-JAN-2009 - Andrey Somov releases SnakeYAML, a 1.1 YAML Parser - 03-JAN-2009 - Burt Harris announced YAML for.NET and editor for Visual Studio - 02-DEC-2008 - Jesse Beder released YAML for C - 11-MAY-2008 - Oren Ben-Kiki has released a new YAML 1.2 spec draft - 29-NOV-2007 - Alexey Zakhlestin has updated his Syck (YAML 1.0) binding. To learn the basics of YAML, see Learn YAML in Y Minutes. Azure Pipelines doesn't support all YAML features. Unsupported features include anchors, complex keys, and sets. Also, unlike standard YAML, Azure Pipelines depends on seeing stage, job, task, or a task shortcut like script as the first key in a mapping.

  1. Best Mac Editor For Yaml File

Let's take a look at a short tutorial that gives an explanation of the vim settings for working with YAML.

Join the DZone community and get the full member experience.

Join For Free

Having managed to avoid YAML until quite recently, my vim installation wasn't well set up at all for working with it. It needs more config settings than plugins, so I thought I'd write down what I found helpful. I'm using it quite a lot now I'm working with OAS (used to be Swagger) API definitions.

Let's start with the easy bit: I'm using the yaml-vim plugin. This seems to do a decent job of syntax highlighting, really helping to spot mistakes!

I added a bunch of configuration to my .vimrc also:

By setting the foldmethod to indent, I get a fold on an increase in indentation levels, which really helps to just expand the bits I'm working on and generally be able to find my way around a file (Pythonistas may find this setting useful since Python works on a similar indentation basis).

Most of the rest of the configuration is around indentation. Yaml does not allow tabs, and indents are multiples of two spaces, so I've set the expandtab value here and also set tabstop/soft tabstop ( ts and sts), and shiftwidth ( sw) to 2.

Bonus pro tip: Try openapi-spec-validator to check your OAS documents are making sense.

integration,tutorial,yaml,vim settings

Published at DZone with permission of Lorna Mitchell, DZone MVB. See the original article here.

2020

Opinions expressed by DZone contributors are their own.

Mac text editor

Best Mac Editor For Yaml File

Popular on DZone