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

Output arrays with one item per line #200

Closed
pelletier opened this issue Oct 24, 2017 · 6 comments
Closed

Output arrays with one item per line #200

pelletier opened this issue Oct 24, 2017 · 6 comments
Labels
feature Issue asking for a new feature in go-toml.

Comments

@pelletier
Copy link
Owner

The encoder should be able to emit arrays with one item per line. It would help with diffs, as discussed in golang/dep#789 (comment). Thanks to #192 this can be exposed as an option for the encoder.

@pelletier pelletier added the feature Issue asking for a new feature in go-toml. label Oct 24, 2017
@pelletier
Copy link
Owner Author

cc @carolynvs who may be interested in that :)

@sdboyer
Copy link

sdboyer commented Nov 15, 2017

just checking in - any ideas on when you might get round to this? 😄

@carolynvs
Copy link
Contributor

Oops, sorry if anyone thought that I was signing up for this issue. I have too much right now to pick this up.

@pelletier
Copy link
Owner Author

pelletier commented Nov 16, 2017 via email

pelletier added a commit that referenced this issue Dec 5, 2017
A new Encoder option emits arrays with more than one line on multiple lines.
This is off by default and toggled with `ArraysWithOneElementPerLine`.

Fixes #200
pelletier added a commit that referenced this issue Dec 5, 2017
A new Encoder option emits arrays with more than one line on multiple lines.
This is off by default and toggled with `ArraysWithOneElementPerLine`.

For example:

```
A = [1,2,3]
```

Becomes:

```
A = [
  1,
  2,
  3
]
```

Fixes #200
pelletier added a commit that referenced this issue Dec 5, 2017
A new Encoder option emits arrays with more than one line on multiple lines.
This is off by default and toggled with `ArraysWithOneElementPerLine`.

For example:

```
A = [1,2,3]
```

Becomes:

```
A = [
  1,
  2,
  3
]
```

Fixes #200
pelletier added a commit that referenced this issue Dec 18, 2017
A new Encoder option emits arrays with more than one line on multiple lines.
This is off by default and toggled with `ArraysWithOneElementPerLine`.

For example:

```
A = [1,2,3]
```

Becomes:

```
A = [
  1,
  2,
  3
]
```

Fixes #200
@pelletier
Copy link
Owner Author

@sdboyer @carolynvs merged the new feature. Let's me know how it goes for you!

@sdboyer
Copy link

sdboyer commented Dec 18, 2017

lookin good so far! golang/dep#1461

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Issue asking for a new feature in go-toml.
Projects
None yet
Development

No branches or pull requests

3 participants