vim - get mappings from the help tex files available with the scripts.
Here is a simple script that will show all the vim mappings from the tex file (help file that comes with the vim scripts).
This will prove to be very useful in usin gthe mappings 🙂
#!/bin/bash –
#===============================================================================# FILE: get_mappings_from_tex_for_vim.sh
# USAGE: ./get_mappings_from_tex_for_vim.sh
# DESCRIPTION: Get the mappings from tex file
# OPTIONS: —
# REQUIREMENTS: —
# BUGS: —
# NOTES: —
# AUTHOR: <a class="zem_slink" title="Amit Agarwal" rel="self" href="http://blog.amit-agarwal.co.in">Amit Agarwal (AKA), amit.agarwal@amit-agarwal.co.in
# COMPANY: Individual
# VERSION: 1.0
# CREATED: 09/06/2009 09:19:19 PM IST
# REVISION: —
#===============================================================================
file=$1
IFS=$(echo -e ’\n’)
for i in $(cat $file |<a class="zem_slink freebase/en/grep" title="Grep" rel="wikipedia" href="http://en.wikipedia.org/wiki/Grep">grep ”^..line”)
do
#echo $i |<a class="zem_slink freebase/en/awk" title="AWK" rel="homepage" href="http://cm.bell-labs.com/cm/cs/awkbook/index.html">awk -F”’” '{print $2” ” $3” ”$4}’|awk -F”&” '{print $1” ”$2}’
echo $i |awk -F”’” '{
if ( NF >= 4 )
{
print ($2”\t ->”$4”\t==»”$NF);
}
else
{
print($2”\t–>”$3);
}
fi
}’ |<a class="zem_slink freebase/en/sed" title="Sed" rel="wikipedia" href="http://en.wikipedia.org/wiki/Sed">sed ’s/\h.*(/(/’ |sed ’s/>.*&/>/’ |sed ’s/\t*-.>$//’ |sed ’s/\//’done<h6 class="zemanta-related-title">Related articles by Zemanta <ul class="zemanta-article-ul"> <li class="zemanta-article-ul-li"><a href="http://blog.amit-agarwal.co.in/2010/04/12/mappings-tex-file-vim-plugins/">Get the mappings from tex file for vim plugins (amit-agarwal.co.in) <li class="zemanta-article-ul-li"><a href="http://blog.amit-agarwal.co.in/2010/02/02/bash-script-to-change-the-vim-colorscheme-from-the-list-of-locally-available-schemes/">bash script to change the vim colorscheme from the list of locally available schemes (amit-agarwal.co.in) <li class="zemanta-article-ul-li"><a href="http://blog.amit-agarwal.co.in/2010/04/11/bash-script-change-vim-colorscheme-based-themes/">bash script to change vim colorscheme based on the available themes (amit-agarwal.co.in) <li class="zemanta-article-ul-li"><a href="http://blog.amit-agarwal.co.in/2010/03/04/mod-and-hack-the-gnome-main-menu-with-automated-scripts-to-create-a-menu-of-the-directory/">Mod and hack the GNome main menu with automated scripts to create a menu of the directory. (amit-agarwal.co.in) <li class="zemanta-article-ul-li"><a href="http://blog.amit-agarwal.co.in/2010/05/05/find-program-access-file/">Find out why a program can’t seem to access to a file (amit-agarwal.co.in) <li class="zemanta-article-ul-li"><a href="http://almirkaric.com/2010/5/2/sed-vs-awk/">sed vs awk (almirkaric.com) <div class="zemanta-pixie"><a class="zemanta-pixie-a" title="Reblog this post [with Zemanta]" href="http://reblog.zemanta.com/zemified/5536f878-8091-4635-a648-833cb8ce5acf/"><img class="zemanta-pixie-img" src="http://blog.amit-agarwal.co.in/wp-content/uploads/2010/08/reblog_b71.png" alt="Reblog this post [with Zemanta]" /><span class="zem-script more-related more-info pretty-attribution paragraph-reblog">
Related Articles:
- 2010/05/17 Script to download all the related videos from youtube with youtube-dl
- 2010/04/11 core dump checking script.
- 2010/04/11 bash script to change vim colorscheme based on the available themes
- 2010/01/18 Blog once and educate 40,000 underprivileged children of India
- 2009/06/01 3/10 results in first page of bing for my site for search term \”amit agarwal\”.