From b02085e5f00bbd395eb2caa9ed6666254e2afbbe Mon Sep 17 00:00:00 2001 From: ronny abraham Date: Sun, 25 Aug 2024 20:13:46 +0300 Subject: [PATCH] updated readmes for ycm --- share/templates/readmes/ycm.md | 37 ++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 share/templates/readmes/ycm.md diff --git a/share/templates/readmes/ycm.md b/share/templates/readmes/ycm.md new file mode 100644 index 0000000..321f414 --- /dev/null +++ b/share/templates/readmes/ycm.md @@ -0,0 +1,37 @@ +# YCM Setup with Python 3.11.9 + +## Overview + +Due to issues with getting YCM (YouCompleteMe) to work with Python 3.12, it's recommended to create all virtual environments using Python version 3.11.9. This guide will walk you through setting up YCM with Python 3.11.9. + +## Creating a Virtual Environment + +To create a virtual environment using Python 3.11.9, run the following command: + +```bash +mkvirtualenv -p $(pyenv which python3.11) environment_name +``` + +Replace environment_name with your desired virtual environment name. + +## Recompiling YCM +If you encounter issues with YCM, you may need to recompile it. Follow these steps: + +``` +cd ~/.vim/bundle/YouCompleteMe +git pull origin master +python3 install.py --all +``` + +This will pull the latest changes from the YCM repository and recompile it with the necessary support. + +## Setting Up YCM +To configure YCM for your project, create a .ycm_extra_conf.py file in the root directory of your project. The file should contain the following Python code: + +```python +def Settings(**kwargs): + return { + 'interpreter_path': "/Users/ronny/.virtualenvs/PROJECT_NAME/bin/python" + } +``` +