Closed progfolio closed 1 year ago
Thank you for the recommendations. Your points about package header, checkdoc, pop-to-buffer, autoload, and chatgpt--newline-twice
and chatgpt--delete-line
should be addressed in a9734dda7d83fc2a406bec541d9e4ec6f5ac3f77.
I will look into comint-mode
.
Please feel free to submit any issues and pull requests. I am a novice in Emacs package development, and any feedback is welcome.
This package will fail to install due to it missing a package header.
Without it there's no way for the package manager to know which dependencies are needed or what minimum version of Emacs the package supports.
chatgpt-repo-path
should not be hardcoded to assume straight.el was used to install the package. It would be better to dynamically detect the repository path.checkdoc shows the following warnings/errors:
Instead of relying on epc and deffered, you may be able to redesign this as a major mode derived from comint-mode.
See: https://www.masteringemacs.org/article/comint-writing-command-interpreter
The
chatgpt-display
command is missing an interactive spec. It's implementation could likely be replaced by Emacs built-inpop-to-buffer
function, e.g.:However, it would be better to let the user decide which window ends up selected.
pop-to-buffer
will obeydisplay-buffer-alist
on its own.There are autoload cookies for private elisp functions. By convention these shouldn't be called by anyone consuming the library, so they should not be autoloaded.
chatpt--newline-twice
andchatgpt--delete-line
seem superfluous.I'd recommend re-implementing the python script in elisp to avoid the dependency on python altogether.