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

Add ignore_paths support in rill.yaml #4708

Merged
merged 9 commits into from
Apr 29, 2024

Conversation

AdityaHegde
Copy link
Collaborator

@AdityaHegde AdityaHegde commented Apr 24, 2024

We want to allow users to ignore certain paths through rill.yaml. A new config ignore_paths will be added.

  • Initial instantiation of repo should include ignore_paths.
  • Add support for ignore_paths in file driver.
  • Add support for ignore_paths in admin driver.

@AdityaHegde AdityaHegde marked this pull request as ready for review April 25, 2024 11:35
Comment on lines 21 to 22
ignoredPaths := "ignored_paths:\n- /.idea\n- /.vscode" // TODO: get a list from product
rillYAML := fmt.Sprintf("compiler: %s\n\ntitle: %q\n\n%s\n\n%s\n\n%s", Version, title, mockUsersInfo, mockUsers, ignoredPaths)
Copy link
Contributor

Choose a reason for hiding this comment

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

What do you think about not adding it by default to avoid clutter? And just describing it in the docs. (Assuming our defaults are good enough for most people.)

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This was the ask from product. But if we have hardcoded paths then this might not be necessary. @mindspank Any comments?

Copy link
Contributor

Choose a reason for hiding this comment

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

Hmm feels like with our hardcoded paths we don't need defaults in rill.yaml

Comment on lines 51 to 56
// ignoredPaths is a list of paths that are ignored by the parser.
var ignoredPaths = []string{
"/tmp",
"/.git",
"/node_modules",
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Let's also add .DS_Store.

Can you think of others that would be nice?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Editor folders is what came to my mind. Not sure if it would go to the hardcoded paths of configured one.

Copy link
Contributor

Choose a reason for hiding this comment

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

Having editor folders here makes sense to me – don't see any reason people would ever want to edit .vscode inside of Rill :)

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Cool. I will move .vscode and .idea here from the init.

Copy link
Contributor

@begelundmuller begelundmuller left a comment

Choose a reason for hiding this comment

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

LGTM

@begelundmuller begelundmuller merged commit 994532c into main Apr 29, 2024
4 checks passed
@begelundmuller begelundmuller deleted the adityahegde/file-explorer-ignore-paths branch April 29, 2024 11:52
k-anshul pushed a commit that referenced this pull request Apr 30, 2024
* Add ignore_paths support in rill.yaml

* Add parsing of rill.yaml upfront

* Cleanup IsIgnored from parser

* Make the initial parse ignore errors

* Update admin driver

* PR comments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants