diff options
author | makefu <github@syntax-fehler.de> | 2011-08-05 21:20:13 +0200 |
---|---|---|
committer | makefu <github@syntax-fehler.de> | 2011-08-05 21:20:13 +0200 |
commit | 57d2b4a2fa034c9c87ff5b4c04ceaabf86b4842e (patch) | |
tree | 1ae7434d3f5e408a3b9d4a54a1b464b2dffd47d7 /util/bin/wiki.firstpar | |
parent | 082a2ed2761ea1dd3bd0a30d2109962ef29377f4 (diff) |
wiki.firstpar: initial commit of galileo
Diffstat (limited to 'util/bin/wiki.firstpar')
-rwxr-xr-x | util/bin/wiki.firstpar | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/util/bin/wiki.firstpar b/util/bin/wiki.firstpar new file mode 100755 index 00000000..df66f707 --- /dev/null +++ b/util/bin/wiki.firstpar @@ -0,0 +1,23 @@ +#! /bin/sh +set -euf + +A=Mozilla + +pwd="$(dirname "$(readlink -f "$0")")" + +for x in \ + "$pwd/../../submodules/github/tmpvar" \ + "$pwd/../../submodules/github/mikeal" \ + "$pwd/../../submodules/github/NV" \ + "$pwd/../../submodules/github/tautologistics" \ +; do + export NODE_PATH="`readlink -f "$x"`${NODE_PATH+:$NODE_PATH}" +done + +# ensure query is ready +#(cd "$pwd/../.." && git submodule update --init) + +query() { + node "$(readlink -f "$pwd/../../submodules/github/visionmedia/query")" "$@" +} +curl -sS -A "\${A-Mozilla}" "$1" | query 'p' 'first' | w3m -T text/html -dump |