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

Source link doesn't include file name #36

Closed
belucid opened this issue Dec 9, 2013 · 5 comments
Closed

Source link doesn't include file name #36

belucid opened this issue Dec 9, 2013 · 5 comments

Comments

@belucid
Copy link

belucid commented Dec 9, 2013

Hi, thanks for the great tool.

I have my configuration as such:

  :codox {
    :sources ["src/fcms/resources"]
    :exclude [fcms.resources.collection-resource]
    :output-dir "../Falkland-CMS-docs/API/Clojure"
    :src-dir-uri "http://github.com/SnootyMonkey/Falkland-CMS/blob/master/"
    :src-linenum-anchor-prefix "L" ; for Github
  }

And the href of the source links are being generated with no file name, like such:

http://github.com/SnootyMonkey/Falkland-CMS/blob/master/#L30

The source-dir-uri part is there, as is the line number, but nothing for the file name.

Here is an example of the output: https://github.com/SnootyMonkey/Falkland-CMS/blob/gh-pages/API/Clojure/fcms.resources.item.html

@weavejester
Copy link
Owner

Which version of Codox are you using?

@belucid
Copy link
Author

belucid commented Dec 9, 2013

@belucid
Copy link
Author

belucid commented Dec 9, 2013

FWIW, I also tried it with 0.6.4, which was what hiccup is using, since I noticed their source links looked fine. I got the same result with 0.6.4.

@weavejester
Copy link
Owner

I took a closer look at your project.clj file. You've entered the wrong source path in your Codox setup. Rather than ["src"] or just leaving it blank, you've put in ["src/fcms/resources"] instead. Because it's a subdirectory of your source folder, Codox isn't able to resolve the paths.

Ideally this should raise an exception, but I don't think anyone's triggered this before.

@belucid
Copy link
Author

belucid commented Dec 10, 2013

Thanks! You're right, that worked just fine with this conf:

  :codox {
    :include [fcms.resources.common fcms.resources.collection fcms.resources.item fcms.resources.taxonomy]
    :output-dir "../Falkland-CMS-docs/API/Clojure"
    :src-dir-uri "http://github.com/SnootyMonkey/Falkland-CMS/blob/master/"
    :src-linenum-anchor-prefix "L" ; for Github
  }

I thought I'd discovered a nifty feature by setting sources to "src/fcms/resources" I was able to specify that I wanted docs for just that dir and didn't need each namespace individually.

With that config, I didn't need to worry about forgetting to add it to codox when I added a namespace. It effectively let me scope the docs to all the namespaces in the dir.

Such a config would be desirable :-)

@belucid belucid closed this as completed Dec 10, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants