-
Notifications
You must be signed in to change notification settings - Fork 209
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
Document lint codes #2486
Comments
Hi @carolynvs 👋 , I would like to pick up this issue. Could you brief me more about this? |
Hey @0xquark, I recommend first going through the contributor tutorial which will give you an understanding of how to use porter, and then walk you through making changes to the code. https://getporter.org/quickstart We only have a single lint error defined so far, exec-100, which can be reproduced with the following:
$ porter lint
Running linters for each mixin used in the manifest...
warning(exec-100) - Best Practice: Avoid Embedded Bash
install: 1st step in the exec mixin (such quotes, much wow)
See https://getporter.org/best-practices/exec-mixin/#use-scripts for more information
---
error(exec-101) - bash -c argument missing wrapping quotes
install: 1st step in the exec mixin (such quotes, much wow)
The bash -c flag argument must be wrapped in quotes, for example
exec:
description: Say Hello
command: bash
flags:
c: '"echo Hello World"'
See https://getporter.org/best-practices/exec-mixin/#quoting-escaping-bash-and-yaml for more information
---
Follow the changes described in the issue to document the lint error and then you can preview your documentation changes either by submitting a PR and looking at the netlify build check, or by running the documentation locally. |
Hi , So i am able to set up the porter on machine using the tutorial, tinkered around it and was able to reproduce this lint error.So now i am documenting the error , I wanted to know two things before :
|
I was referring to the lint command documentation located at https://getporter.org/cli/porter_lint/. Right now we just have exec-100 in Porter, which has to do with embedding bash commands in porter.yaml. The other message, porter-100 (reserved parameter prefix for porter), is still in development in an open pull request and would be reproduced differently. Let's just do exec-100 and the page that you create can be updated when the other PR is merged. |
Thanks! I just got confused :/ Now i'll be documenting it. |
When a user runs
porter lint
, there is a bunch of metadata returned for each result, including a URL that explains the problem in more detail.Let's create a page on the Porter website that documents all known lint messages for Porter (not specific mixins).
See our Contributing Tutorial and New Contributor Guide for help getting started contributing to Porter.
The text was updated successfully, but these errors were encountered: