laurencer / confluence-sync

A command line tool for syncing HTML/Markdown to Confluence!
BSD 3-Clause "New" or "Revised" License
82 stars 10 forks source link

Support for as-is page names #2

Closed laurencer closed 8 years ago

laurencer commented 8 years ago

Currently page names are automatically title cased based on a few rules: my-file-name.md becomes My File Name as a page. This is nice for the common case but can make a few pages look extremely messy, especially where there is an acronym: ABC Learning becoming Abc Learning.

It would be fantastic if the user could specify whether to preserve the original casing of a file name.

One way to approach this is to embed this in-band. My current thinking is that appending a . at the end of the file or directory name could be used to disable any case modifications. For example ABC-Learning..md would become ABC Learning, and a folder named ATMs. would become ATMs.

laurencer commented 8 years ago

\cc @pdericson - any thoughts on this, not sure if you've come across this problem?

pdericson commented 8 years ago

How about splitting on hyphen and only capitalising the words that do not contain any upper case characters?

laurencer commented 8 years ago

Good idea - might implement that as an initial stop gap (behind a feature flag).

laurencer commented 8 years ago

Implemented in master behind a feature flag.