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

set up configuration to input subproject's urls and docpath #167

Merged
merged 1 commit into from
Jun 21, 2017

Conversation

pri22296
Copy link
Member

@pri22296 pri22296 commented Jun 21, 2017

Description

  • add two new env var SUBPROJECT_URLS and SUBPROJECT_DOCPATHS which would contain comma seperated urls and docpaths respectively.
    A user would be able to set it from the .yaydoc.yml file like this
metadata:
  projectname: testYaydoc2
  author: Priyam Singh
  debug: true
  subproject:
    - url: https://github.com/testYaydoc2.git
      docpath: 'docs'
    - url: https://github.com/testYaydoc.git
      docpath: 'doc'

Resultant output

export DOCTHEME="fossasia_theme"
export SUBPROJECT_DOCPATHS="docs,doc"
export SUBPROJECT_URLS="https://github.com/testYaydoc2.git,https://github.com/testYaydoc.git"
export MARKDOWN_FLAVOUR="markdown_github"
export LOGO=""
export AUTHOR="Priyam Singh"
export VERSION="Jun 21, 2017"
export DOCPATH="docs"
export PROJECTNAME="testYaydoc2"

Related Issue

#160

Motivation and Context

This is required so that user's would be easily able to specify subprojects

How Has This Been Tested?

Screenshots (if appropriate):

Types of changes

  • Bug fix
  • New feature

Checklist:

  • I have read the Contribution & Best practices Guide and my PR follows them.
  • There is a corresponding issue for this pull request.
  • Mentioned the Issue number in the pull request commit message Fixes #<number> commit message
  • There is only one commit per issue.

@pri22296
Copy link
Member Author

@imujjwal96 @Sch00lb0y Please review

Copy link
Contributor

@imujjwal96 imujjwal96 left a comment

Choose a reason for hiding this comment

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

Looks good to me

@imujjwal96
Copy link
Contributor

Can you show how these Env Vars would look with your example yaml

@pri22296
Copy link
Member Author

@imujjwal96 I have updated the description with the output

@imujjwal96
Copy link
Contributor

@pri22296 any token to check if subprojects exist? Or the presence of values in these two env vars is enuff?

@pri22296
Copy link
Member Author

That logic would have to be handled by the script which clones the subprojects. I think config.py should be limited to reading values from .yaydoc.yml and exporting env vars from that.

@imujjwal96
Copy link
Contributor

@pri22296 What about the name of the subprojects?

@pri22296
Copy link
Member Author

For now let's default with the repository name? or maybe i could add an extra field for it and default it with reponame extracted from the url? any other fields we should expose in the subproject section?

@imujjwal96
Copy link
Contributor

I don't think so

@pri22296
Copy link
Member Author

okay a query! where would we need the subproject's name in the build process?

@imujjwal96
Copy link
Contributor

imujjwal96 commented Jun 21, 2017

I guess we won't 👌
We can work with splitting the reponames.

@mariobehling mariobehling merged commit 5912511 into fossasia:master Jun 21, 2017
@pri22296 pri22296 deleted the subproject branch June 22, 2017 08:54
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.

4 participants