Skip to content

A plugin for easily running Python and C++ files from Vim (nonfunctional lol)

Notifications You must be signed in to change notification settings

pipparichter/vim-autorun

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 

Repository files navigation

vim-autorun

NOTE: This is very much a work-in-progress! It was mostly just a way to familiarize myself with Vimscript syntax, but I've found it somewhat useful for quickly executing code. I am continually updating it as I think of additional features or notice any bugs. For anyone who tries it out, I'd appreciate any comments, suggestions, bug information, etc.

This plugin provides commands for running Python and C++ files from Vim.

Installation

Dependencies

Use of this plugin requires...

  • Python installed on your machine.
  • A C++ compiler installed on your machine (so far, this plugin is only set up for the g++ compiler, which should come with most Debian-based Linux distros).
  • The Gnome Terminal Emulator. This can be installed on Debian-based Linux systems using sudo apt install gnome-terminal.

Procedure

If your plugin manager is vim-plug...

  1. Clone this repository into your ~/.vim plugin folder.
    'git clone https://github.com/pipparichter/vim-autorun.git'
  2. Add the following line to your .vimrc file, before call plug#end() and after the vim-plug setup.
    Plug 'pipparichter/vim-autorun'
    NOTE: Make sure to use single quotes!

If your plugin manager is Pathogen...

  1. Clone this repository into your .vim plugin folder.

If you don't have a plugin manager...

  1. Clone this repository into your .vim plugin folder.

Commands

Running files

  • :Run
    This command is basically just a combined version of :RunPython and :RunCPP. It recognizes the filetype of the buffer and calls :RunPython or :RunCPP accordingly.

* `:RunPython`
Saves the current buffer and executes it as a Python file.
* `:RunCPP`

Managing projects

  • :MakeCPPProject {project name}

* `:SetCurrentProject {project name}`

Configuration

Troubleshooting

About

A plugin for easily running Python and C++ files from Vim (nonfunctional lol)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published