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

docs(vrl): add example syntax for valid expressions. #21963

Merged
merged 4 commits into from
Dec 5, 2024

Conversation

bfung
Copy link
Contributor

@bfung bfung commented Dec 5, 2024

Summary

Add documentation for valid VRL syntax using newline and/or semicolons.

Change Type

  • Bug fix
  • New feature
  • Non-functional (chore, refactoring, docs)
  • Performance

Is this a breaking change?

  • Yes
  • No

How did you test this PR?

Verified the VRL syntax works in the VRL Playground [share]

Create and test .cue file documentation:

➜  vector git:(bfung/vrl-endofexpresssion-documentation) cd website
➜  website git:(bfung/vrl-endofexpresssion-documentation) make local-preview-build
...
✔✔✔ passed in 642.414083ms
tested 508 documents
➜  website git:(bfung/vrl-endofexpresssion-documentation) make serve
...
Web Server is available at http://localhost:1313/ (bind address 127.0.0.1)
Press Ctrl+C to stop

Then open browser to local site at http://localhost:1313/docs/reference/vrl/expressions/#syntax.
Screenshot 2024-12-04 at 8 25 23 PM

Does this PR include user facing changes?

  • Yes. Please add a changelog fragment based on our guidelines.
  • No. A maintainer will apply the "no-changelog" label to this PR.

Checklist

  • Please read our Vector contributor resources.
  • If this PR introduces changes Vector dependencies (modifies Cargo.lock), please
    run dd-rust-license-tool write to regenerate the license inventory and commit the changes (if any). More details here.

References

Discord chat [link]:

@bfung bfung added domain: external docs Anything related to Vector's external, public documentation no-changelog Changes in this PR do not need user-facing explanations in the release changelog labels Dec 5, 2024
@bfung bfung requested review from a team as code owners December 5, 2024 04:01
@datadog-vectordotdev
Copy link

datadog-vectordotdev bot commented Dec 5, 2024

Datadog Report

Branch report: bfung/vrl-endofexpresssion-documentation
Commit report: 6109974
Test service: vector

✅ 0 Failed, 7 Passed, 0 Skipped, 25.45s Total Time

Copy link
Member

@pront pront left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, looks good!

(FYI if you add website in the branch name, it will trigger a site preview deployment)

@pront pront added this pull request to the merge queue Dec 5, 2024
remap: syntax: expressions: {
title: "Expressions"
description: """
VRL programs are made up of literal and dynamic expressions, described more in detail below. Expressions can be separated by newline or semicolon in any combination.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
VRL programs are made up of literal and dynamic expressions, described more in detail below. Expressions can be separated by newline or semicolon in any combination.
VRL programs are made up of literal and dynamic expressions, described more in detail below. Expressions can be separated by newlines or semicolons in any combination.

Merged via the queue into master with commit 75f35e2 Dec 5, 2024
69 checks passed
@pront pront deleted the bfung/vrl-endofexpresssion-documentation branch December 5, 2024 17:31
pront pushed a commit that referenced this pull request Dec 6, 2024
* docs(vrl): add example syntax for valid expressions.

* fix spelling

* fix grammar and trailing whitespace from 'cargo vdev check fmt'

* run 'cue fmt' to pass 'make check-docs'
jszwedko pushed a commit that referenced this pull request Dec 9, 2024
* docs(vrl): add example syntax for valid expressions.

* fix spelling

* fix grammar and trailing whitespace from 'cargo vdev check fmt'

* run 'cue fmt' to pass 'make check-docs'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
domain: external docs Anything related to Vector's external, public documentation no-changelog Changes in this PR do not need user-facing explanations in the release changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants