Skip to content

Commit

Permalink
docs
Browse files Browse the repository at this point in the history
  • Loading branch information
userdocs committed Mar 17, 2024
1 parent 787777a commit 6f8c3dd
Show file tree
Hide file tree
Showing 5 changed files with 120 additions and 122 deletions.
3 changes: 0 additions & 3 deletions docs/src/components/glossary.astro
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
---
const posts = await Astro.glob("/src/content/docs/glossary/*.md");
const basePath = "/" + Astro.url.pathname.split("/")[1] + "/";
const Test = Astro.url.pathname;
// const Test2 = thePath.substring(thePath.lastIndexOf('/') + 1);
---

<ul>
Expand Down
3 changes: 2 additions & 1 deletion docs/src/components/important.astro
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
---
const { id, alt } = Astro.props;
const basePath = "/" + Astro.url.pathname.split("/")[1];
---

<div class=`my-icon-container ${id}`>
<div class=`my-icon ${id}`>
<img
class=`my-icon-image ${id}`
src={`/astro-starlight/icons/${id}.svg`}
src={`${basePath}/icons/${id}.svg`}
alt={alt}
/>
</div>
Expand Down
114 changes: 57 additions & 57 deletions docs/src/content/docs/github-actions.mdx
Original file line number Diff line number Diff line change
@@ -1,57 +1,57 @@
---
title: Github Actions
hide_title: true

---

import { Advanced, Details, Modal, Tooltip, Charts, Important } from "/src/components/global.jsx"
import { Steps, Tabs, TabItem, Card, CardGrid, LinkCard, Aside, Icon } from '@astrojs/starlight/components';

There are some actions created that will build the binaries and create and artifacts. They can be viewed here:

[https://github.com/userdocs/qbittorrent-nox-static/actions](https://github.com/userdocs/qbittorrent-nox-static/actions)

Most of these actions are triggered manually by clicking on the action and running the workflow meaning you can fork the repo and use the workflows you require. Patching will work with the `multi_arch` actions as long as you configure it correctly in the action first.

These are the currently available actions.

:::tip
also generates releases based on the qbittorrent and libtorrent tags used. The release is created when the first matrix build completes and the other builds update this release as they complete.
:::

```bash
# CI triggered on pushes to the build script. Tests on x86_64 Debian buster/sid Ubuntu Focal/hirsute to make sure it all works on these platforms.
debian_based_CI.yml

# qbittorrent-nox qmake, cmake, libtorrent v1 and v2 multi build and release across these architectures - x86_64 armhf armv7 aarch64 cross built via musl prebuilt toolchains. 32 builds are created. 16 per release.
matrix_multi_build_and_release.yml

# Same as above but with options to specificy tags so that I can update previous releases.
matrix_multi_build_and_release_customs_tags.yml

# Uses https://github.com/userdocs/qbt-workflow-file to create artifacts of dependencies for the worklows.
matrix_multi_build_and_release_artifacts.yml


# Uses https://github.com/userdocs/qbt-workflow-file as a source for dependencies for the worklows.
matrix_multi_build_and_release_qbt_workflow_files.yml
```

### Github repo Actions settings

The only permissions these actions should need is:

```yaml
permissions:
contents: write
```
These are already set and should require not modification in the forked repo to run successfully.
These should be the default settings for recently forked versions of this repo that require this permission.
![](/astro-starlight/docs_images/github_settings_actions_perms.png)
You can find these settings bu going to the repo settings/actions/general
![](/astro-starlight/docs_images/github_settings_actions_options.png)
---
title: Github Actions
hide_title: true

---

import { Advanced, Details, Modal, Tooltip, Charts, Important } from "/src/components/global.jsx"
import { Steps, Tabs, TabItem, Card, CardGrid, LinkCard, Aside, Icon } from '@astrojs/starlight/components';

There are some actions created that will build the binaries and create and artifacts. They can be viewed here:

[https://github.com/userdocs/qbittorrent-nox-static/actions](https://github.com/userdocs/qbittorrent-nox-static/actions)

Most of these actions are triggered manually by clicking on the action and running the workflow meaning you can fork the repo and use the workflows you require. Patching will work with the `multi_arch` actions as long as you configure it correctly in the action first.

These are the currently available actions.

:::tip
also generates releases based on the qbittorrent and libtorrent tags used. The release is created when the first matrix build completes and the other builds update this release as they complete.
:::

```bash
# CI triggered on pushes to the build script. Tests on x86_64 Debian buster/sid Ubuntu Focal/hirsute to make sure it all works on these platforms.
debian_based_CI.yml

# qbittorrent-nox qmake, cmake, libtorrent v1 and v2 multi build and release across these architectures - x86_64 armhf armv7 aarch64 cross built via musl prebuilt toolchains. 32 builds are created. 16 per release.
matrix_multi_build_and_release.yml

# Same as above but with options to specificy tags so that I can update previous releases.
matrix_multi_build_and_release_customs_tags.yml

# Uses https://github.com/userdocs/qbt-workflow-file to create artifacts of dependencies for the worklows.
matrix_multi_build_and_release_artifacts.yml


# Uses https://github.com/userdocs/qbt-workflow-file as a source for dependencies for the worklows.
matrix_multi_build_and_release_qbt_workflow_files.yml
```

### Github repo Actions settings

The only permissions these actions should need is:

```yaml
permissions:
contents: write
```
These are already set and should require not modification in the forked repo to run successfully.
These should be the default settings for recently forked versions of this repo that require this permission.
![](/qbittorrent-nox-static/docs_images/github_settings_actions_perms.png)
You can find these settings bu going to the repo settings/actions/general
![](/qbittorrent-nox-static/docs_images/github_settings_actions_options.png)
10 changes: 5 additions & 5 deletions docs/src/content/docs/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ hero:
file: /public/logo-static.svg
actions:
- text: Docs
link: /astro-starlight/introduction
link: /qbittorrent-nox-static/introduction
icon: right-arrow
variant: primary

Expand All @@ -33,7 +33,7 @@ import { Card, CardGrid } from '@astrojs/starlight/components';
<Card class="card-github" icon="github" title="Github Actions and Workflows" >

<div class="float-child card-image card-image-github">
<img class="card-image" style="height:100px; width:100px;" src="/astro-starlight/logo-github.svg" alt=""/>
<img class="card-image" style="height:100px; width:100px;" src="/qbittorrent-nox-static/logo-github.svg" alt=""/>
</div>

<div class="float-child card-text">
Expand All @@ -49,7 +49,7 @@ import { Card, CardGrid } from '@astrojs/starlight/components';
<Card class="card-musl" icon="rocket" title="Musl Libc and static linking" >

<div class="float-child card-image card-image-musl">
<img class="card-image" style="height:100px; width:100px;" src="/astro-starlight/logo-musl.svg" alt=""/>
<img class="card-image" style="height:100px; width:100px;" src="/qbittorrent-nox-static/logo-musl.svg" alt=""/>
</div>

<div class="float-child card-text">
Expand All @@ -65,7 +65,7 @@ import { Card, CardGrid } from '@astrojs/starlight/components';
<Card class="card-alpine" icon="star" title="Alpine Linux as a build host" >

<div class="float-child card-image card-image-alpine">
<img class="card-image" style="height:100px; width:100px;" src="/astro-starlight/logo-alpine.svg" alt=""/>
<img class="card-image" style="height:100px; width:100px;" src="/qbittorrent-nox-static/logo-alpine.svg" alt=""/>
</div>

<div class="float-child card-text">
Expand All @@ -81,7 +81,7 @@ import { Card, CardGrid } from '@astrojs/starlight/components';
<Card class="card-github" icon="approve-check" title="qBittorent-nox fully static binaries" >

<div class="float-child card-image card-image-github">
<img class="card-image" style="height:100px; width:100px;" src="/astro-starlight/logo-qbittorrent.svg" alt=""/>
<img class="card-image" style="height:100px; width:100px;" src="/qbittorrent-nox-static/logo-qbittorrent.svg" alt=""/>
</div>

<div class="float-child card-text">
Expand Down
112 changes: 56 additions & 56 deletions docs/src/content/docs/script-usage.mdx
Original file line number Diff line number Diff line change
@@ -1,56 +1,56 @@
---
title: Script Usage
hide_title: true
---

import { Advanced, Details, Modal, Tooltip, Charts, Important } from "/src/components/global.jsx"
import { Steps, Tabs, TabItem, Card, CardGrid, LinkCard, Aside, Icon } from '@astrojs/starlight/components';

:::tip[Just use docker]
The preferred and recommended build platform is Alpine Linux and the recommended method is via docker. It will just make things easier.
:::

:::caution[Assumptions]
The guide will assume you are using docker, with example commands that are either one liners or from within the container.
:::

:::danger
Don't run this directly on the host system unless you know what you are doing. It's not recommended and the build will probably fail.
:::


<Details summary="What to expect">![](/astro-starlight/docs_images/script_usage/first-run.png)</Details>

⭐ When you are familiar with the script you can do anything you want with a one liner. It's pretty simple to use.

### Host - execute script

To execute the script use this command:

```bash
chmod +x ~/qbt.sh # make it executable
```

```bash
~/qbt.sh
```

<Advanced>

:::note
Please see the [switches and flags summary](./build-help?id=switches-and-flags-summarised) to see what options you can pass and how to use them
:::

You can modify the installation command by editing this part of the docker command.

```bash
bash -s all
```

For example, to use `ICU` using `-i`, `-c` to trigger cmake and in turn activate Qt6 and optimise for the system CPU using `-o`:

```bash
bash -s all -i -c -o
```

</Advanced>
---
title: Script Usage
hide_title: true
---

import { Advanced, Details, Modal, Tooltip, Charts, Important } from "/src/components/global.jsx"
import { Steps, Tabs, TabItem, Card, CardGrid, LinkCard, Aside, Icon } from '@astrojs/starlight/components';

:::tip[Just use docker]
The preferred and recommended build platform is Alpine Linux and the recommended method is via docker. It will just make things easier.
:::

:::caution[Assumptions]
The guide will assume you are using docker, with example commands that are either one liners or from within the container.
:::

:::danger
Don't run this directly on the host system unless you know what you are doing. It's not recommended and the build will probably fail.
:::


<Details summary="What to expect">![](/qbittorrent-nox-static/docs_images/script_usage/first-run.png)</Details>

⭐ When you are familiar with the script you can do anything you want with a one liner. It's pretty simple to use.

### Host - execute script

To execute the script use this command:

```bash
chmod +x ~/qbt.sh # make it executable
```

```bash
~/qbt.sh
```

<Advanced>

:::note
Please see the [switches and flags summary](./build-help?id=switches-and-flags-summarised) to see what options you can pass and how to use them
:::

You can modify the installation command by editing this part of the docker command.

```bash
bash -s all
```

For example, to use `ICU` using `-i`, `-c` to trigger cmake and in turn activate Qt6 and optimise for the system CPU using `-o`:

```bash
bash -s all -i -c -o
```

</Advanced>

0 comments on commit 6f8c3dd

Please sign in to comment.