Skip to content

Commit d973d80

Browse files
committed
removed hide data option from conf, its just a flag now
1 parent 55f3d36 commit d973d80

File tree

2 files changed

+2
-25
lines changed

2 files changed

+2
-25
lines changed

src/gitfetch/config.py

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -236,28 +236,6 @@ def set_custom_box(self, box: str) -> None:
236236
self.config['DEFAULT'] = {}
237237
self.config['DEFAULT']['custom_box'] = box
238238

239-
def get_show_date(self) -> bool:
240-
"""
241-
Get whether to show date labels on the contribution graph.
242-
243-
Returns:
244-
True if date labels should be shown, False otherwise
245-
"""
246-
show_date_str = self.config.get('DEFAULT', 'show_date',
247-
fallback='true')
248-
return show_date_str.lower() in ('true', '1', 'yes', 'on')
249-
250-
def set_show_date(self, show_date: bool) -> None:
251-
"""
252-
Set whether to show date labels on the contribution graph.
253-
254-
Args:
255-
show_date: Whether to show date labels
256-
"""
257-
if 'DEFAULT' not in self.config:
258-
self.config['DEFAULT'] = {}
259-
self.config['DEFAULT']['show_date'] = str(show_date).lower()
260-
261239
def save(self) -> None:
262240
"""Save configuration to file."""
263241
import os

src/gitfetch/display.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ class DisplayFormatter:
1616

1717
def __init__(self, config_manager: ConfigManager,
1818
custom_box: Optional[str] = None,
19-
show_date: Optional[bool] = None,
19+
show_date: bool = True,
2020
graph_only: bool = False,
2121
show_achievements: bool = True,
2222
show_languages: bool = True,
@@ -33,8 +33,7 @@ def __init__(self, config_manager: ConfigManager,
3333
self.enable_color = sys.stdout.isatty()
3434
self.colors = config_manager.get_colors()
3535
self.custom_box = custom_box or config_manager.get_custom_box() or "■"
36-
self.show_date = (show_date if show_date is not None
37-
else config_manager.get_show_date())
36+
self.show_date = show_date
3837
self.graph_only = graph_only
3938
self.show_achievements = show_achievements
4039
self.show_languages = show_languages

0 commit comments

Comments
 (0)