Decathlon / wiki-page-creator-action

Create a GitHub wiki page based on the provided markdown file
Apache License 2.0
94 stars 20 forks source link

Support Spaces in file names #7

Closed Andre601 closed 4 years ago

Andre601 commented 4 years ago

When you have files/pages that contain spaces (e.g configure bot.md) does the action treat those as separate pages and errors with the following message(s):

cp: can't stat 'wiki/configure.md': No such file or directory

The action should support spaces by f.e. replacing them with dashes (-).

didnotwant commented 4 years ago

Putting spaces in filenames is not a good practice, though.

I edited my comment because I thought that your problem is similar to mine but it’s not. But what’s related to your problem is that in this repo I could find a pull request (#10) which added a support for converting underscores _ to spaces in sidebar.


Let me connect to your thread because I think it’s not worth creating yet another one:

I have no clue why hyphens are converted to spaces in the sidebar: e.g. filename "How-to-use.md" results in "How to use" on the list: image

@mmornati — do you have any knowledge on this?

For now the best approach I can choose to not rely on the filename in the sidebar is to create a custom sidebar.

mmornati commented 4 years ago

@didnotwant It is by design in GitHub wiki pages I guess: in the wiki the - are automatically converted in spaces.

mmornati commented 4 years ago

@Andre601 I think I can try to fix problem allowing the action to take care to file with spaces... but I'm not sure what is then the result in GitHub.