From 145a81dcd6054830ae55292f1db3be1cec98a9b4 Mon Sep 17 00:00:00 2001 From: Chris Lane Date: Thu, 31 Jan 2019 17:53:34 -0500 Subject: [PATCH] Var renames Replaced more references to deprecated envvar names to their newer counterparts. --- bin/cheat | 2 +- cheat/sheet.py | 4 ++-- cheat/sheets.py | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/bin/cheat b/bin/cheat index a1a5aa6..a41647b 100755 --- a/bin/cheat +++ b/bin/cheat @@ -13,7 +13,7 @@ Usage: cheat -v Options: - -d --directories List directories on CHEATPATH + -d --directories List directories on $CHEAT_PATH -e --edit Edit cheatsheet -l --list List cheatsheets -s --search Search cheatsheets for diff --git a/cheat/sheet.py b/cheat/sheet.py index 2221084..94c7630 100644 --- a/cheat/sheet.py +++ b/cheat/sheet.py @@ -13,12 +13,12 @@ class Sheet: def copy(self, current_sheet_path, new_sheet_path): """ Copies a sheet to a new path """ - # attempt to copy the sheet to DEFAULT_CHEAT_DIR + # attempt to copy the sheet to CHEAT_DEFAULT_DIR try: shutil.copy(current_sheet_path, new_sheet_path) # fail gracefully if the cheatsheet cannot be copied. This can happen - # if DEFAULT_CHEAT_DIR does not exist + # if CHEAT_DEFAULT_DIR does not exist except IOError: Utils.die('Could not copy cheatsheet for editing.') diff --git a/cheat/sheets.py b/cheat/sheets.py index 4bbcdde..2141c1a 100644 --- a/cheat/sheets.py +++ b/cheat/sheets.py @@ -67,15 +67,15 @@ class Sheets: self.default_path(), ] - # merge the CHEATPATH paths into the sheet_paths + # merge the CHEAT_PATH paths into the sheet_paths if self._config.cheat_path: for path in self._config.cheat_path.split(os.pathsep): if os.path.isdir(path): sheet_paths.append(path) if not sheet_paths: - Utils.die('The DEFAULT_CHEAT_DIR dir does not exist ' - + 'or the CHEATPATH is not set.') + Utils.die('The CHEAT_DEFAULT_DIR dir does not exist ' + + 'or the CHEAT_PATH is not set.') return sheet_paths