Skip to content

Commit

Permalink
initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
yndx-birman committed Sep 22, 2023
0 parents commit b5169a9
Show file tree
Hide file tree
Showing 55 changed files with 3,093 additions and 0 deletions.
61 changes: 61 additions & 0 deletions actions/build/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: docs-build-action
description: Build & Upload Docs

inputs:
revision:
required: true
project-name:
required: true
src-root:
required: true
storage-bucket:
required: true
storage-endpoint:
required: true
storage-access-key-id:
required: true
storage-secret-access-key:
required: true
storage-region:
required: true
lint-root:
default: "./_docs-lint"
build-root:
default: "./_docs-build"
shared-storage-bucket:
default: false
type: boolean

runs:
using: composite
steps:
- uses: actions/setup-node@v3
with:
node-version: 14
- run: npm i @doc-tools/docs -g
shell: bash
- run: yfm -i ${{ inputs.src-root }} -o ${{ inputs.lint-root }}
shell: bash
- name: build
run: |
yfm -i ${{ inputs.src-root }} -o ${{ inputs.build-root }} --output-format md --add-map-file --allow-custom-resources
shell: bash
- name: Set DEST_DIR
shell: bash
run: |
if [ "${{ inputs.shared-storage-bucket }}" == "true" ]; then
echo "DEST_DIR=${{ inputs.project-name }}/rev/${{ inputs.revision }}" >> $GITHUB_ENV
else
echo "DEST_DIR=rev/${{ inputs.revision }}" >> $GITHUB_ENV
fi
- name: Upload S3
shell: bash
run: |
yfm publish \
-i ${{ inputs.build-root }} \
--endpoint ${{ inputs.storage-endpoint }} \
--region ${{ inputs.storage-region }} \
--bucket ${{ inputs.storage-bucket }} \
--prefix ${{ env.DEST_DIR }} \
--access-key-id ${{ inputs.storage-access-key-id }} \
--secret-access-key ${{ inputs.storage-secret-access-key }}
72 changes: 72 additions & 0 deletions actions/release/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
name: docs-release-action
description: Build & Upload Docs & Release

inputs:
revision:
required: true
project-name:
required: true
src-root:
required: true
default: "./"
storage-bucket:
required: true
storage-endpoint:
required: true
storage-access-key-id:
required: true
storage-secret-access-key:
required: true
storage-region:
required: true
lint-root:
default: "./_docs-lint"
build-root:
default: "./_docs-build"
shared-storage-bucket:
type: boolean
default: false

runs:
using: composite
steps:
- name: Build
uses: ./actions/build
with:
src-root: ${{ inputs.src-root }}
revision: ${{ inputs.revision }}
project-name: ${{ inputs.project-name }}
storage-bucket: ${{ inputs.storage-bucket }}
storage-endpoint: ${{ inputs.storage-endpoint }}
storage-access-key-id: ${{ inputs.storage-access-key-id }}
storage-secret-access-key: ${{ inputs.storage-secret-access-key }}
storage-region: ${{ inputs.storage-region }}
lint-root: ${{ inputs.lint-root }}
build-root: ${{ inputs.build-root }}
shared-storage-bucket: ${{ inputs.shared-storage-bucket }}
- name: Create head folder
shell: bash
run: mkdir -p head
- name: Write revision to head file
shell: bash
run: |
echo "{ \"revision\": \"${{ inputs.revision }}\" }" > head/head
- name: Set DEST_DIR
shell: bash
run: |
if [ "${{ inputs.shared-storage-bucket }}" == "true" ]; then
echo "DEST_DIR=${{ inputs.project-name }}" >> $GITHUB_ENV
else
echo "DEST_DIR=/" >> $GITHUB_ENV
fi
- name: Upload head file to storage
shell: bash
run: |
yfm publish \
-i head \
--endpoint ${{ inputs.storage-endpoint }} \
--region ${{ inputs.storage-region }} \
--bucket ${{ inputs.storage-bucket }} \
--prefix ${{ env.DEST_DIR }} \
--access-key-id ${{ inputs.storage-access-key-id }} \
--secret-access-key ${{ inputs.storage-secret-access-key }}
11 changes: 11 additions & 0 deletions docs/.yfm
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
disableLiquid: true
allowHTML: true
langs: ['ru']

docs-viewer:
project-name: diplodoc
favicon-src: https://storage.yandexcloud.net/diplodoc-www-assets/favicon/favicon.ico
logo-src: https://storage.yandexcloud.net/diplodoc-www-assets/navigation/diplodoc-logo.svg
logo-link-preview: https://storage.yandexcloud.net/diplodoc-www-assets/navigation/diplodoc-logo.svg
github-url-prefix: https://github.com/diplodoc-platform/docs/blob/master
logo-title: Diplodoc
Binary file added docs/ru/_images/leading.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/ru/_images/overview.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/ru/_images/overview_landing_black.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/ru/_images/overview_landing_white.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/ru/_images/terms_sample.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions docs/ru/_images/user-settings.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/ru/_images/user_settings.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions docs/ru/_includes/file.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fake file
20 changes: 20 additions & 0 deletions docs/ru/_includes/plugins.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
#|
|| Название плагина | Описание | Параметры | Подключен по умолчанию |
|| **Anchors**| Автоматическое генерирование [якорей для заголовков](../syntax/base.md#headers) | `extractTitle`: учитывать заголовок первого уровня</br> Тип: bool, По умолчанию: false </br></br>`supportGithubAnchors`: генерировать дополнительные якоря, совместимые с GitHub</br> Тип: bool, По умолчанию: false | + ||
|| **Code**| Отображение кнопки копирования в [блоках кода](../syntax/code.md#block) | - | + ||
|| **Cut** | Поддержка разметки [катов](../syntax/cuts-tabs.md#cuts) | - | + ||
|| **Deflist**| Поддержка разметки [списка определений](../syntax/lists.md#terms) | - | + ||
|| **File** | Поддержка разметки [объектов файлов](../syntax/links.md#files) | `fileExtraAttrs`: дополнительные атрибуты для ссылки | + ||
|| **Tasks list** | Добавление [списка задач](../syntax/additional.md#tasks-list) | `divClass`: classname для div, который оборачивает чекбокс</br> Тип: string, По умолчанию: checkbox </br></br> `idPrefix`: перфикс для id чекбокса</br> Тип: string, По умолчанию: checkbox | - ||
|| **Images** | Добавление [изображений](../syntax/media.md#images) | `assetsPublicPath`: путь до иконок</br> Тип: string, По умолчанию: / | - ||
|| **Imsize** | Задание размера изображений | - | - ||
|| **Includes** | Переиспользование контента в документе | `getVarsPerFile`: функция, которая по пути к файлу возвращает вычисленные переменные</br> Тип: function, По умолчанию: - | - ||
|| **Links** | Расширение [синтаксиса ссылок](../syntax/links.md) | - | - ||
|| **Monospace** | [Моноширинный шрифт](../syntax/base.md) | - | + ||
|| **Meta** | Добавление [метаданных](../syntax/meta.md#meta) в начало файлов | - | + ||
|| **Notes** | Поддержка разметки [заметок](../syntax/notes.md) | `lang`: язык для отображения типа заметки</br> Тип: string, По умолчанию: ru | + ||
|| **Sup** | Вывод текста в [верхнем регистре](../syntax/base.md#line) | - | + ||
|| **Table** | Поддержка [многострочных таблиц](../syntax/tables/multiline.md) | - | + ||
|| **Tabs** | Поддержка разметки [табов](../syntax/cuts-tabs.md#tabs) | - | + ||
|| **Video** | Добавление [видео](../syntax/media.md#video) | - | + ||
|#
14 changes: 14 additions & 0 deletions docs/ru/about.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Diplodoc

Diplodoc - это платформа работы с документацией в парадигме Documentation as a Code.

Вы можете создавать свои документационные проекты в YFM, cо всей структурой, контентом и элементами, необходимыми для качественного предоставления информации пользователям.

Достоинства платформы:

* простота использования;
* скорость работы;
* общепринятый формат Markdown;
* обширная функциональность;
* интеграция с системами автоматической документации;
* поиск.
Loading

0 comments on commit b5169a9

Please sign in to comment.