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

No documentation generated when quotes in pathname #1049

Closed
hasanabuzayed opened this issue Feb 14, 2019 · 5 comments
Closed

No documentation generated when quotes in pathname #1049

hasanabuzayed opened this issue Feb 14, 2019 · 5 comments

Comments

@hasanabuzayed
Copy link

I've being trying run jazzy on different projects on my machine but it doesn't seems to be working, I tried uninstalling and reinstalling it, yet the same results, updated xcode-select, gem, ruby.
these are different ways I tried to run jazzy on my project:

  1. just simply jazzy command
  2. jazzy --min-acl internal/private
  3. file .json/yaml
{
    "xcodebuild_arguments": ["-project", "MyProject.xcodeproj", "-configuration", "Debug", "-target", "MyProject"],
    "author": "Company Inc",
    "author_url": "https://github.com/project/MyProject",
    "module": "MyProject",
    "sdk": "iphonesimulator",
}

as for the output I always get

Running xcodebuild
0% documentation coverage with 0 undocumented symbols
building site
building search index
jam out ♪♫ to your fresh new docs in `docs`

This is my system:
macOS: 10.14.2 (18C54)
Xcode: 10.1 (10B61)
Swift: 4.2.1
Jazzy: 0.9.5
Ruby: ruby 2.3.7p456 (2018-03-28 revision 63024) [universal.x86_64-darwin18]

@johnfairh
Copy link
Collaborator

This means SourceKitten has identified a Swift module MyProject being built but can't find any Swift source files that are part of it.

You'll need to look at the output from, looking at the last of your examples above, xcodebuild clean build -project MyProject.xcodeproj -configuration Debug -target MyProject unless you can share it.

The code that tries to parse the output is here and then here -- that final filter is evaluating to the empty list.

My blind guess is either an Xcode configuration issue or some unusual filesystem characters somehow confusing a regexp. Jazzy is a bit more downlevel on SourceKitten than I'd thought but it should be fine.

@hasanabuzayed
Copy link
Author

hasanabuzayed commented Feb 14, 2019

You blind guess was the wildest, my colleague and I thought of so many different scenarios but folder naming issue was not one of them.
So this /Users/username/Development/Xcode'sProjects/Project/MyProject was my pwd when I faced the issue, but then I tried moving the project to a different directory when no ' character, and it worked.
I would usually face such issues if I have spaces on my folders names which I stopped don't but I had no idea that ' would cause such issues as well.

Thank you so much @johnfairh I spent

@johnfairh johnfairh changed the title No documentation is being generated No documentation generated when quotes in pathname Feb 15, 2019
@jpsim
Copy link
Collaborator

jpsim commented Apr 6, 2019

jpsim/SourceKitten#577 was merged

@fbeeper
Copy link

fbeeper commented Apr 25, 2019

I just had a similar issue with parenthesis in my project path. Jazzy would fail to generate my documentation while raising a bunch of WARNING: No documented top-level declarations match name XXX specified in categories file. But it works correctly when I remove the parenthesis.

As far as I understand, jpsim/SourceKitten#577 is a fix for escaping and this would be covered as well. However, I thought it may be useful to add this information here for anyone lost with similar warnings not noticing the problem can be rooted on the path characters.

Thanks for your great work :)

@johnfairh
Copy link
Collaborator

Included in jazzy master now via #1076

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants