Skip to content

Commit

Permalink
chore: update CI to deploy bugfixes
Browse files Browse the repository at this point in the history
  • Loading branch information
lukicenturi committed Oct 11, 2024
1 parent d0719c1 commit 7c9cc4d
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 21 deletions.
8 changes: 8 additions & 0 deletions .github/workflows/deploy-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on:
branches:
- main
- develop
- bugfixes

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
Expand Down Expand Up @@ -46,6 +47,13 @@ jobs:
env:
DOCS_VERSION: latest

- name: Build bugfixes (patch) docs
run: |
git checkout bugfixes
pnpm run build --outDir .vitepress/dist/patch
env:
DOCS_VERSION: patch

- name: Combine builds
run: |
mv .vitepress/dist-main/* .vitepress/dist/
Expand Down
40 changes: 22 additions & 18 deletions .vitepress/config.mts
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,10 @@ import { tabsMarkdownPlugin } from 'vitepress-plugin-tabs';

const __dirname = path.dirname(fileURLToPath(new URL(import.meta.url)));

const isLatest = process.env.DOCS_VERSION === 'latest';
const base = isLatest ? '/latest' : '/';
const DOCS_VERSION = process.env.DOCS_VERSION;
const isLatest = DOCS_VERSION === 'latest';
const isPatch = DOCS_VERSION === 'patch';
const base = isLatest || isPatch ? `/${DOCS_VERSION}` : '/';

// https://vitepress.dev/reference/site-config
export default defineConfig({
Expand All @@ -21,22 +23,24 @@ export default defineConfig({
{ text: 'Home', link: '/' },
{ text: 'Documentation', link: '/requirement-and-installation' },
{ text: 'Download', link: 'https://rotki.com/download' },
{
text: isLatest ? 'Latest' : 'Stable',
items: [
isLatest
? {
text: 'Stable',
link: 'https://docs.rotki.com/',
target: '_blank',
}
: {
text: 'Latest',
link: 'https://docs.rotki.com/latest/',
target: '_blank',
},
],
},
...(isPatch
? []
: [{
text: isLatest ? 'Latest' : 'Stable',
items: [
isLatest
? {
text: 'Stable',
link: 'https://docs.rotki.com/',
target: '_blank',
}
: {
text: 'Latest',
link: 'https://docs.rotki.com/latest/',
target: '_blank',
},
],
}]),
],

sidebar: [
Expand Down
14 changes: 11 additions & 3 deletions .vitepress/theme/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,17 @@

:root {
--vp-home-hero-name-color: transparent;
--vp-home-hero-name-background: -webkit-linear-gradient(120deg, var(--vp-c-brand-1) 30%, var(--vp-c-brand-1) 30%);

--vp-home-hero-image-background-image: linear-gradient(-45deg, var(--vp-c-brand-1) 50%, var(--vp-c-brand-1) 50%);
--vp-home-hero-name-background: -webkit-linear-gradient(

Check failure on line 102 in .vitepress/theme/style.css

View workflow job for this annotation

GitHub Actions / ci

Replace `⏎····120deg,⏎····var(--vp-c-brand-1)·30%,⏎····var(--vp-c-brand-1)·30%⏎··` with `120deg,·var(--vp-c-brand-1)·30%,·var(--vp-c-brand-1)·30%`
120deg,
var(--vp-c-brand-1) 30%,
var(--vp-c-brand-1) 30%
);

--vp-home-hero-image-background-image: linear-gradient(

Check failure on line 108 in .vitepress/theme/style.css

View workflow job for this annotation

GitHub Actions / ci

Replace `⏎····-45deg,⏎····var(--vp-c-brand-1)·50%,⏎····var(--vp-c-brand-1)·50%⏎··` with `-45deg,·var(--vp-c-brand-1)·50%,·var(--vp-c-brand-1)·50%`
-45deg,
var(--vp-c-brand-1) 50%,
var(--vp-c-brand-1) 50%
);
--vp-home-hero-image-filter: blur(44px);
}

Expand Down

0 comments on commit 7c9cc4d

Please sign in to comment.