aboutsummaryrefslogtreecommitdiff
path: root/misc/term-color
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2013-01-13 17:32:58 -0200
committerSilvio Rhatto <rhatto@riseup.net>2013-01-13 17:32:58 -0200
commita64487d5db57b9e281a5953b082618d2c1fca8a4 (patch)
treebfd1f26e5eaccf9cfd3d2809a49161beceb7f9b6 /misc/term-color
parentf6978c1b28db3308808f2e303c607047f97a96c5 (diff)
downloadscripts-a64487d5db57b9e281a5953b082618d2c1fca8a4.tar.gz
scripts-a64487d5db57b9e281a5953b082618d2c1fca8a4.tar.bz2
Removing old scripts and cleaning up some code
Diffstat (limited to 'misc/term-color')
-rwxr-xr-xmisc/term-color43
1 files changed, 0 insertions, 43 deletions
diff --git a/misc/term-color b/misc/term-color
deleted file mode 100755
index 85bf44b..0000000
--- a/misc/term-color
+++ /dev/null
@@ -1,43 +0,0 @@
-#! /usr/bin/env python
-# Copyright (C) 2006 by Johannes Zellner, <johannes@zellner.org>
-# modified by mac@calmar.ws to fit my output needs
-# modified by crncosta@carloscosta.org to fit my output needs
-# pyroscope.project@gmail.com added a final "tput init", and changed the output format
-
-import os
-import sys
-
-def echo(msg):
- os.system('echo -n "' + str(msg) + '"')
-
-def out(n):
- os.system("tput setab " + str(n) + "; echo -n " + ("\"% 4d\"" % n))
- os.system("tput setab 0")
-
-if os.getenv("TERM") in ("xterm", "screen"):
- os.putenv("TERM", os.getenv("TERM") + "-256color")
-
-try:
- # normal colors 1 - 16
- os.system("tput setaf 16")
- for n in range(8):
- out(n)
- echo("\n")
- for n in range(8, 16):
- out(n)
-
- echo("\n")
- echo("\n")
-
- y=16
- while y < 256:
- for z in range(0,18):
- out(y)
- y += 1
- if y >= 256: break
-
- echo("\n")
-
- echo("\n")
-finally:
- os.system("tput init")