Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/xbmlz/uniconv
Using LibreOffice as a server for converting documents.
https://github.com/xbmlz/uniconv
converter document docx go golang libreoffice office openoffice pdf pptx xlsx
Last synced: about 1 month ago
JSON representation
Using LibreOffice as a server for converting documents.
- Host: GitHub
- URL: https://github.com/xbmlz/uniconv
- Owner: xbmlz
- License: mit
- Created: 2024-02-01T07:10:44.000Z (11 months ago)
- Default Branch: main
- Last Pushed: 2024-02-01T07:25:54.000Z (11 months ago)
- Last Synced: 2024-06-21T15:36:59.765Z (6 months ago)
- Topics: converter, document, docx, go, golang, libreoffice, office, openoffice, pdf, pptx, xlsx
- Language: Go
- Homepage:
- Size: 16.6 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Uniconv
[![Build Status](https://github.com/xbmlz/uniconv/actions/workflows/ci.yml/badge.svg?branch=main)](https://github.com/features/actions)
[![Coverage Status](https://coveralls.io/repos/github/xbmlz/uniconv/badge.svg?branch=main)](https://coveralls.io/github/xbmlz/uniconv?branch=main)
[![Go Report Card](https://goreportcard.com/badge/github.com/xbmlz/uniconv)](https://goreportcard.com/report/github.com/xbmlz/uniconv)
[![Go Doc](https://godoc.org/github.com/xbmlz/uniconv?status.svg)](https://godoc.org/github.com/xbmlz/uniconv)
[![Code Size](https://img.shields.io/github/languages/code-size/xbmlz/uniconv.svg?style=flat-square)](https://github.com/xbmlz/uniconv)
[![Release](https://img.shields.io/github/release/xbmlz/uniconv.svg?style=flat-square)](https://github.com/xbmlz/uniconv/releases)Using LibreOffice as a server for converting documents.
## Requirements
- Go 1.20 or later
- [Apache OpenOffice](https://www.openoffice.org/) or [LibreOffice](https://www.libreoffice.org/); the latest stable version is usually recommended.
## Installation
```bash
go get -u github.com/xbmlz/uniconv
```## Usage
```go
package mainimport (
"fmt"
"github.com/xbmlz/uniconv"
)func main() {
// create a new processor, the default port is 2002
p := uniconv.NewProcessor()
// Start an office process and connect to the started instance (on port 2002).
p.Start()
defer p.Stop()
// Convert
c := uniconv.NewConverter()
c.Convert("input.docx", "output.pdf")
}
```