Extract URL into json_config file, remove the reverse function
Uncomment the self.exec_plugin_manager function
This commit is contained in:
parent
34851105c9
commit
caa3eea0b9
@ -31,7 +31,9 @@ class VimModule(AbstractModule):
|
||||
if os.path.isfile(str(get_vim_root().joinpath("autoload", "plug.vim"))):
|
||||
print("Vimplug already installed!")
|
||||
else:
|
||||
curl_request = "curl https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim " + \
|
||||
pluginmanager_url = self.json_config['pluginmanager_url']
|
||||
curl_request = "curl " + \
|
||||
pluginmanager_url + \
|
||||
" -o " + \
|
||||
str(get_vim_root().joinpath("autoload", "plug.vim"))
|
||||
subprocess.call(curl_request, shell=True)
|
||||
@ -77,9 +79,8 @@ class VimModule(AbstractModule):
|
||||
print("\n\033[4mDefault settings:\033[0m")
|
||||
[print(i) for i in default_settings]
|
||||
|
||||
default_settings.reverse()
|
||||
for setting in default_settings:
|
||||
vimrc_content.insert(0, setting + "\n")
|
||||
vimrc_content.append(setting + "\n")
|
||||
return vimrc_content
|
||||
|
||||
def get_vimfile_working_copy(self):
|
||||
@ -107,11 +108,9 @@ class VimModule(AbstractModule):
|
||||
subprocess.call(install_plugins, shell=True)
|
||||
|
||||
def run(self):
|
||||
|
||||
self.create_folder_structure()
|
||||
self.get_vimplug_file()
|
||||
plugin_section = self.create_plugin_section()
|
||||
settings_section = self.create_setting_section()
|
||||
self.write_vimfile(settings_section + plugin_section)
|
||||
# Uncomment when in production
|
||||
# self.exec_plugin_manager()
|
||||
self.exec_plugin_manager()
|
||||
|
Loading…
Reference in New Issue
Block a user