Permalink
Browse files

Version 1.3

- added plugin load order
- fixed issue with python line separators across platforms
- fixed menu disordering problem on autoload
- refactoring and performance tweaks
  • Loading branch information...
mbadran authored and vim-scripts committed Jan 19, 2012
1 parent 8309464 commit fc8742600e38acf9bbe9c502a9f8ba0278251e4e
View
@@ -0,0 +1,5 @@
+.DS_Store
+doc/.DS_Store
+doc/tags
+plugin/.DS_Store
+plugin/.ropeproject/
View
2 README
@@ -2,7 +2,7 @@ This is a mirror of http://www.vim.org/scripts/script.php?script_id=3455
Headlights adds a 'Bundles' menu to Vim, revealing your bundles (aka. plugins) and the features they provide.
-Headlights creates a menu for each _currently loaded_ bundle, grouping together docs, commands, mappings, abbreviations, functions, and script files.
+Headlights creates a menu for each _currently loaded_ bundle, grouping together docs, commands, mappings, abbreviations, functions, highlights, and plugin files.
Combined with a powerful bundle manager, Headlights will improve your Vim user experience -- nay, your quality of life.
View
@@ -32,19 +32,27 @@ The Manual Way
1. [Download the latest package] [4].
-2. Expand the archive into your `.vim` directory.
+2. Expand the archive's contents into your `.vim` directory.
3. Run the following Vim command:
- `helptags ~/.vim/doc/`
+ `helptags ~/.vim/<plugin_dir>/<headlights_dir>/doc/`
Further Reading
===============
-- Refer to the Headlights help menu:
+Refer to the Headlights help menu:
`Bundles > a - i > headlights > Help`
+Protip
+------
+
+On Mac OS X, you can quickly edit any plugin script by typing its name. Hit
+Cmd-? to bring up a search dialog for menu items, then type `fugitive open`,
+for example, to reveal the `fugitive.vim` menu item as the first result. I use
+this like, _all the time_.
+
[1]: http://www.vim.org/
[2]: https://github.com/mbadran/headlights/raw/master/headlights_ss.png
View
@@ -16,8 +16,7 @@ CONTENTS *headlights*
3. Issues ____________________________________________ |headlights-issues|
4. About ______________________________________________ |headlights-about|
5. Changelog ______________________________________ |headlights-changelog|
- 6. TODO ________________________________________________ |headlights-todo|
- 7. License __________________________________________ |headlights-license|
+ 6. Licence __________________________________________ |headlights-licence|
==============================================================================
INTRODUCTION *headlights-intro*
@@ -37,8 +36,8 @@ experience -- nay, your quality of life.
[2]: Headlights mirrors Vim's 'scriptnames' command, revealing only the
bundles that are currently loaded. This is fast because it avoids file
- system access, but the trade off is that autoload bundles are not
- revealed until they are, well, autoloaded. (This is acceptable.)
+ system access, but the trade off is that autoload bundles and ftplugins
+ are not revealed until they are needed. (This is Good Enough ™.)
==============================================================================
OPTIONS *headlights-options*
@@ -92,6 +91,14 @@ Create menus for global bundle functions: >
let g:headlights_show_functions = 1
<
+Default value: 0
+
+ *headlights_show_load_order*
+
+Create menus for load order of plugin files: >
+
+ let g:headlights_show_load_order = 1
+<
Default value: 0
*headlights_debug_mode*
@@ -125,13 +132,15 @@ Lastly, I welcome any pull requests, so feel free to Fork, Fix, Send.
A NOTE ON PERFORMANCE
-Headlights can slow Vim down when a large number of bundles are loaded, or
-when hardware resources are limited. Because of this, most configuration
-options are disabled by default.
+Headlights can slow Vim down when a large number of bundles are loaded, or when
+hardware resources are limited. This is partly because adding menus to Vim is an
+expensive operation which can take over half the total execution time.
-If you experience slowness when launching Vim or switching buffers, disable
-some or all configuration options, and consider troubleshooting further or
-raising a project issue.
+This is why most configuration options are disabled by default.
+
+If you experience slowness when launching Vim or switching buffers, disable some
+or all configuration options, and consider troubleshooting further or raising a
+project issue.
==============================================================================
ABOUT *headlights-about*
@@ -143,10 +152,14 @@ hosted at Vim.org:
<http://www.vim.org/scripts/script.php?script_id=3455>
-Send feedback and untold riches to mebadran _AT_ gmail.
-
==============================================================================
-7. Changelog *headlights-changelog*
+CHANGELOG *headlights-changelog*
+
+1.3
+ - added plugin load order
+ - fixed issue with python line separators across platforms
+ - fixed menu disordering problem on autoload
+ - refactoring and performance tweaks
1.2
- major rewrite
@@ -174,32 +187,6 @@ Send feedback and untold riches to mebadran _AT_ gmail.
- initial release
==============================================================================
-TODO *headlights-todo*
-
-- the bundles menu currently gets out of order when autoload bundles are
- handled. this is because the menu is not entirely reset -- only new items
- are added below. to fix this, either provide a command to redo all the
- menus, have a periodic on timeout fix, or change the menu layout to submenus
- only (which is uglier and less convenient).
-
-- group bundles by parent. vim does not currently do this, nor does
- headlights. install syntastic for an example.
-
- headlights can identify associated bundles if they share a common path, but
- this requires some checks, and a 'parent' field will probably have to be
- added to bundles. this may impact performance, and it should be optional.
-
-- more performance optimisation on the default settings
-
-- more testing, especially for linux and windows
-
-MAYBE
-
-- add a new bundle category: highlight (:verbose highlight)
-
-- bring back autocmds as an optional bundle category (:verbose autocmd)
-
-==============================================================================
-9. License *headlights-license*
+LICENCE *headlights-licence*
Headlights is released in the public domain.
View
Binary file not shown.
@@ -1,85 +0,0 @@
-# The default ``config.py``
-
-
-def set_prefs(prefs):
- """This function is called before opening the project"""
-
- # Specify which files and folders to ignore in the project.
- # Changes to ignored resources are not added to the history and
- # VCSs. Also they are not returned in `Project.get_files()`.
- # Note that ``?`` and ``*`` match all characters but slashes.
- # '*.pyc': matches 'test.pyc' and 'pkg/test.pyc'
- # 'mod*.pyc': matches 'test/mod1.pyc' but not 'mod/1.pyc'
- # '.svn': matches 'pkg/.svn' and all of its children
- # 'build/*.o': matches 'build/lib.o' but not 'build/sub/lib.o'
- # 'build//*.o': matches 'build/lib.o' and 'build/sub/lib.o'
- prefs['ignored_resources'] = ['*.pyc', '*~', '.ropeproject',
- '.hg', '.svn', '_svn', '.git']
-
- # Specifies which files should be considered python files. It is
- # useful when you have scripts inside your project. Only files
- # ending with ``.py`` are considered to be python files by
- # default.
- #prefs['python_files'] = ['*.py']
-
- # Custom source folders: By default rope searches the project
- # for finding source folders (folders that should be searched
- # for finding modules). You can add paths to that list. Note
- # that rope guesses project source folders correctly most of the
- # time; use this if you have any problems.
- # The folders should be relative to project root and use '/' for
- # separating folders regardless of the platform rope is running on.
- # 'src/my_source_folder' for instance.
- #prefs.add('source_folders', 'src')
-
- # You can extend python path for looking up modules
- #prefs.add('python_path', '~/python/')
-
- # Should rope save object information or not.
- prefs['save_objectdb'] = True
- prefs['compress_objectdb'] = False
-
- # If `True`, rope analyzes each module when it is being saved.
- prefs['automatic_soa'] = True
- # The depth of calls to follow in static object analysis
- prefs['soa_followed_calls'] = 0
-
- # If `False` when running modules or unit tests "dynamic object
- # analysis" is turned off. This makes them much faster.
- prefs['perform_doa'] = True
-
- # Rope can check the validity of its object DB when running.
- prefs['validate_objectdb'] = True
-
- # How many undos to hold?
- prefs['max_history_items'] = 32
-
- # Shows whether to save history across sessions.
- prefs['save_history'] = True
- prefs['compress_history'] = False
-
- # Set the number spaces used for indenting. According to
- # :PEP:`8`, it is best to use 4 spaces. Since most of rope's
- # unit-tests use 4 spaces it is more reliable, too.
- prefs['indent_size'] = 4
-
- # Builtin and c-extension modules that are allowed to be imported
- # and inspected by rope.
- prefs['extension_modules'] = []
-
- # Add all standard c-extensions to extension_modules list.
- prefs['import_dynload_stdmods'] = True
-
- # If `True` modules with syntax errors are considered to be empty.
- # The default value is `False`; When `False` syntax errors raise
- # `rope.base.exceptions.ModuleSyntaxError` exception.
- prefs['ignore_syntax_errors'] = False
-
- # If `True`, rope ignores unresolvable imports. Otherwise, they
- # appear in the importing namespace.
- prefs['ignore_bad_imports'] = False
-
-
-def project_opened(project):
- """This function is called after opening the project"""
- # Do whatever you like here!
@@ -1,3 +0,0 @@
-�}qU
-headlightsq]qU
-Headlightsqas.
@@ -1 +0,0 @@
-�]q(]q]qe.
@@ -1 +0,0 @@
-�}q.
Oops, something went wrong.

0 comments on commit fc87426

Please sign in to comment.