Skip to content

Commit

Permalink
Refine (#27)
Browse files Browse the repository at this point in the history
* Refine

* Update

* Update mkdocs.yml

Co-authored-by: fisher <[email protected]>

* Fix naming related to precompile

* Update mkdocs.yml

* Delete docs/blog directory

* Update mkdocs.yml

---------

Co-authored-by: fisher <[email protected]>
  • Loading branch information
AurevoirXavier and hackfisher authored Apr 16, 2024
1 parent d461426 commit a547a5a
Show file tree
Hide file tree
Showing 13 changed files with 1,045 additions and 183 deletions.
30 changes: 15 additions & 15 deletions .github/workflows/deploy-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,24 +9,24 @@ jobs:
name: Deploy
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- uses: actions/checkout@v2
- name: Fetch latest code
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Build pages
run: |
pip3 install poetry
poetry run poetry install --no-root
poetry run mkdocs build
- name: Setup Vercel environment
uses: actions/checkout@v4
with:
repository: darwinia-network/devops
path: .github

- uses: actions/setup-python@v5
with:
python-version: 3.x

- name: build
run: |
pip install mkdocs-material mkdocs-git-revision-date-localized-plugin
mkdocs build
- uses: ./.github/actions/smart-vercel
name: Deploy to Vercel
- name: Deploy to Vercel
uses: ./.github/actions/smart-vercel
with:
vercel_token: ${{ secrets.VERCEL_TOKEN }}
vercel_group: itering
Expand Down
32 changes: 16 additions & 16 deletions .github/workflows/deploy-prd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,27 +7,27 @@ on:

jobs:
deploy:
name: Deploy
name: Deploy pages
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- uses: actions/checkout@v2
- name: Fetch latest code
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Build pages
run: |
pip3 install poetry
poetry run poetry install --no-root
poetry run mkdocs build
- name: Setup Vercel environment
uses: actions/checkout@v4
with:
repository: darwinia-network/devops
path: .github

- uses: actions/setup-python@v5
with:
python-version: 3.x

- name: build
run: |
pip install mkdocs-material mkdocs-git-revision-date-localized-plugin
mkdocs build
- uses: ./.github/actions/smart-vercel
name: Deploy to Vercel
- name: Deploy to Vercel
uses: ./.github/actions/smart-vercel
with:
vercel_token: ${{ secrets.VERCEL_TOKEN }}
vercel_group: itering
Expand Down
27 changes: 11 additions & 16 deletions .github/workflows/deploy-stg.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,24 +9,19 @@ jobs:
name: Deploy
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- uses: actions/checkout@v2
with:
repository: darwinia-network/devops
path: .github

- uses: actions/setup-python@v5
- name: Fetch latest code
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: 3.x

- name: build
python-version: "3.12"
- name: Build pages
run: |
pip install mkdocs-material mkdocs-git-revision-date-localized-plugin
mkdocs build
- uses: ./.github/actions/smart-vercel
name: Deploy to Vercel
pip3 install poetry
poetry run poetry install --no-root
poetry run mkdocs build
- name: Deploy to Vercel
uses: ./.github/actions/smart-vercel
id: smart-vercel
with:
vercel_token: ${{ secrets.VERCEL_TOKEN }}
Expand Down
31 changes: 17 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,26 +1,29 @@
# Welcome to the Darwinia Documentation

This repository contains the source files for the Darwinia documentation. The documentation is built using [MkDocs](https://www.mkdocs.org/) with the [Material for MkDocs](https://squidfunk.github.io/mkdocs-material/) theme.
This repository hosts the source files for Darwinia's documentation, built with [MkDocs](https://www.mkdocs.org/) using the [Material for MkDocs](https://squidfunk.github.io/mkdocs-material/) theme.

## Building the Documentation Locally

To build the documentation locally, you will need to have Python and pip installed. Once you have those, follow these steps:
To build the documentation on your local machine, ensure you have Python and pip installed. Then follow these steps:

1. Clone this repository.
2. Navigate to the root directory of the cloned repository.
3. Run `pip install mkdocs-material mkdocs-git-revision-date-localized-plugin` to install the necessary dependencies.
4. Run `mkdocs serve` to start the local development server.
5. Open your web browser and navigate to `http://127.0.0.1:8000` to view the documentation.
```sh
# Clone the repository.
git clone https://github.com/darwinia-network/document.git && document
# Install necessary dependencies.
pip install mkdocs-material mkdocs-git-authors-plugin mkdocs-git-revision-date-localized-plugin
# View the documentation in your browser at `http://127.0.0.1:8000`.
mkdocs serve
```

## Contributing to the Documentation

We welcome contributions to the documentation. If you would like to contribute, please follow these steps:
Contributions are welcome! To contribute:

1. Clone this repository.
2. Make your changes to the Markdown files in the `docs` directory.
3. Build the documentation locally to ensure that your changes are formatted correctly.
4. Submit a pull request with your changes.
1. Fork this repository.
2. Edit Markdown files in the `docs` folder.
3. Build locally to check formatting.
4. Create a pull request with your updates.

We will review your pull request and merge it as soon as possible.
We'll review and merge your pull request promptly.

Thank you for your contributions to the Darwinia documentation!
Thanks for contributing to Darwinia's documentation!
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
10 changes: 6 additions & 4 deletions docs/resource/stylesheets/extra.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
:root {
--md-primary-fg-color: #FF0083;
--md-primary-fg-color--light: #FF0083;
--md-primary-fg-color--dark: #A00959;
[data-md-color-scheme="default"] {
--md-primary-fg-color: rgb(255, 0, 131);
}

[data-md-color-scheme="slate"] {
--md-primary-fg-color: rgb(189, 45, 120);
}
Loading

0 comments on commit a547a5a

Please sign in to comment.