Skip to content

Commit

Permalink
nilrt-snac: remove redundant error logs
Browse files Browse the repository at this point in the history
Signed-off-by: Alex Hearn <[email protected]>
  • Loading branch information
AlexHearnNI committed Sep 18, 2024
1 parent a583b28 commit 843aced
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion nilrt_snac/_configs/_opkg_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ def verify(self, args: argparse.Namespace) -> bool:
if not snac_config_file.exists():
valid = False
logger.error(f"MISSING: {OPKG_SNAC_CONF} not found")
if not snac_config_file.contains("option autoremove 1"):
elif not snac_config_file.contains("option autoremove 1"):
valid = False
logger.error(
f"MISSING: 'option autoremove 1' not found in {snac_config_file.path}"
Expand Down
2 changes: 1 addition & 1 deletion nilrt_snac/_configs/_sudo_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def verify(self, args: argparse.Namespace) -> bool:
if not config_file.exists():
valid = False
logger.error(f"MISSING: {config_file.path} not found")
if not config_file.contains("Defaults timestamp_timeout=0"):
elif not config_file.contains("Defaults timestamp_timeout=0"):
valid = False
logger.error("MISSING: immediate timestamp_timeout")
return valid
4 changes: 2 additions & 2 deletions nilrt_snac/_configs/_tmux_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,13 +57,13 @@ def verify(self, args: argparse.Namespace) -> bool:
if not snac_config_file.exists():
valid = False
logger.error(f"MISSING: {snac_config_file.path} not found")
if not snac_config_file.contains("set -g lock-after-time"):
elif not snac_config_file.contains("set -g lock-after-time"):
valid = False
logger.error("MISSING: commands to inactivity lock")
if not profile_file.exists():
valid = False
logger.error(f"MISSING: {profile_file.path} not found")
if not profile_file.contains("exec tmux"):
elif not profile_file.contains("exec tmux"):
valid = False
logger.error("MISSING: command to replace shell with tmux")
return valid
2 changes: 1 addition & 1 deletion nilrt_snac/_configs/_wifi_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def verify(self, args: argparse.Namespace) -> bool:
if not config_file.exists():
valid = False
logger.error(f"MISSING: {config_file.path} not found")
if not config_file.contains("install cfg80211 /bin/true"):
elif not config_file.contains("install cfg80211 /bin/true"):
valid = False
logger.error("MISSING: commands to fail install of WiFi modules")
return valid

0 comments on commit 843aced

Please sign in to comment.