Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  1. Create a personal github access token with public_repo permission only to allow travis to deploy the java docs to the gh-pages branch. Instructions can be found here . This has already been done for the OpenSRP projects. No need to create another one at the moment.

  2. Configure a publishing source for the github pages site using directions provided here

  3. If the site has not published i.e you cannot view the projects Readme contents on http://smartregister.org/ {project repo name} , the admin should make a blank commit & push on the gh-pages branch for the project using this command git commit -S -m "Trigger CI" --allow-empty . After the push, the contents of the project's Readme files should be displayed on http://smartregister.org/ {project repo name} url.

  4. Encrypt the gitub token generated on step 1 using the following command travis encrypt GITHUB_TOKEN=actual_github_access_token . Note that this step has to be done in the project directory itself. Encrypted travis values cannot be shared between projects

    • This command will create the github access token and add it to the travis.yml file automatically.

      Code Block
      travis encrypt GITHUB_TOKEN=actual_github_access_token --add
  • You need travis installed on your local environment. Use the following commands:

    • Ubuntu :-

      • Code Block
        sudo apt install ruby ruby-dev
        sudo gem install travis

    • Mac : -

      • Code Block
        brew install ruby
        gem update --system
        gem install travis -v 1.8.8 --no-rdoc --no-ri

The following details steps for setting up travis to generate and publish javadocs to github pages. This can be done by any developer.

...