Skip to content

Commit

Permalink
Merge pull request #3 from ujjwal-ibm/readme-fix
Browse files Browse the repository at this point in the history
changed folder structure, fixed logger issues
  • Loading branch information
ujjwal-ibm authored Nov 28, 2024
2 parents 23097be + 0e29c1e commit 01e1177
Show file tree
Hide file tree
Showing 34 changed files with 124 additions and 346 deletions.
File renamed without changes.
File renamed without changes.
7 changes: 4 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -106,10 +106,8 @@ ipython_config.py
#pdm.lock
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
# in version control.
# https://pdm.fming.dev/latest/usage/project/#working-with-version-control
# https://pdm.fming.dev/#use-with-ide
.pdm.toml
.pdm-python
.pdm-build/

# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
__pypackages__/
Expand Down Expand Up @@ -160,3 +158,6 @@ cython_debug/
# and can be added to the global gitignore or merged into this file. For a more nuclear
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
#.idea/

path/*
*.docx
4 changes: 2 additions & 2 deletions boxtodocx/CHANGELOG.md → CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
## [1.0.0] - 2024-11-28

### Added
- Initial release of boxnotetodocx
- Initial release of boxtodocx
- Command-line interface for converting BoxNote files
- Support for single file conversion
- Support for batch directory conversion
- Box API integration for image downloading
- HTML to DOCX conversion with formatting preservation
- HTML to docx conversion with formatting preservation
- Support for tables, lists, and images
- Comprehensive error handling and logging
- Documentation and contribution guidelines
Expand Down
10 changes: 5 additions & 5 deletions boxtodocx/CONTRIBUTING.md → CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
# Contributing to BoxNote to DOCX Converter
# Contributing to BoxNote to docx Converter

Thank you for your interest in contributing to BoxNote to DOCX Converter! This document provides guidelines and instructions for contributing.
Thank you for your interest in contributing to BoxNote to docx Converter! This document provides guidelines and instructions for contributing.

## Development Setup

1. Clone the repository:
```bash
git clone [email protected]:ujjwal-ibm/boxnoteconvertor.git
cd boxnoteconvertor/boxnotetodocx
git clone [email protected]:ujjwal-ibm/boxtodocx.git
cd boxtodocx
```

2. Create a virtual environment:
Expand Down Expand Up @@ -47,7 +47,7 @@ pytest

For test coverage:
```bash
pytest --cov=boxnotetodocx
pytest --cov=boxtodocx
```

## Pull Request Process
Expand Down
21 changes: 0 additions & 21 deletions LICENSE

This file was deleted.

2 changes: 1 addition & 1 deletion boxtodocx/MANIFEST.in → MANIFEST.in
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ include CHANGELOG.md
include requirements.txt
include requirements-dev.txt

recursive-include src/boxnotetodocx *
recursive-include src/boxtodocx *
recursive-exclude * __pycache__
recursive-exclude * *.py[cod]
recursive-exclude tests *
69 changes: 46 additions & 23 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,39 +1,62 @@
# boxnoteconvertor
A tool to convert boxnotes to docx(for now)
# BoxNote to docx Converter

A Python command-line tool to convert Box Notes to Microsoft Word (docx) documents with preservation of formatting, tables, and images.

### **Getting Started with `boxtodocx`**
## Features

set up the core tool—`boxtodocx`. Follow these steps:
- Convert single BoxNote files to docx
- Batch convert entire directories of BoxNote files
- Preserve formatting, tables, and images
- Support for Box API authentication
- Simple command-line interface

## Installation

#### **1. Clone the Repository**
```bash
git clone https://github.com/ujjwal-ibm/boxnoteconvertor.git

pip3 install .
```

#### **2. Navigate to the Tool Directory**
## Usage

### Basic Usage

Convert a single file:
```bash
cd boxnoteconvertor/boxtodocx
boxtodocx example.boxnote
```

#### **3. Install the Tool**
Install the package using Python’s package manager:
Convert all files in a directory:
```bash
pip3 install .
boxtodocx /path/to/directory
```

#### **4. Verify Installation**
You can now use the command-line tool:
### Advanced Options

```bash
boxnotetodocx --help
boxtodocx --help

Options:
-d, --dir TEXT Work directory for temporary files
-t, --token TEXT Box access token
-o, --output TEXT Output file name (only for single file conversion)
-u, --user TEXT Box user id
-v, --verbose Enable verbose logging
--help Show this message and exit
```

#### **5. Conversion Examples**
- **Single File Conversion**:
```bash
boxnotetodocx example.boxnote
```
- **Batch Conversion for a Directory**:
```bash
boxnotetodocx /path/to/directory
```
## Authentication

To use Box API features (like image downloading), you need to provide a Box access token:

```bash
boxtodocx input.boxnote -t "your_box_token" -u "your_user_id"
```

## Development

See [CONTRIBUTING.md](CONTRIBUTING.md) for development setup and guidelines.

## License

This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
File renamed without changes.
163 changes: 0 additions & 163 deletions boxtodocx/.gitignore

This file was deleted.

Loading

0 comments on commit 01e1177

Please sign in to comment.