Skip to content

Commit

Permalink
chore: clean up formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
mehalter committed Nov 21, 2023
1 parent 01bb686 commit d69dc76
Show file tree
Hide file tree
Showing 7 changed files with 21 additions and 14 deletions.
4 changes: 2 additions & 2 deletions src/content/docs/configuration/custom_plugins.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,11 +65,11 @@ return {

Many of our core plugins have additional code that runs during setup which you might want to extend. For this reason we have included our own modules in `require("astronvim.plugins.configs.X")` (replacing `X` with the plugin `require` string) that returns the AstroNvim default config function in each plugin specification that has a `config` function which can be easily called if you want to extend a plugin configuration. This is particularly useful if you want to do something like add rules to `nvim-autopairs`, add user snippets to `luasnip`, or add more extensions to `telescope` without having to rewrite our entire configuration function. Here is an example of adding the `media_files` Telescope extension:

::::note
:::note

Not all plugins have custom `config` functions and will not have an `astronvim.plugins.configs.X` module. The Lua language server provides autocompletion that is useful for identifying which plugins have a core `config` function.

::::
:::

```lua title="lua/plugins/extended_config.lua" {10-11}
return {
Expand Down
4 changes: 2 additions & 2 deletions src/content/docs/configuration/lua_completion.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ return {
}
```

::::tip
:::tip

AstroLSP allows for language server configuration completion by utilizing types exposed by the `nvim-lspconfig` plugin. One downside is the type does complain that "fields are missing" even though they are not actually required. To work around this, it can be useful and less noisy if you add

Expand All @@ -50,7 +50,7 @@ return {
}
```

::::
:::

### `opts` Function

Expand Down
4 changes: 2 additions & 2 deletions src/content/docs/configuration/v4_migration.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ id: v4_migration
title: Migration to v4.0
---

::::danger
:::danger

Currently this is the old v3 migration guide, this should be updated to migrating to v4

::::
:::

MAKE SURE TO ADD A DESCRIPTION BEFORE THE FIRST HEADER

Expand Down
13 changes: 10 additions & 3 deletions src/content/docs/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ tableOfContents:
maxHeadingLevel: 2
---

import { Tabs, TabItem } from '@astrojs/starlight/components';
import { Tabs, TabItem } from "@astrojs/starlight/components";

:::tip

Expand Down Expand Up @@ -35,13 +35,20 @@ AstroNvim is an aesthetic and feature-rich neovim config that is extensible and

:::note

<sup id="1">[1]</sup> All downloadable Nerd Fonts contain icons which are used by AstroNvim. Install the Nerd Font of your choice to your system and in your terminal emulator settings, set its font face to that Nerd Font. If you are using AstroNvim on a remote system via SSH, you do not need to install the font on the remote system.
<sup id="1">\[1\]</sup> All downloadable Nerd Fonts contain icons which are used
by AstroNvim. Install the Nerd Font of your choice to your system and in your terminal
emulator settings, set its font face to that Nerd Font. If you are using AstroNvim
on a remote system via SSH, you do not need to install the font on the remote system.

:::

:::note

<sup id="2">[2]</sup> When using default theme: For MacOS, the default terminal does not have true color support. You will need to use <a href="https://iterm2.com/">iTerm2</a>, <a href="https://sw.kovidgoyal.net/kitty/">Kitty</a>, <a href="https://wezfurlong.org/wezterm/">WezTerm</a>, or another <a href="https://github.com/termstandard/colors">terminal emulator</a> that has true color support.
<sup id="2">\[2\]</sup> When using default theme: For MacOS, the default terminal
does not have true color support. You will need to use [iTerm2](https://iterm2.com/),
[Kitty](https://sw.kovidgoyal.net/kitty/), [WezTerm](https://wezfurlong.org/wezterm/),
or another [terminal emulator](https://github.com/termstandard/colors) that has true
color support.

:::

Expand Down
2 changes: 1 addition & 1 deletion src/content/docs/recipes/colorscheme.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ There are only 2 simple steps to change colorscheme of your editor:

### Step 1 - Adding a plugin

You can either add a colorscheme plugin directly to your `plugins` as described in the [Custom Plugins Page](../../configuration/custom_plugins), for example if you wanted to add [Catppuccin](https://github.com/catppuccin/nvim) you would add the following to your `plugins`:
You can either add a colorscheme plugin directly to your `plugins` as described in the [Custom Plugins Page](/configuration/custom_plugins), for example if you wanted to add [Catppuccin](https://github.com/catppuccin/nvim) you would add the following to your `plugins`:

```lua title="lua/plugins/catppuccin.lua"
return {
Expand Down
4 changes: 2 additions & 2 deletions src/content/docs/recipes/detached_git_worktrees.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ return {
}
```

::::note
:::note

This mirrors a similar configuration option in gitsigns (https://github.com/lewis6991/gitsigns.nvim/pull/600).

::::
:::
4 changes: 2 additions & 2 deletions src/content/docs/using_the_docs.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ return {

Consolidating plugin specifications can help make your configuration more manageable in some ways while having things more separated can make it easier to enable/disable features and play around with things. It is fully up to you to decide which methods fit your needs.

::::caution
:::caution

Some plugin specifications may require more or less knowledge of the Lua programming language to effectively consolidate. Some recipes use a function notation to get more control over the `opts` table rather than simply specifying a list. It will take some Lua knowledge and programming skills to correctly consolidate these two formats together. Or you can just keep the snippets in separate files and they will all be applied in an isolated manner.

::::
:::

0 comments on commit d69dc76

Please sign in to comment.