jgm / jgm/gitit

export to ODT fails ...

Open
#337 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Haskell
Stars
2.3k
Forks
231
PR merge metrics
No merged PRs in 30d

Description

```
Server error: /home/ozn/wikis/wikidata/static/Error_Building_The_Work_Space.jpg: openFile: does not exist (No such file or directory)
```

as a work around I copied "static" into wikidata, and put the images inside it.

```
$ ls wikidata/static/
css Error_Building_The_Work_Space.jpg screenshot.1.jpg Target_Editing.jpg
Empty_Target.jpg img Target_Content.jpg
```

The problem with this work around is that, new images are uploaded in `wikidata` and not to `wikidata/static/`.

I have no clue about Haskell. But, I think this is because in the file `Handlers.hs` the variable `dropWhile` is hard coded:

```
uploadFile :: Handler
uploadFile = withData $ \(params :: Params) -> do
let origPath = pFilename params
let filePath = pFilePath params
let wikiname = normalise
$ dropWhile (=='/')
```

IMHO, it would make sense to make this a configurable option.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.