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

add gitContribute to customize contribution URL #505

Merged
merged 2 commits into from
Jul 19, 2016
Merged

add gitContribute to customize contribution URL #505

merged 2 commits into from
Jul 19, 2016

Conversation

superyyrrzz
Copy link
Contributor

@@ -3,6 +3,6 @@ var common = require('./common.js');

exports.transform = function (model) {
model._disableToc = model._disableToc || !model._tocPath || (model._navPath === model._tocPath);
model.docurl = model.docurl || common.getViewSourceHref(model);
model.docurl = model.docurl || common.getViewSourceHref(model, model.gitContribute);
Copy link
Contributor

@qinezh qinezh Jul 18, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need to add model.gitContribute as an input parameter?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It needs the second parameter, see https://github.com/dotnet/docfx/pull/505/files#diff-5bd22e55ddbb69d733cdb3b7284456b2R37. Thus I can link to a different branch when clicking "Improve this Doc" for conceptual doc.

object newFileRepository;
if (config.GlobalMetadata.TryGetValue("newFileRepository", out newFileRepository))
object gitRespositoryOpenToPublicContributors;
if (config.GlobalMetadata.TryGetValue("gitContribute", out gitRespositoryOpenToPublicContributors))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gitContribute [](start = 51, length = 13)

do we have documentation to update?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems document about this topic is missing... will add later.

@ansyral
Copy link
Contributor

ansyral commented Jul 19, 2016

:shipit:

@vwxyzh
Copy link
Contributor

vwxyzh commented Jul 19, 2016

✔️

@hellosnow
Copy link
Contributor

:shipit:

@qinezh
Copy link
Contributor

qinezh commented Jul 19, 2016

💯

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

Successfully merging this pull request may close these issues.

6 participants