summaryrefslogtreecommitdiffstats
path: root/contrib/awk/awklib/eg/network/protbase.awk
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/awk/awklib/eg/network/protbase.awk')
-rw-r--r--contrib/awk/awklib/eg/network/protbase.awk11
1 files changed, 11 insertions, 0 deletions
diff --git a/contrib/awk/awklib/eg/network/protbase.awk b/contrib/awk/awklib/eg/network/protbase.awk
new file mode 100644
index 0000000..16199e4
--- /dev/null
+++ b/contrib/awk/awklib/eg/network/protbase.awk
@@ -0,0 +1,11 @@
+{ request = request "\n" $0 }
+
+END {
+ BLASTService = "/inet/tcp/0/www.ncbi.nlm.nih.gov/80"
+ printf "POST /cgi-bin/BLAST/nph-blast_report HTTP/1.0\n" |& BLASTService
+ printf "Content-Length: " length(request) "\n\n" |& BLASTService
+ printf request |& BLASTService
+ while ((BLASTService |& getline) > 0)
+ print $0
+ close(BLASTService)
+}
OpenPOWER on IntegriCloud