This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
# Sizes - Calculate and sort all filesizes for current folder Includes | |
# directory sizes, colorized output Brett Terpstra 2019 WTF License | |
VERSION = "1.0.1" | |
require 'shellwords' | |
# Just including term-ansicolor by @flori and avoiding all the | |
# rigamarole of requiring multiple files when it's not a gem... - Brett | |
# |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. Install Exuberant Ctags | |
2. Create ~/.ctags with the following content to (rudimentary) support XQuery for ctags: | |
--langdef=xquery | |
--langmap=xquery:.xq.xqm.xqy | |
--regex-xquery=/^[ \t]*declare?[ \t]*(%[^%])*[ \t]*function[ \n\t]*([_a-zA-Z0-9:-]*:)?([_a-zA-Z0-9-]+)/\3/f,function/ | |
--regex-xquery=/^[ \t]*declare[ \t]*variable[ \t]*\$([_a-zA-Z0-9:-]*:)?([_a-zA-Z0-9-]+)/\2/v,variable/ | |
--regex-xquery=/^module namespace[ \t]*(\w+)[ \t]*=.*/\1/m,module/ | |
3. Install the Tlist vim plugin: vim-taglist.sourceforge.net |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/ruby | |
=begin | |
Planter v1.3 | |
Brett Terpstra 2013 | |
ruby script to create a directory structure from indented data. | |
Three ways to use it: | |
- Pipe indented (tabs or 2 spaces) text to the script | |
- e.g. `cat "mytemplate" | planter.rb | |
- Create template.tpl files in ~/.planter and call them by their base name |