-
Notifications
You must be signed in to change notification settings - Fork 0
Improve table handling and formatting in markdown-to-man conversion #4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: markdown-to-man
Are you sure you want to change the base?
Conversation
@petrasovaa could you please check this out |
Sure, I will try to find some time for it |
- Add hierarchical section numbering (1., 1.1) with descriptive labels (Main Section/Subsection) - Implement explicit list nesting markers with level indicators and type detection - Add space padding (\fB text \fR) to improve source readability - Resolve list index error in nested list processing
I sincerely apologize for any inconvenience caused. I tested the changes manually, and my output seemed correct, but I noticed the differences in the images you shared. Could you kindly share how you tested it? I’d love to follow the same process to understand where the discrepancy might be. I’ve also attached images of my output file how it appeared on my end for reference. I truly appreciate your time and guidance on this. I’m really sorry for any trouble this may have caused, and I’ll make sure to get this sorted properly. |
Hi Sachin, I saw the screenshots you posted on OSGeo wiki and I think you are seeing different output from Anna because you are directly viewing the content of the file without using the (To avoid any confusion, I am also a fellow contributor in Grass). |
Thank you so much for the clarification! That makes a lot of sense, |
- Added table processing functionality with troff/groff table format conversion - Improved YAML front matter stripping and block parsing logic - Enhanced special character handling, especially in code blocks - Better heading and list processing with proper indentation - Added UTF-8 encoding support for file operations - Refactored argument parsing and output formatting
@petrasovaa , when you have a moment, could you please review my changes? I’d really appreciate your feedback. |
…andling, and groff escapes - Added comprehensive table support using groff's TS/TE macros - Implemented more robust Markdown formatting handling (bold/italic/combined) - Introduced proper groff special character escaping (~, ^, `, etc) - Improved list processing with better indentation handling - Added paragraph (.PP) and section formatting - Simplified YAML front matter removal - Implemented block-based parsing architecture - Added UTF-8 encoding support for file operations - Enhanced code block formatting with proper font switching - Unified heading conversion logic - Improved text wrapping and whitespace handling - Added support for alternative Markdown syntax (bold/italic) - Removed fragile regex substitutions in favor of structured parsing - Added proper documentation section formatting
@petrasovaa sorry for the bother, can you kindly check the changes , when you have a moment |
This looks better, but even from your screenshots I can still see some markdown leftovers (headings, formatting, links). Plus you are not converting the right files, the md files in the source code are missing autogenerated headers, so you need to compile GRASS and then use the md files in ./dist.x86_64-pc-linux-gnu/docs/mkdocs/source which have the header, see my previous screenshot. |
Got it! I’ll make sure to use the correct files from after compiling GRASS and clean up any leftover markdown formatting. Thanks for pointing it out |
@petrasovaa Kindly review it when you have some time. Please let me know if any updates are required. |
Sorry for taking me so long to respond... Looking at your last screenshot, the header is still not there. Have you compiled GRASS to generate the markdown file? |
This PR enhances the Markdown-to-manpage converter with several improvements:
New Features
Improvements