Git Product home page Git Product logo

docs.pact.io's Introduction

Pact Docs Website

Netlify Status

Sync Pact docs

Table of Contents

Local development

The files are markdown, stored under the docs directory.

You will need Docker and Docker Compose to run the docs application locally.

docker-compose up

Adding pages

Moving pages

  • Find the file under the docs directory.
  • Move it to the directory/name you want.
  • Update website/sidebars.json.
  • Do a file search and replace to update any internal references to the page.
  • Create a redirect in netlify.toml.

Automatic syncing from the markdown files in each Pact implementation repository

The markdown files in the following directories are synced from their respective source repositories. Do not edit them directly! You'll be able to tell if it's a file that has been synced from another repository because the custom_edit_url will be set in the page metadata.

  • docs/implementation_guides/go
  • docs/implementation_guides/javascript
  • docs/implementation_guides/jvm
  • docs/implementation_guides/python
  • docs/implementation_guides/cpp
  • docs/implementation_guides/rust
  • docs/implementation_guides/net
  • docs/pact_broker/client_cli
  • docs/pact_broker/docker_images/
  • docs/pact_broker/kubernetes/

Each of the above Pact repositories has a Github workflow that triggers the sync-docs workflow when any markdown files are edited on master.

When the sync-docs workflow runs, it pulls in the master markdown files from the changed repository, syncs and processes them, and then commits and pushes them. On push, Netlify automatically deploys.

Slack history

Because the free version of slack only lets you read the last 10k of messages, and at the time of writing this (March 2021) that means about 97k messages are gone, it's helpful to have access to the history.

You can docs.pact.io/slack/

To update the export:

  1. Download the latest extract from https://pact-foundation.slack.com/services/export
  2. Extract into a directory
  3. Download this php file (to e.g. slack.php) into the same directory as the export: https://gist.github.com/mefellows/1b825c86b2ff1063afbb2e5cb6b8cb3e
  4. Run this script php slack.php
  5. Sync the HTML files from slack2html/html/* into the website/static/slack directory

Hosting

The Pact docs site is hosted by Netlify. Thanks!

The site will be automatically redeployed after any push to master.

Deploys by Netlify

Search

The search is provided free by Algolia because Pact is an open source project.

  1. An algolia crawler is defined here to crawl the docs.pact.io sitemap here
  2. An algolia search index is configured here and the crawler results are stored in the search index
  3. The docs.pact.io website which is built on docusaurus, is configured
    1. in ./website/docusaurus.config.js under themeConfig.algolia
  4. The Search analytics page is here.
    1. It is accessed via the [email protected] account
  • Info on how to style the search UI is here.

Contributing

See CONTRIBUTING.md

Contact

docs.pact.io's People

Contributors

bethesque avatar you54f avatar mefellows avatar dependabot[bot] avatar elliottmurray avatar uglyog avatar davidvc avatar aliciaforeman avatar tinexw avatar thetreeofgrace avatar timothyjones avatar b3nnyl avatar ahanafy avatar muirandy avatar opicaud avatar sergeyklay avatar thatguysimon avatar joacand avatar issafalcon avatar edouard-lopez avatar lewis-prescott-cruk avatar ertrzyiks avatar andrew-demb avatar bheemreddy181 avatar inksprout avatar surpher avatar patricekrakow avatar ruben-perez avatar rdarge avatar rafaelaazevedo avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.