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

feat: implemented gptme.vim plugin #241

Merged
merged 1 commit into from
Nov 1, 2024
Merged

feat: implemented gptme.vim plugin #241

merged 1 commit into from
Nov 1, 2024

Conversation

ErikBjare
Copy link
Owner

@ErikBjare ErikBjare commented Nov 1, 2024

Fixes #213

gptme wrote all of this, I'm honestly stunned.

It is amazingly good, I will prob be using this all the time!


Important

Introduces a Vim plugin for gptme enabling direct interaction from Vim with configurable settings and key mappings.

  • Features:
    • Implements a Vim plugin for gptme allowing interaction directly from Vim.
    • Supports running gptme queries with context from the current buffer.
    • Results are displayed in a new buffer.
    • Configurable context size and key mappings.
  • Installation:
    • Instructions for installation using vim-plug and manual installation in scripts/vim/README.md.
  • Usage:
    • Provides :Gptme command and <Leader>g mapping for running gptme.
    • Handles visual selection and context around the cursor.
  • Configuration:
    • Settings for context lines and key mappings in .vimrc.
  • Files Added:
    • scripts/vim/README.md: Documentation for the plugin.
    • scripts/vim/doc/gptme.txt: Help file for the plugin.
    • scripts/vim/plugin/gptme.vim: Main plugin script.

This description was created by Ellipsis for 889a213. It will automatically update as commits are pushed.

Copy link
Contributor

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

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

👍 Looks good to me! Reviewed everything up to 889a213 in 44 seconds

More details
  • Looked at 213 lines of code in 4 files
  • Skipped 0 files when reviewing.
  • Skipped posting 4 drafted comments based on config settings.
1. scripts/vim/doc/gptme.txt:15
  • Draft comment:
    The command in the documentation is :Gptme, but in the implementation, it is :gptme. Consider using consistent casing for the command name in both documentation and implementation.
  • Reason this comment was not posted:
    Decided after close inspection that this draft comment was likely wrong and/or not actionable:
    The comment addresses a potential inconsistency between the documentation and the implementation. However, the implementation details are not visible in the diff, so it's unclear if the issue exists. Without evidence from the diff, the comment may not be actionable.
    The comment could be valid if the implementation indeed uses a different casing, but without seeing the implementation, it's speculative. The comment assumes an issue without providing evidence from the diff.
    The comment is speculative because it lacks evidence from the diff. Without seeing the implementation, we cannot confirm the inconsistency.
    Delete the comment because it is speculative and lacks evidence from the diff to support its claim.
2. scripts/vim/README.md:36
  • Draft comment:
    The command in the documentation is :gptme, but in the implementation, it is :Gptme. Consider using consistent casing for the command name in both documentation and implementation.
  • Reason this comment was not posted:
    Marked as duplicate.
3. scripts/vim/plugin/gptme.vim:71
  • Draft comment:
    The command in the implementation is :Gptme, but in the documentation, it is :gptme. Consider using consistent casing for the command name in both documentation and implementation.
  • Reason this comment was not posted:
    Marked as duplicate.
4. scripts/vim/plugin/gptme.vim:65
  • Draft comment:
    The command in the implementation is :Gptme, but in the documentation, it is :gptme. Consider using consistent casing for the command name in both documentation and implementation.
  • Reason this comment was not posted:
    Marked as duplicate.

Workflow ID: wflow_qeIpzUWX55VJxwUb


You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

@codecov-commenter
Copy link

codecov-commenter commented Nov 1, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 72.63%. Comparing base (cdd8c6b) to head (889a213).

✅ All tests successful. No failed tests found.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #241      +/-   ##
==========================================
- Coverage   72.68%   72.63%   -0.06%     
==========================================
  Files          60       60              
  Lines        3833     3833              
==========================================
- Hits         2786     2784       -2     
- Misses       1047     1049       +2     
Flag Coverage Δ
anthropic/claude-3-haiku-20240307 71.64% <ø> (ø)
openai/gpt-4o-mini 71.53% <ø> (-0.06%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@ErikBjare ErikBjare merged commit a04ee05 into master Nov 1, 2024
7 checks passed
@ErikBjare ErikBjare deleted the dev/vim branch November 1, 2024 16:54
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.

vim integration
2 participants