ITADN

Update trash(1) man page for clarity, compatibility notes, and examples

#362Pull Requestyashwanth2706 创建于 2025-02-03
Y
yashwanth2706commented
Purpose of the Changes This PR updates the trash man page to: Clarify compatibility quirks with GNU rm options. Improve documentation of metadata retention (e.g., original path, deletion date). Add practical examples for edge cases (e.g., files starting with -). Standardize cross-references and external links for consistency. Key Changes Compatibility Notes Explicitly documented that -d, -f, -i, -r, and -R are retained only for GNU rm compatibility but have no functional effect. This prevents user confusion for those transitioning from rm to trash. Metadata Documentation Added details about retained metadata (original path, deletion date, permissions) to the DESCRIPTION section, aligning with the FreeDesktop.org Trash Specification. Examples Included examples for handling files with leading dashes (e.g., trash -- -foo), which addresses a common edge case. Standardized example formatting for consistency. Cross-References Linked related commands (trash-list, trash-restore, etc.) in the SEE ALSO section. Added a direct URL to the FreeDesktop.org Trash Specification for easy access. Updated the bug report link to the current GitHub repository. Typos and Formatting Fixed minor formatting issues (e.g., consistent use of backticks for commands). Improved grammar and readability in option descriptions. Why These Changes Matter User Experience: Users transitioning from rm will immediately understand why certain flags (e.g., -f) behave differently in trash. Transparency: Explicitly documenting metadata retention helps users trust the tool’s behavior (e.g., knowing files can be fully restored). Discoverability: The added examples and cross-references make the man page more actionable for new users. Testing Local Review: Generated and reviewed the man page locally with man ./trash.1 to ensure proper formatting. Example Validation: Tested all commands in the EXAMPLES section to confirm they work as described (e.g., trash -- -foo).
合并状态:未合并 关闭于 2025-06-29 2 条评论