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

Refactor #138

Merged
merged 4 commits into from
Feb 10, 2023
Merged

Refactor #138

merged 4 commits into from
Feb 10, 2023

Conversation

savq
Copy link
Owner

@savq savq commented Jan 31, 2023

  • Rename check_rm to find_unlisted and refactor.
  • Rename walk_dir to walkdir and refactor to return an iterator instead of taking a function.
  • Refactor report to contain the messages table, since it's not used anywhere else.
  • Refactor list function.
  • Refactor register function to simplify name inference.
  • Remove parse_name function.
  • Prefer calling string.format function to :format method.

Docs

  • Add description for url_format setup option.
  • Format code snippets in docs:
    • Indent at 2 spaces
    • Use double quotes
    • Elide parentheses for single table arguments
  • Rewrite the section on bootstrapping.
  • Update CONTRIBUTING to mention the issue template.
  • Update the descriptions of package options.

  • The refactoring of walkdir was based on Julia's Filesystem.walkdir.
  • find_unlisted could be simplified further with vim.fs.dir, but that requires nvim v0.8.
  • Closes self-installing example #129 . I incorporated some of the suggestions with the script that we already had in the docs.
  • Note: I wanted to refactor logging in this PR too, but there seems to be a problem with writing to the log synchronously.

@savq savq changed the title Refactor and maintenance Refactor Jan 31, 2023
@savq savq force-pushed the dev branch 2 times, most recently from 23998a0 to 3fb861e Compare February 2, 2023 22:00
@savq savq marked this pull request as ready for review February 5, 2023 22:22
@savq savq force-pushed the dev branch 3 times, most recently from e9191c5 to 75fe69c Compare February 8, 2023 21:53
- Rename `check_rm` to `find_unlisted` and refactor.
  - NOTE: It'd be simplified further with `vim.fs.dir`, but that
    requires nvim v0.8.
- Rename `walk_dir` to `walkdir` and refactor to return an iterator
  instead of taking a function.
- Refactor `list` function
- Refactor `report` to contain the `messages` table, since it's not used
  anywhere else.
- Prefer calling `string.format` function to `:format` method.
- Prefer omitting parentheses when passing a single table argument.
- Add description for `url_format` setup option.
- Format code snippets in docs.
  - Indent at 2 spaces
  - Use double quotes
  - Elide parentheses for single table arguments
- Rewrite the section on bootstrapping.
- Update CONTRIBUTING to mention the issue template.
- Update the descriptions of package options.
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.

self-installing example
1 participant