diff options
author | Amjith Ramanujam <amjith.r@gmail.com> | 2015-02-08 20:33:04 -0800 |
---|---|---|
committer | Amjith Ramanujam <amjith.r@gmail.com> | 2015-02-08 20:33:04 -0800 |
commit | 2576ce1bf59b6b10c22118e5e85181267c78227f (patch) | |
tree | 052414ce53d2fd2669d8cbfe84e7ec58def4b525 | |
parent | be9622e1c31a6045c15e7f1211e18855740cc1a3 (diff) |
Override LESS options completely.
-rw-r--r-- | changelog.rst | 10 | ||||
-rwxr-xr-x | pgcli/main.py | 11 |
2 files changed, 14 insertions, 7 deletions
diff --git a/changelog.rst b/changelog.rst index 0d89a50c..e4290ac9 100644 --- a/changelog.rst +++ b/changelog.rst @@ -1,4 +1,12 @@ -Current +0.15.3 +====== +* Override the LESS options completely instead of appending to it. + +0.15.2 +======= +* Revert back to using psycopg2 as the postgres adapter. psycopg2cffi fails for some tests in Python 3. + +0.15.0 ======= Features: diff --git a/pgcli/main.py b/pgcli/main.py index 94bd6db6..c9e7c6ab 100755 --- a/pgcli/main.py +++ b/pgcli/main.py @@ -267,13 +267,12 @@ class PGCli(object): def adjust_less_opts(self): less_opts = os.environ.get('LESS', '') self.logger.debug('Original value for LESS env var: %r', less_opts) - if not less_opts: - os.environ['LESS'] = '-RXF' + os.environ['LESS'] = '-RXF' - if 'X' not in less_opts: - os.environ['LESS'] += 'X' - if 'F' not in less_opts: - os.environ['LESS'] += 'F' + #if 'X' not in less_opts: + #os.environ['LESS'] += 'X' + #if 'F' not in less_opts: + #os.environ['LESS'] += 'F' return less_opts |