Skip to content
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

install instruction for macOS #15

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ More [examples](/examples)

## Installation

##### On Linux-based systems

```bash
sudo add-apt-repository ppa:libreoffice/ppa
sudo apt-get update
Expand All @@ -50,6 +52,8 @@ sudo apt-get install libreoffice-writer
composer require mnvx/lowrapper
```

##### Inside a Docker container

Example of installation libreoffice into docker container:

```dockerfile
Expand All @@ -67,6 +71,30 @@ RUN mkdir -p /var/www/.cache/dconf \
&& chmod -R ugo+rwx /var/www/.config
```

##### On macOS

Watch out! For weird reasons, the LibreOffice command line binary has a non-obvious name on macOS:
`soffice`, probably because until 2010 the software was named StarOffice.
Install the necessary Java Development Kit (which is needed for LibreOffice to run) and LibreOffice
itself for example with the packet manager [brew](https://brew.sh):

```
brew install openjdk
brew install libreoffice
```
Check if LibreOffice is installed correctly:

```
soffice -v
# should show
# LibreOffice 7.0.x.x
```
And in your code tell the Converter the name of the binary:

```
$converter = new Converter('soffice');
```

## Run tests

```bash
Expand Down