BreakPts : Set/View Vim breakpoints and browse functions visually
script karma |
Rating 19/8,
Downloaded by 4484 |
Comments, bugs, improvements
|
Vim wiki
|
created by |
Hari Krishna Dara |
|
script type |
utility |
|
description |
YOU NEED Vim7.0 FOR THE NEW VERSION TO WORK.
New version no longer depends on multvals.vim
The plugin provides a few features for debugging Vim scripts that are similar
to what IDEs normally have, such as browing source, managing breatpoints etc.
Setting breakpoints visually in functions is very important as you need to
specify the exact line number for the line you are interested in (which often
is difficult to find out if you use |line-continuation| characters to format
code). This also avoids typing in the |:breakadd| command while guessing what
the scriptids for your script are. It also defines a few convenience commands
that take the place of Vim built-in commands and add Vim command-line
completion feature.
The plugin also provided utilties to create various conditional breakpoints
programmatically to help debug complex and iterative logic. You can set a
condition, a skip count and an expire count for your breakpoint to be valid on
any particular line.
You can also simply use the plugin to browse Vim sripts and functions. It
provides a browser history type of features to drill into the code, by
navigating the function calls and return back to the previous function at any
time.
Here is a list of features:
- Set/unset breakpoints in functions and scripts visually.
- Save/clear/restore list of breakpoints across sessions.
- Browse functions and script by navigating through the list of functions
(and function references) and scripts.
- Reload scripts when they change externally (during development)
- Global functions to set/unset breakpoints programmatically with optional
conditions.
- Misc. alternative commands for the built-ins that typically work better
(better completion and defaults).
- Remote debugging ability to debug scripts in one Vim session using
another Vim as the debugger.
Search_keywords: breakpoint breakpts breakadd breaklist breakdel break vim WinManager visual list Hari Krishna Dara
|
|
install details |
- To install, download the latest versions of these two plugins:
breakpts: http://www.vim.org/script.php?script_id=618
genutils: http://vim.sourceforge.net/script.php?script_id=197
- Extract the zip archives in to your runtime directory (.vim or vimfiles
under your HOME directory).
- Make sure your vim has +signs feature.
- Start a new instance or go to an existing instance of vim.
- Execute:
:helpt <your runtime directory>/doc
This should generate the help tags for the breakpts plugin help.
- Take a look at the |breakpts-settings| to change any default
configuration and behavior.
Optional:
- Take a look at the |breakpts-winmanager| to configure with winmanager.
- Choose a hotkey as described in |breakpts-usage|.
- Considier installation the following two optional plugins:
- If cmdalias plugin is installed, it will be used to create aliases for
a few commands, to make it easier to type. Download the plugin from:
http://www.vim.org/script.php?script_id=745
- If foldutil plugin is installed, it will be used to foldaway the code
such that the breakpoints are easier to see. Download the plugin from:
http://www.vim.org/script.php?script_id=158
For versions older than 4.0, you also need multvals.vim: vimscript#171 in addition to genutils, and you need to download the non-autoload versions of both. See their respective installation sections for more information .
|
|
script versions (upload new version)
Click on the package to download.
breakpts-4.0.zip |
4.0 |
2008-01-09 |
7.0 |
Hari Krishna Dara |
- The script is now more aligned to Vim 7.0.
- It is now autoloaded.
- Not dependent on multvals anymore.
- Comes with a Vim style help file.
- Minor improvements and fixes.
|
breakpts.vim |
3.2 |
2006-05-08 |
6.0 |
Hari Krishna Dara |
Release 3.2 for vim7 compatibility. Thanks to David Fishburn for
providing most of the patches for vim7 and testing it.
|
breakpts.vim |
3.1 |
2004-07-15 |
6.0 |
Hari Krishna Dara |
Just trying to fix a bad upload for version 3.1
- Now requires Vim 6.3
- More documentation.
- The script now works perfectly well for remote debugging. All the Vim bugs
were fixed in 6.3 and I have used the plugin for some real debugging this
time, and found it to be quite usable.
- You can now reload scripts from remote session.
- Many new useful commands with command-completions.
- Runtime: that completes filenames from 'rtp'
- Debug: that completes command and function names (with arguments).
- Breakadd/Breakdel: that complete function names/script paths
- Where: to see the context at the debug prompt.
- Useful BreakPtsSetupBuf command. A few other global commands.
- Lots of other misc. and subtle improvements. Read the script header completely
for details (you can diff with the old version if you like :)
|
breakpts.vim |
3.0 |
2003-12-17 |
6.0 |
Hari Krishna Dara |
See the function header for details.
- Now BreakPts command can take an option to specify the initial view.
- New BPOpen command to open a script for editing from the scripts view.
- Experimental features to debug scripts from a remote vim using the
|clientserver| functionality. It is now possible to view the context and execute the :debug
mode commands such as >next >cont from the browser, while debugging
remotely. CAUTION: This requires installing a patch to vim and sometimes makes Vim crash (see installation section).
- Two global functions BPBreak() and BPBreakIf() to add breakpoints from
with in your script. The BPBreak() can also be used while at the
:debug prompt (>) to easily add breakpoints without needing to worry
about the function name and line number. This requires a patch to be
installed to vim (see installation section).
- New setting g:brkptsModFuncHeader.
- New version dependency check on dependent libraries. You now get an
error message during the Vim startup if you don't have the right
version of multvals and genutils.
- Remember the line number when the browser is closed and reopened.
- Fixed a bug in handling function names, such as <SID>Func.
- Fixed a bug in browser name on unixy vim.
- Plugin reloading now handles some non-standard naming conventions for
the loaded_ variable and works better.
- Fixed other misc. bugs.
- The g:loaded_breakpts variable now contains the version number for any dependency checking (see :help v:version for format information) |
breakpts.vim |
2.0 |
2003-06-18 |
6.0 |
Hari Krishna Dara |
Number of improvements, thanks to David Fishburn {fishburn at sybase dot org} for feedback/ideas and help with identifying issues. Note: This version requires Vim 6.2. New features at a glance:
- View the list of scripts loaded.
- View the script listing and set "file" breakpoints.
- Reload a script after unletting the g:loaded_xxx variable.
- Mappins to goto next/previous breakpoint.
- Fold the contents so that only breakpoints are visible (with some
context).
- A command to clear all the breakpoints.
- A new :BPBrklist command to get the list of breakpoints. You can
press <F9> on them to disable/enable them.
- :BPSave command to save the current breakpoints in a specified global
variable. You can later exec the variable to reinstate the
breakpoints. This allows you to save/restore breakpoints across sessions.
See description for more information. Please continue to send in your suggestions/bug reports etc.
|
breakpts.vim |
1.0 |
2003-04-11 |
6.0 |
Hari Krishna Dara |
Initial upload |
ip used for rating: 142.132.191.50
|