Closed nazdridoy closed 9 months ago
oh man, when the final appimage pr drops, it will probably have an entire research paper attached :smiley:
i just can't ignore š
I poured my heart and soul into this tool
oh and i hate when people submit pull requests with a 315-line edit spread across 69 files and their PR description is simply
'Updated some files to have this.' š
A pull request should provide as much detail as possible. Although, I suppose my PR template might be overly elaborate for a modest +10/-6 PR... XD
Description
This pull request introduces changes to the way f95checker handles file writing, specifically for log files. Previously, log files were being written directly to
globals.self_path
, which could lead to clutter and issues in environments whereself_path
is read-only or has restrictive permissions (such as when packaged for AUR). To address this, I've refactored the code to ensure all log files are neatly organized in alogs
subfolder withinglobals.data_path
. This change keeps the executable path clean, avoids clutter, and ensures compatibility with read-only or restricted permission environments.Changes
globals.py
Adjustment: Ensured that alogs
subfolder is created withinglobals.data_path
if it doesn't already exist. This provides a dedicated space for storing log files.Refactored File Writing Operations:
login_broken.bin
,check_broken.bin
,notifs_broken.bin
,update_broken.bin
, andlog.txt
) were being written toglobals.self_path
. These files are now correctly written to thelogs
subfolder withinglobals.data_path
.Motivation
The main motivation behind these changes is to maintain a clean executable path and to address potential issues with file writing permissions, especially when the application is packaged for distribution (e.g., AUR). By organizing log files into a dedicated subfolder within
globals.data_path
, we not only avoid clutter but also circumvent the complications arising from read-only or restricted permission scenarios.Testing
self_path
is read-only.Impact