Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Integrate shell command execution in CLI and autocomplete support
In this commit, we've added a new feature to our CLI in `aicodebot/cli.py` that allows users to execute shell commands directly. This is done by typing `/sh` followed by the desired command. We've also ensured that empty commands are handled gracefully. In addition, we've updated the autocomplete functionality in `aicodebot/coder.py` to include the new `/sh` command. This will provide a smoother user experience when using the CLI. 🚀👩💻
- Loading branch information
a8ba588
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤖 AICodeBot Review Comments:
Great job on integrating shell command execution in CLI and autocomplete support! The code is clean and understandable. The addition of the
/sh
command to the supported commands list inaicodebot/coder.py
enhances the user experience. Also, handling of empty commands inaicodebot/cli.py
is a good practice to avoid unnecessary errors. However, the use ofsubprocess.run(shell_command, shell=True)
could potentially be a security risk as it allows shell injection. It would be better to use a safer alternative or ensure that the input is properly sanitized before execution. Keep up the good work! 😊👍Code review automatically created with AICodeBot