wblock@
Developer
Firefox accepts the names of HTML files from the command line, which is easy to complete in csh(1):
.cshrc:
But I also discovered recently that Firefox can jump directly to anchors in files if they are included in the filename:
It would be nice to complete for that. When the user has typed
But it's not clear to me whether the parameter containing the filename is available ($1?) or how to use it in the completion. This would be a c or C completion of the current parameter.
Any ideas?
.cshrc:
Code:
complete firefox 'n/*/f:*.{[hH][tT][mM][lL]}/'
But I also discovered recently that Firefox can jump directly to anchors in files if they are included in the filename:
firefox book.html#overview-quick-start
It would be nice to complete for that. When the user has typed
firefox book.html#
, pressing Tab would complete from the list of anchors, HTML IDs. The IDs can be pulled out of the HTML file:
Code:
perl -ne 'print "$1\n" if /id="(.*?)">?/' book.html | sort -u
Any ideas?