Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
docs:vim:creating_php_function_list_file [2009/08/15 12:14] – created billhdocs:vim:creating_php_function_list_file [2009/08/15 15:53] (current) billh
Line 14: Line 14:
 :%s/<[^>]*>//g :%s/<[^>]*>//g
 </code> </code>
-  - FIXME incomplete steps! +  - remove the 'Description' and leading spaces, run<code> 
-  - remove the 'Description' and return types, run<code> +:%s/^\s*Description\s*//g
-:%s/^\s*Description\s*[a-zA-Z]*\s*//g+
 </code> </code>
   - to create the dictionary, run<code>   - to create the dictionary, run<code>
-:%s/^\([^[:space:]]\+\) \([^[:space:]]\+\) ( \(.*\))/\\ '\2(': '\3\1',+:%s/^\([^[:space:]]\+\) \([^[:space:]]\+\) ( \(.*\)/\\ '\2(': '\3) returns \1',/
 +</code> 
 +  - remove all non-dictionary lines, run<code> 
 +:%s/^[^\\]*\n//
 +</code> 
 +  - FIXME add the other necessary items, such as removing dollar signs and correct the ending parenthesis issue on some lines; then show how to finish the file and what to name it and where to put it; I'm doing the following in a new window and then executing it on the func file<code> 
 +:g/Description/normal! 5J 
 +:%s/<[^>]*>//
 +:%s/^\s*Description\s*//
 +:%s/^\([^[:space:]]\+\) \([^[:space:]]\+\) (\(.*\)/\\ '\2(': '\3) returns \1',/g 
 +:%s/^[^\\]*//
 +:%s/^\n//
 +:%s/))/)/
 +:%s/' /'/g 
 +:sort 
 +:sort u 
 + 
 +(we still need to fix a few bugs and clean up &amp; and &quot; values, maybe fixing open ['s too) 
 + 
 +it looks like the file should be called php.vim, and placed in ~/.vim/after/ftplugin/
 </code> </code>
  • docs/vim/creating_php_function_list_file.1250360065.txt.gz
  • Last modified: 2009/08/15 12:14
  • by billh