Fix issue #49: Show correct time on login/lock screen#19
Fix issue #49: Show correct time on login/lock screen#19ericbsd merged 1 commit intoghostbsd:masterfrom
Conversation
During install, the file /var/db/zoneinfo is not created. This change now creates the file so the user's local time is shown on the login and lock screens.
Reviewer's Guide by SourceryThis pull request addresses an issue where the timezone file No diagrams generated as the changes look simple and do not need a visual representation. File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
There was a problem hiding this comment.
Hey @mfjurbala - I've reviewed your changes - here's some feedback:
Overall Comments:
- Consider ensuring the parent directory exists before writing to
${FSMNT}/var/db/zoneinfo.
Here's what I looked at during the review
- 🟡 General issues: 1 issue found
- 🟢 Security: all looks good
- 🟢 Testing: all looks good
- 🟢 Complexity: all looks good
- 🟢 Documentation: all looks good
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
| { | ||
| TZONE="$1" | ||
| cp ${FSMNT}/usr/share/zoneinfo/${TZONE} ${FSMNT}/etc/localtime | ||
| echo ${TZONE} | tee ${FSMNT}/var/db/zoneinfo > /dev/null |
There was a problem hiding this comment.
suggestion (bug_risk): Quote shell variables to avoid word splitting issues.
Wrap variable references in double quotes (e.g. "${TZONE}" and "${FSMNT}/var/db/zoneinfo") to ensure the script handles values with spaces or special characters correctly.
Suggested implementation:
cp "${FSMNT}/usr/share/zoneinfo/${TZONE}" "${FSMNT}/etc/localtime"
echo "${TZONE}" | tee "${FSMNT}/var/db/zoneinfo" > /dev/null
During install, the file /var/db/zoneinfo is not created. This change now creates the file so the user's local time is shown on the login and lock screens.
Summary by Sourcery
Bug Fixes:
/var/db/zoneinfoduring setup.