Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,7 @@ root = true
charset = utf-8
indent_style = space
indent_size = 2
spelling_language = en-US
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true

[*.md]
max_line_length = 120
20 changes: 0 additions & 20 deletions .github/workflows/lint.yml

This file was deleted.

28 changes: 12 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,39 +2,35 @@

Experimental / proof of concept page to replace the current documentation which is built with GitBook.

This documentation is built with [Hugo](https://gohugo.io) in conjunction with the [Doks theme](https://getdoks.org/) as
an experiment to see if it is a viable alternative.
This documentation is built with [Hugo](https://gohugo.io) in conjunction with the [Doks theme](https://getdoks.org/) as an experiment to see if it is a viable alternative.

## Contributing / Building

Install [Node.js](https://nodejs.org/en), clone this repository, install the dependencies with `npm install`, and run
`npm run dev` to start a local server. The server will automatically rebuild the page when you make changes.
Install [Node.js](https://nodejs.org/en), clone this repository, install the dependencies with `npm install`, and run `npm run dev` to start a local server.
The server will automatically rebuild the page when you make changes.

To build the page in release mode, use `HUGO_BASEURL=... npm run build`, then serve the generated `public/` directory
with your webserver of choice.
To build the page in release mode, use `HUGO_BASEURL=... npm run build`, then serve the generated `public/` directory with your webserver of choice.

For more information, please view our [Contributing Guidelines](.github/CONTRIBUTING.md).

### Editor Setup

As this project uses the [EditorConfig](https://editorconfig.org/) standard, you will have to make sure that your
editor supports it. Most modern editors do, but if you are unsure, check the EditorConfig page.
As this project uses the [EditorConfig](https://editorconfig.org/) standard, you will have to make sure that your editor supports it.
Most modern editors do, but if you are unsure, check the EditorConfig page.

### Authoring Content

Pages are written in Markdown with additional shortcodes provided by the Doks theme; refer to [its
documentation](<(https://getdoks.org/docs/start-here/getting-started/)>) for a complete list of features.
Pages are written in Markdown with additional shortcodes provided by the Doks theme; refer to [its documentation](<(https://getdoks.org/docs/start-here/getting-started/)>) for a complete list of features.

If you are editing pages related to custom commands, note that codeblocks support a custom `yag` language for accurate
syntax highlighting—do not use `go`. However, this feature is only enabled in production builds for performance, so
`npm run dev` will _not_ highlight `yag` codeblocks. Use `npm run build` followed by `npm run preview` instead if you
need to verify that code is highlighted correctly.
If you are editing pages related to custom commands, note that codeblocks support a custom `yag` language for accurate syntax highlighting—do not use `go`.
However, this feature is only enabled in production builds for performance, so `npm run dev` will _not_ highlight `yag` codeblocks.
Use `npm run build` followed by `npm run preview` instead if you need to verify that code is highlighted correctly.

> [!TIP]
> If you use VSCode, this project provides custom workspace snippets to insert callouts, which you can activate in
> Markdown files by typing <kbd>Ctrl</kbd> + <kbd>Space</kbd> followed by `note`, `tip`, `warning`, or `danger`.

## License

This documentation's text is distributed under the terms of the Creative Commons Attribution ShareAlike 4.0 license
(SPDX-indentifer `CC-BY-SA`). Please view the [LICENSE](LICENSE) file for more information.
This documentation's text is distributed under the terms of the Creative Commons Attribution ShareAlike 4.0 license (SPDX-indentifer `CC-BY-SA`).
Please view the [LICENSE](LICENSE) file for more information.
96 changes: 0 additions & 96 deletions config/.markdownlint.yaml

This file was deleted.

80 changes: 41 additions & 39 deletions content/docs/core/command-settings.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,28 +8,33 @@ Fine-grained control over all of YAGPDB's inbuild commands.

## Overview

Command overrides allow you to restrict access to YAGPDB's inbuilt commands and optionally configure intervals after
which the command trigger and response will be autodeleted. The key features of the page are as follows:

![Overview of the Command Settings page.](command_settings_overview.png)
Command overrides allow you to restrict access to YAGPDB's inbuilt commands and optionally configure intervals after which the command trigger and response will be autodeleted.
The key features of the page are shown below.

<center>

**1** Command prefix, default `-` **2** _All commands enabled_ setting **3** Required roles **4** Ignored roles
**5** Autodelete trigger interval **6** Autodelete response interval **7** Command overrides **8** Channel overrides tabs
**1** Command prefix.
**2** All commands enabled setting.
**3** Required roles.
**4** Ignored roles.
**5** Autodelete trigger interval.
**6** Autodelete response interval.
**7** Command overrides.
**8** Channel overrides tabs.
Comment on lines -18 to +23
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FWIW, this is what rumdl struggles with, it considers this entire section a single sentence, so even with this formatting as it is right now, it complains that a single sentence spans 11 lines.

This should probably be using the figure shortcode anyway, but even that templating is currently not recognised by rumdl :^)


</center>

The prefix (**1**) is a short sequence of characters that trigger YAGPDB commands. By default, the prefix is `-`. Thus,
for instance, the `remindme` command is invoked by prefixing the command name with a hyphen: `-remindme ...`. If the
prefix was instead `?`, one would use `?remindme ...`, and so on.
The prefix (**1**) is a short sequence of characters that trigger YAGPDB commands.
By default, the prefix is `-`.
Thus, for instance, the `remindme` command is invoked by prefixing the command name with a hyphen: `-remindme ...`.
If the prefix was instead `?`, one would use `?remindme ...`, and so on.

Slash commands are always triggered using the `/` character and hence do not depend on the prefix configured here.

{{< callout context="tip" title="Tip: Mention as a Command Prefix" icon="outline/rocket" >}}

In addition to the command prefix, you can trigger YAGPDB commands by pinging the bot at the start of your message. This
is helpful if you forget your prefix, as sending `@YAGPDB.xyz prefix` will recall it.
In addition to the command prefix, you can trigger YAGPDB commands by pinging the bot at the start of your message.
This is helpful if you forget your prefix, as sending `@YAGPDB.xyz prefix` will recall it.

{{< /callout >}}

Expand All @@ -56,56 +61,54 @@ Command overrides are considered in the following order, with settings applied a
restrictions.
3. Channel-specific restrictions (_Override #1_, _Override #2_, ...) are applied analogously.

The order above trickles down from least specific to most specific, prioritizing the most specific setting---an analogy
for developers would be CSS's cascading rules.
The order above trickles down from least specific to most specific, prioritizing the most specific setting---an analogy for developers would be CSS's cascading rules.

Though perhaps confusing at first, the priority order above is designed to make common configurations trivial. For
instance, to disable all but a specific command---say the `remindme` command---one can simply disable the _All
commands enabled_ option and then create a command override that enables only `remindme`. This is possible as command
overrides are applied after the _All commands enabled_ setting.
Though perhaps confusing at first, the priority order above is designed to make common configurations trivial.
For instance, to disable all but a specific command---say the `remindme` command---one can simply disable the _All commands enabled_ option and then create a command override that enables only `remindme`.
This is possible as command overrides are applied after the _All commands enabled_ setting.

## Options

### Common Options

These options are common across all three sub-settings: global settings, channel overrides, and individual command
overrides.
These options are common across all three sub-settings: global settings, channel overrides, and individual command overrides.

#### Required and Ignored Roles

Clicking on either of these options (**3**,**4**) opens a drop-down menu with all the roles present on your server.
Select as many as you wish. YAGPDB will then either require all members to have any of these roles in order to run
commands, or completely ignore members with any of the ignored roles, server admins and owners included.
Clicking on either of these options (**3**, **4**) opens a drop-down menu with all the roles present on your server.
Select as many as you wish.
YAGPDB will then either require all members to have any of these roles in order to run commands, or completely ignore members with any of the ignored roles, server admins and owners included.

{{< callout context="note" title="Note: Priority of Ignored vs. Required Roles" icon="outline/info-circle" >}}

YAGPDB was raised well and honors a "no" when told "no". In other words, ignored roles take precedence over required
roles.
YAGPDB was raised well and honors a "no" when told "no".
In other words, ignored roles take precedence over required roles.

{{< /callout >}}

#### Autodelete Trigger / Response Interval

This setting makes YAGPDB automatically delete the triggering message and/or its response after the configured duration
has passed. To activate it, make sure to click the checkbox next to the respective input field (**5**,**6**).
This setting makes YAGPDB automatically delete the triggering message and/or its response after the configured duration has passed.
To activate it, make sure to click the checkbox next to the respective input field (**5**, **6**).

If 10 seconds are not enough, or too long, feel free to adjust as you see fit; the intervals need not be equal.

#### Slash command response always ephemeral

Toggling this setting on will make YAGPDB always respond to slash commands with an ephemeral message. This means that
only the user who triggered the command will be able to see the response.
Toggling this setting on will make YAGPDB always respond to slash commands with an ephemeral message.
This means that only the user who triggered the command will be able to see the response.

### Channel Override Options

These options are only available for channel overrides (**8**). To add a new one, head to the _New channel override_
tab on the command settings page.
These options are only available for channel overrides (**8**).
To add a new one, head to the _New channel override_ tab on the command settings page.

You must select at least one channel or category; otherwise, the settings of the override will not be applied.

#### Channels

With this setting, you can select individual channels to apply the override to. Select as many as you wish.
With this setting, you can select individual channels to apply the override to.
Select as many as you wish.

You find this setting in the top-left corner of any channel override.

Expand All @@ -117,17 +120,16 @@ You find this setting in the top-right corner of any channel override, adjacent

### Command Override Options

These options are only available for individual command overrides (**7**). To add a new one, go to either your
global settings or any channel override and click on _New command override_.
These options are only available for individual command overrides (**7**).
To add a new one, go to either your global settings or any channel override and click on _New command override_.

#### Commands

This setting allows you to select specific commands to apply the command override to. Select as many as you wish to
apply an override to. You cannot have two (or more) overrides for the same command in the same tab, i.e. global settings
or a specific channel override.
This setting allows you to select specific commands to apply the command override to.
Select as many as you wish to apply an override to.
You cannot have two (or more) overrides for the same command in the same tab, i.e. global settings or a specific channel override.

#### Enable Specified Commands

Toggling this option simply tells YAGPDB whether the commands you selected are enabled or disabled. This allows you to
disable some specific commands, which may be useful if -- for example -- you have created a custom command that
completely replaces an inbuilt one.
Toggling this option simply tells YAGPDB whether the commands you selected are enabled or disabled.
This allows you to disable some specific commands, which may be useful if -- for example -- you have created a custom command that completely replaces an inbuilt one.
23 changes: 12 additions & 11 deletions content/docs/core/control-panel-access.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,30 +4,31 @@ weight = 210
description = "Select who can view or edit your control panel."
+++

This page is relatively simple, yet very powerful. An overview of the settings follows.
This page is relatively simple, yet very powerful.
An overview of the settings follows.

![Overview of the control panel access configuration page.](control_panel_access.png)

### Read Access

#### Allow people with the following roles

The very top option is to allow people with certain roles read access to the control panel. Simply open the drop-down
select menu and select the roles you wish to grant read access.
The very top option is to allow people with certain roles read access to the control panel.
Simply open the drop-down select menu and select the roles you wish to grant read access.

#### Allow all members read access

This switch is fairly straight forward, when enabled any and all members of your server are granted read access. For
reference, this is enabled on the support server, but it may be a good idea to keep it disabled.
This switch is fairly straight forward, when enabled any and all members of your server are granted read access.
For reference, this is enabled on the support server, but it may be a good idea to keep it disabled.

#### Allow users not part of your server read access

Taking the above one step further, this toggle lets any and all users, even not logged in ones, to view your control
panel. In general, it is a very good idea to have this disabled, unless you have good reasons not to. For the record,
this option is enabled on the support server's control panel.
Taking the above one step further, this toggle lets any and all users, even not logged in ones, to view your control panel.
In general, it is a very good idea to have this disabled, unless you have good reasons not to.
For the record, this option is enabled on the support server's control panel.

### Write Access

Quite simple, but moderately dangerous. Anyone with these roles can edit anything on your control panel, so do handle
this with care. To make things easier to configure, members with **Manage Server** permissions can always edit the
control panel.
Quite simple, but moderately dangerous.
Anyone with these roles can edit anything on your control panel, so do handle this with care.
To make things easier to configure, members with **Manage Server** permissions can always edit the control panel.
8 changes: 3 additions & 5 deletions content/docs/core/control-panel-logs.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,9 @@ weight = 220
description = "View a list of recent changes to your YAGPDB configuration."
+++

This page is the analogue of the audit log built in to Discord for YAGPDB settings and summarizes recent edits on the
control panel, listing the time, action, and responsible user for each. It is useful to audit who may be responsible if
things go haywire, but other than that this page is unlikely to be of use.
This page is the analogue of the audit log built in to Discord for YAGPDB settings and summarizes recent edits on the control panel, listing the time, action, and responsible user for each.
It is useful to audit who may be responsible if things go haywire, but other than that this page is unlikely to be of use.

Please do not be confused if you see changes from the user `destroy_0001` (ID `598900258579283976`), as that is the bot
developer and he may at times need to change certain settings to ensure proper operation.
Please do not be confused if you see changes from the user `destroy_0001` (ID `598900258579283976`), as that is the bot developer and he may at times need to change certain settings to ensure proper operation.

![Screenshot of some example control panel logs.](control_panel_logs.png)
Loading