Skip to content

Commit ab24b79

Browse files
committed
Merge branch 'master' of https://github.com/chubin/cheat.sh
2 parents 7864990 + 9063184 commit ab24b79

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

lib/adapter/cmd.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ def _get_list(self, prefix=None):
5454
return _get_filenames(PATH_CHEAT_PAGES)
5555

5656
def _get_page(self, topic, request_options=None):
57-
cmd = ["cheat", topic]
57+
cmd = ["/usr/local/bin/cheat", topic]
5858
proc = Popen(cmd, stdout=PIPE, stderr=PIPE)
5959
answer = proc.communicate()[0].decode('utf-8')
6060
return answer

lib/frontend/ansi.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,10 @@
2828
# pylint: disable=wrong-import-position
2929
sys.path.append(os.path.abspath(os.path.join(__file__, '..')))
3030
from globals import COLOR_STYLES
31-
import languages_data
32-
import beautifier # pylint: enable=wrong-import-position
31+
import languages_data # pylint: enable=wrong-import-position
3332

3433
import fmt.internal
34+
import fmt.comments
3535

3636
def visualize(answer_data, request_options):
3737
"""
@@ -72,7 +72,7 @@ def _colorize_ansi_answer(topic, answer, color_style, # pylint: disable=to
7272
highlight = lambda x: x
7373

7474
if highlight_code:
75-
blocks = beautifier.code_blocks(
75+
blocks = fmt.comments.code_blocks(
7676
answer, wrap_lines=True, unindent_code=(4 if unindent_code else False))
7777
highlighted_blocks = []
7878
for block in blocks:

lib/globals.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434

3535
if USE_OS_PACKAGES:
3636
PATH_TLDR_PAGES = "/home/igor/.tldr/cache/pages/*/*.md"
37-
PATH_CHEAT_PAGES = "/usr/local/lib/python2.7/dist-packages/cheat/cheatsheets/*"
37+
PATH_CHEAT_PAGES = "/usr/share/cheat/*"
3838
PATH_CHEAT_SHEETS = "/home/igor/cheat.sheets/sheets/"
3939
PATH_CHEAT_SHEETS_SPOOL = "/home/igor/cheat.sheets/spool/"
4040
PATH_LEARNXINY = "/home/igor/git/github.com/adambard/learnxinyminutes-docs"

0 commit comments

Comments
 (0)