doc2markdown


Namedoc2markdown JSON
Version 0.1.2 PyPI version JSON
download
home_pagehttps://github.com/adam404/doc2markdown
SummaryA tool to convert various document formats to Markdown
upload_time2024-09-05 03:01:52
maintainerNone
docs_urlNone
authorYour Name
requires_python>=3.6
licenseNone
keywords
VCS
bugtrack_url
requirements sourcPyPDF2 python-pptx python-docx pycryptodome
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # 📄 doc2markdown

`doc2markdown` is a Python command-line tool that converts various document formats (PDF, PPTX, DOCX) to Markdown. It processes files in a given directory and its subdirectories, maintaining the original folder structure in the output.

## ✨ Features

- 📑 Converts PDF, PPTX, and DOCX files to Markdown format
- 🗂️ Preserves folder structure from input to output
- 💻 Command-line interface for easy use and integration with other tools
- 🔍 Verbose mode for detailed processing information

## ⚙️ Installation

To install `doc2markdown`, run the following command:

```bash
pip install doc2markdown
```

This will install `doc2markdown` along with its dependencies.

## 🚀 Usage

Basic usage:

```bash
doc2markdown /path/to/input/file.pdf /path/to/output/folder 
```

```bash
doc2markdown /path/to/input/folder /path/to/output/folder
```

With verbose output:

```bash
doc2markdown /path/to/input/folder /path/to/output/folder -v
```

For help and more options:

```bash
doc2markdown --help
```

## 🛠️ Requirements

- Python 3.6+
- PyPDF2
- python-pptx
- python-docx

These dependencies will be automatically installed when you install `doc2markdown` using pip.

## 🚀 Future Improvements

We're constantly working to improve doc2markdown. Here are some features and enhancements we're considering for future releases:

### TODO:

- [ ] Implement parallel processing for faster conversion of multiple files
- [ ] Add a progress bar for large batches of file conversions
- [ ] Create a plugin system for easy addition of new file format converters
- [ ] Implement comprehensive unit tests for each converter function
- [ ] Add logging mechanism for better debugging and user feedback
- [ ] Implement input sanitization for enhanced security
- [ ] Add type hints throughout the codebase for improved readability and maintainability
- [ ] Create a CONTRIBUTING.md file with guidelines for contributors

We welcome contributions from the community to help implement these features and improve doc2markdown. If you're interested in working on any of these tasks, please check our issues page or submit a pull request.

## 📝 Changelog

### [0.1.2] 
- Renamed to doc2markdown
- Added support for encrypted PDFs

### [0.1.1] 
- Added File as well as folder support
- Improved the CLI messaging

### [0.1.0] 
- Initial release
- Basic functionality to convert PDF, PPTX, and DOCX files to Markdown
- Command-line interface with verbose mode option

## 🤝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

## 📜 License

This project is licensed under the MIT License.

## 🙏 Acknowledgements 

This tool was inspired by the need for easy conversion of various document formats to Markdown for use with Large Language Models and other text processing applications.

## Contributing

### Bumping the Version

To bump the version of the project, use the `bump_version.py` script:

1. Navigate to the project root directory.
2. Run the script with the following command:

   ```bash
   python bump_version.py doc2markdown/__init__.py [major|minor|patch]
   ```

   Replace `[major|minor|patch]` with the type of version bump you want to perform.

3. Commit the changes:

   ```bash
   git add doc2markdown/__init__.py
   git commit -m "Bump version to x.y.z"
   ```

4. Tag the new version:

   ```bash
   git tag -a vx.y.z -m "Version x.y.z"
   ```

5. Push the changes and tags:

   ```bash
   git push origin main
   git push --tags
   ```

This process will update the version number in the `__init__.py` file and create a new git tag for the release.

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/adam404/doc2markdown",
    "name": "doc2markdown",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.6",
    "maintainer_email": null,
    "keywords": null,
    "author": "Your Name",
    "author_email": "me@adamscott.info",
    "download_url": "https://files.pythonhosted.org/packages/22/e1/8f02c5fae5aec6768dcfc31b863117b611b8b08b0323470564cadd725255/doc2markdown-0.1.2.tar.gz",
    "platform": null,
    "description": "# \ud83d\udcc4 doc2markdown\n\n`doc2markdown` is a Python command-line tool that converts various document formats (PDF, PPTX, DOCX) to Markdown. It processes files in a given directory and its subdirectories, maintaining the original folder structure in the output.\n\n## \u2728 Features\n\n- \ud83d\udcd1 Converts PDF, PPTX, and DOCX files to Markdown format\n- \ud83d\uddc2\ufe0f Preserves folder structure from input to output\n- \ud83d\udcbb Command-line interface for easy use and integration with other tools\n- \ud83d\udd0d Verbose mode for detailed processing information\n\n## \u2699\ufe0f Installation\n\nTo install `doc2markdown`, run the following command:\n\n```bash\npip install doc2markdown\n```\n\nThis will install `doc2markdown` along with its dependencies.\n\n## \ud83d\ude80 Usage\n\nBasic usage:\n\n```bash\ndoc2markdown /path/to/input/file.pdf /path/to/output/folder \n```\n\n```bash\ndoc2markdown /path/to/input/folder /path/to/output/folder\n```\n\nWith verbose output:\n\n```bash\ndoc2markdown /path/to/input/folder /path/to/output/folder -v\n```\n\nFor help and more options:\n\n```bash\ndoc2markdown --help\n```\n\n## \ud83d\udee0\ufe0f Requirements\n\n- Python 3.6+\n- PyPDF2\n- python-pptx\n- python-docx\n\nThese dependencies will be automatically installed when you install `doc2markdown` using pip.\n\n## \ud83d\ude80 Future Improvements\n\nWe're constantly working to improve doc2markdown. Here are some features and enhancements we're considering for future releases:\n\n### TODO:\n\n- [ ] Implement parallel processing for faster conversion of multiple files\n- [ ] Add a progress bar for large batches of file conversions\n- [ ] Create a plugin system for easy addition of new file format converters\n- [ ] Implement comprehensive unit tests for each converter function\n- [ ] Add logging mechanism for better debugging and user feedback\n- [ ] Implement input sanitization for enhanced security\n- [ ] Add type hints throughout the codebase for improved readability and maintainability\n- [ ] Create a CONTRIBUTING.md file with guidelines for contributors\n\nWe welcome contributions from the community to help implement these features and improve doc2markdown. If you're interested in working on any of these tasks, please check our issues page or submit a pull request.\n\n## \ud83d\udcdd Changelog\n\n### [0.1.2] \n- Renamed to doc2markdown\n- Added support for encrypted PDFs\n\n### [0.1.1] \n- Added File as well as folder support\n- Improved the CLI messaging\n\n### [0.1.0] \n- Initial release\n- Basic functionality to convert PDF, PPTX, and DOCX files to Markdown\n- Command-line interface with verbose mode option\n\n## \ud83e\udd1d Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request.\n\n## \ud83d\udcdc License\n\nThis project is licensed under the MIT License.\n\n## \ud83d\ude4f Acknowledgements \n\nThis tool was inspired by the need for easy conversion of various document formats to Markdown for use with Large Language Models and other text processing applications.\n\n## Contributing\n\n### Bumping the Version\n\nTo bump the version of the project, use the `bump_version.py` script:\n\n1. Navigate to the project root directory.\n2. Run the script with the following command:\n\n   ```bash\n   python bump_version.py doc2markdown/__init__.py [major|minor|patch]\n   ```\n\n   Replace `[major|minor|patch]` with the type of version bump you want to perform.\n\n3. Commit the changes:\n\n   ```bash\n   git add doc2markdown/__init__.py\n   git commit -m \"Bump version to x.y.z\"\n   ```\n\n4. Tag the new version:\n\n   ```bash\n   git tag -a vx.y.z -m \"Version x.y.z\"\n   ```\n\n5. Push the changes and tags:\n\n   ```bash\n   git push origin main\n   git push --tags\n   ```\n\nThis process will update the version number in the `__init__.py` file and create a new git tag for the release.\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "A tool to convert various document formats to Markdown",
    "version": "0.1.2",
    "project_urls": {
        "Homepage": "https://github.com/adam404/doc2markdown"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "a4191fd61b9a48bf4772746abc18f3146279197a1ef35e4348009c6a024ba601",
                "md5": "ea35158230c3042f89c5f261f429927c",
                "sha256": "1621696dec3edf792422a5272b340bb2d6bfa302c244ed1c16f665c28807e424"
            },
            "downloads": -1,
            "filename": "doc2markdown-0.1.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "ea35158230c3042f89c5f261f429927c",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.6",
            "size": 5600,
            "upload_time": "2024-09-05T03:01:50",
            "upload_time_iso_8601": "2024-09-05T03:01:50.192592Z",
            "url": "https://files.pythonhosted.org/packages/a4/19/1fd61b9a48bf4772746abc18f3146279197a1ef35e4348009c6a024ba601/doc2markdown-0.1.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "22e18f02c5fae5aec6768dcfc31b863117b611b8b08b0323470564cadd725255",
                "md5": "76f31a48b66ceaeeda92abaf6ae0b4d7",
                "sha256": "8d42896d7964870f0ee073ad45bf507d61006984ea93353dbd1e31bf18348147"
            },
            "downloads": -1,
            "filename": "doc2markdown-0.1.2.tar.gz",
            "has_sig": false,
            "md5_digest": "76f31a48b66ceaeeda92abaf6ae0b4d7",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.6",
            "size": 6730,
            "upload_time": "2024-09-05T03:01:52",
            "upload_time_iso_8601": "2024-09-05T03:01:52.531835Z",
            "url": "https://files.pythonhosted.org/packages/22/e1/8f02c5fae5aec6768dcfc31b863117b611b8b08b0323470564cadd725255/doc2markdown-0.1.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-09-05 03:01:52",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "adam404",
    "github_project": "doc2markdown",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "requirements": [
        {
            "name": "sourcPyPDF2",
            "specs": []
        },
        {
            "name": "python-pptx",
            "specs": []
        },
        {
            "name": "python-docx",
            "specs": []
        },
        {
            "name": "pycryptodome",
            "specs": []
        }
    ],
    "lcname": "doc2markdown"
}
        
Elapsed time: 0.35449s