This repository contains two shell scripts for managing Vim configurations and NPM packages. These scripts help with installing, configuring, and removing Vim along with necessary plugins, and also handle the installation and removal of NPM packages.
This script automates the setup of Vim and its essential configurations. It performs the following actions:
- Installs Vim Plug for managing Vim plugins.
- Installs necessary NPM packages (
curl
,nodejs
,npm
,pyright
,bash-language-server
). - Copies the Vim configuration file (
config.txt
) to the user's home and root directories. - Installs Vim plugins for both the user and root.
- instalVimPlug: Installs Vim Plug.
- intallNPM: Installs
curl
,nodejs
,npm
,pyright
, andbash-language-server
globally. - copVimrcHome: Copies the
.vimrc
configuration file for the root user. - installPlugins: Installs the Vim plugins for the root user.
- configVimUser: Configures Vim for the regular user and installs plugins.
This script removes Vim, its configuration, and NPM packages. It also reinstalls Vim if needed. It performs the following actions:
- Removes NPM and its packages globally.
- Restores the default Vim configuration.
- Removes Vim completely.
- Optionally, reinstalls Vim.
- removeNPM: Removes
npm
,nodejs
, and all globally installed NPM packages. - uninstallNPM: Uninstalls
pyright
andbash-language-server
packages. - restoreVimrc: Restores the original Vim configuration.
- removeVim: Uninstalls Vim completely.
- installVim: Reinstalls Vim.
- reinstallVim: A combination of the above functions for a full Vim reinstallation.
To use these scripts, follow these steps:
-
Clone this repository:
git clone https://github.com/yourusername/vim-config.git cd vim-config
-
Make the scripts executable:
chmod +x vim-config.sh remove-vim-config.sh
-
Run the configuration script to set up Vim and NPM packages:
./vim-config.sh
-
Run the removal script if you need to uninstall Vim and related packages:
./remove-vim-config.sh
curl
nodejs
npm
- Vim
Make sure these are installed on your system before running the scripts.
This project is licensed under the MIT License - see the LICENSE file for details.