Skip to content

Commit

Permalink
Переезд на vitepress
Browse files Browse the repository at this point in the history
  • Loading branch information
JoCat committed Nov 19, 2022
1 parent 59ab893 commit a815bf7
Show file tree
Hide file tree
Showing 37 changed files with 1,592 additions and 6,041 deletions.
15 changes: 15 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# EditorConfig is awesome: https://EditorConfig.org

# top-most EditorConfig file
root = true

[*]
indent_style = space
indent_size = 2
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true

[*.md]
trim_trailing_whitespace = false
11 changes: 3 additions & 8 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,7 @@ on:

jobs:
deploy:
runs-on: ${{ matrix.os }}

strategy:
matrix:
os: [ubuntu-latest]
node: [14]
runs-on: ubuntu-latest

steps:
- name: Checkout
Expand All @@ -20,7 +15,7 @@ jobs:
- name: Setup Node.js environment
uses: actions/[email protected]
with:
node-version: ${{ matrix.node }}
node-version: 18

- name: Cache node_modules
uses: actions/cache@v2
Expand Down Expand Up @@ -54,7 +49,7 @@ jobs:
REMOTE_HOST: ${{ secrets.SSH_SERVER_IP }}
REMOTE_USER: ${{ secrets.SSH_USER }}
REMOTE_PORT: ${{ secrets.SSH_SERVER_PORT }}
SOURCE: "docs/.vuepress/dist/"
SOURCE: "docs/.vitepress/dist/"
TARGET: ${{ secrets.SITE_DIR }}

- name: Clearing the Cloudflare cache
Expand Down
4 changes: 1 addition & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
/node_modules
/docs/.vuepress/.cache
/docs/.vuepress/.temp
/docs/.vuepress/dist
/docs/.vitepress/dist
5 changes: 5 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"yaml.schemas": {
"https://json.schemastore.org/github-workflow.json": ".github/workflows/deploy.yml"
}
}
52 changes: 18 additions & 34 deletions docs/.vuepress/config.js → docs/.vitepress/config.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
const navbar = require("./navbar");
const sidebar = require("./sidebar");
import { navbar } from "./navbar";
import { sidebar } from "./sidebar";

module.exports = {
lang: "ru",
export default {
lang: "ru-RU",
title: "Aurora Launcher",
description:
"Лаунчер с удобной кастомизацией дизайна для игровых проектов Minecraft",
bundler: "@vuepress/bundler-vite",
head: [
[
"link",
Expand Down Expand Up @@ -51,39 +50,24 @@ module.exports = {
],
["meta", { name: "theme-color", content: "#ffffff" }],
],
locales: {
"/": {
lang: "alpha",
},
"/next/": {
lang: "next",
},
},
themeConfig: {
logo: "/logo.png",
// navbar,
// sidebar,
locales: {
"/": {
navbar: navbar.alpha,
sidebar: sidebar.alpha,
selectLanguageName: "v0.0.3",
selectLanguageText: "v0.0.3",
},
"/next/": {
navbar: navbar.next,
sidebar: sidebar.next,
selectLanguageName: "next",
selectLanguageText: "next",
nav: navbar,
sidebar,
socialLinks: [
{
icon: "discord",
link: "https://discord.aurora-launcher.ru",
},
},
},
plugins: [
[
"@vuepress/plugin-google-analytics",
{
id: "G-Z4BQX6LZKB",
icon: "github",
link: "https://github.com/AuroraTeam/LauncherServer",
},
],
],
outlineTitle: "На этой странице",
docFooter: {
prev: "Предыдущая страница",
next: "Следующая страница",
},
},
};
37 changes: 37 additions & 0 deletions docs/.vitepress/navbar.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
export const navbar = [
{
text: "Базовая настройка",
link: "/basic/",
},
{
text: "Для разработчиков",
items: [
{
text: "Aurora API",
items: [
{
text: "Общая информация",
link: "/for-developers/api/info",
},
{
text: "Список кодов ошибок",
link: "/for-developers/api/errors",
},
],
},
{
text: "Прочее",
items: [
{
text: "Альтернативные зеркала",
link: "/for-developers/mirrors",
},
],
},
],
},
{
text: "На главный сайт",
link: "https://aurora-launcher.ru",
},
];
43 changes: 43 additions & 0 deletions docs/.vitepress/sidebar.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
export const sidebar = {
"/basic/": [
{
text: "Базовая настройка",
items: [
{
text: "Начало работы",
link: "/basic/",
},
{
text: "Игровые клиенты",
link: "/basic/clients",
},
],
},
],
"/for-developers/api/": [
{
text: "Aurora API",
items: [
{
text: "Общая информация",
link: "/for-developers/api/info",
},
{
text: "Список кодов ошибок",
link: "/for-developers/api/errors",
},
],
},
],
"/for-developers/": [
{
text: "Прочее",
items: [
{
text: "Альтернативные зеркала",
link: "/for-developers/mirrors",
},
],
},
],
};
6 changes: 6 additions & 0 deletions docs/.vitepress/theme/custom.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
:root {
scroll-behavior: smooth;

/* TODO */
/* https://github.com/vuejs/vitepress/blob/main/src/client/theme-default/styles/vars.css */
}
4 changes: 4 additions & 0 deletions docs/.vitepress/theme/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
import DefaultTheme from "vitepress/theme";
import "./custom.css";

export default DefaultTheme;
62 changes: 0 additions & 62 deletions docs/.vuepress/navbar.js

This file was deleted.

51 changes: 0 additions & 51 deletions docs/.vuepress/sidebar.js

This file was deleted.

51 changes: 0 additions & 51 deletions docs/.vuepress/styles/index.scss

This file was deleted.

Loading

0 comments on commit a815bf7

Please sign in to comment.