github.com/consideritdone/landslidecore@v0.0.0-20230718131026-a8b21c5cf8a7/docs/DOCS_README.md (about)

     1  # Docs Build Workflow
     2  
     3  The documentation for Tendermint Core is hosted at:
     4  
     5  - <https://docs.tendermint.com/master/>
     6  
     7  built from the files in this (`/docs`) directory for
     8  [master](https://github.com/tendermint/tendermint/tree/master/docs) respectively.
     9  
    10  ## How It Works
    11  
    12  There is a CircleCI job listening for changes in the `/docs` directory, on both
    13  the `master` branch. Any updates to files in this directory
    14  on those branches will automatically trigger a website deployment. Under the hood,
    15  the private website repository has a `make build-docs` target consumed by a CircleCI job in that repo.
    16  
    17  ## README
    18  
    19  The [README.md](./README.md) is also the landing page for the documentation
    20  on the website. During the Jenkins build, the current commit is added to the bottom
    21  of the README.
    22  
    23  ## Config.js
    24  
    25  The [config.js](./.vuepress/config.js) generates the sidebar and Table of Contents
    26  on the website docs. Note the use of relative links and the omission of
    27  file extensions. Additional features are available to improve the look
    28  of the sidebar.
    29  
    30  ## Links
    31  
    32  **NOTE:** Strongly consider the existing links - both within this directory
    33  and to the website docs - when moving or deleting files.
    34  
    35  Links to directories _MUST_ end in a `/`.
    36  
    37  Relative links should be used nearly everywhere, having discovered and weighed the following:
    38  
    39  ### Relative
    40  
    41  Where is the other file, relative to the current one?
    42  
    43  - works both on GitHub and for the VuePress build
    44  - confusing / annoying to have things like: `../../../../myfile.md`
    45  - requires more updates when files are re-shuffled
    46  
    47  ### Absolute
    48  
    49  Where is the other file, given the root of the repo?
    50  
    51  - works on GitHub, doesn't work for the VuePress build
    52  - this is much nicer: `/docs/hereitis/myfile.md`
    53  - if you move that file around, the links inside it are preserved (but not to it, of course)
    54  
    55  ### Full
    56  
    57  The full GitHub URL to a file or directory. Used occasionally when it makes sense
    58  to send users to the GitHub.
    59  
    60  ## Building Locally
    61  
    62  Make sure you are in the `docs` directory and run the following commands:
    63  
    64  ```bash
    65  rm -rf node_modules
    66  ```
    67  
    68  This command will remove old version of the visual theme and required packages. This step is optional.
    69  
    70  ```bash
    71  npm install
    72  ```
    73  
    74  Install the theme and all dependencies.
    75  
    76  ```bash
    77  npm run serve
    78  ```
    79  
    80  <!-- markdown-link-check-disable -->
    81  
    82  Run `pre` and `post` hooks and start a hot-reloading web-server. See output of this command for the URL (it is often <https://localhost:8080>).
    83  
    84  <!-- markdown-link-check-enable -->
    85  
    86  To build documentation as a static website run `npm run build`. You will find the website in `.vuepress/dist` directory.
    87  
    88  ## Search
    89  
    90  We are using [Algolia](https://www.algolia.com) to power full-text search. This uses a public API search-only key in the `config.js` as well as a [tendermint.json](https://github.com/algolia/docsearch-configs/blob/master/configs/tendermint.json) configuration file that we can update with PRs.
    91  
    92  ## Consistency
    93  
    94  Because the build processes are identical (as is the information contained herein), this file should be kept in sync as
    95  much as possible with its [counterpart in the Cosmos SDK repo](https://github.com/cosmos/cosmos-sdk/blob/master/docs/DOCS_README.md).