Skip to content

Commit c5d05f3

Browse files
authored
Add documentation for default index URI variable (#669)
* Add documentation for default index URI variable * Code review changes
1 parent 1bfd342 commit c5d05f3

File tree

2 files changed

+26
-2
lines changed

2 files changed

+26
-2
lines changed
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
---
2+
title: Advanced Configuration
3+
slug: advanced-configuration
4+
weight: 900
5+
---
6+
7+
### Use a different default index
8+
9+
When Krew is installed, it automatically initializes an index named `default`
10+
pointing to the [krew-index][ki] repository. You can force Krew to use a
11+
different repository by setting `KREW_DEFAULT_INDEX_URI` before running the
12+
[installation instructions]({{<ref "setup/install.md">}}) or after [removing the
13+
default index]({{<ref "using-custom-indexes.md#the-default-index">}}).
14+
`KREW_DEFAULT_INDEX_URI` should point to a git repository URI that uses a valid
15+
git remote protocol.
16+
17+
To use a different default index, set the `KREW_DEFAULT_INDEX_URI` environment
18+
variable in your `~/.bashrc`, `~/.bash_profile`, or `~/.zshrc`:
19+
20+
```shell
21+
export KREW_DEFAULT_INDEX_URI='[email protected]:foo/custom-index.git'
22+
```
23+
24+
[ki]: https://github.com/kubernetes-sigs/krew-index

site/content/docs/user-guide/setup/updates.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ upgrade to a newer version.
1010
This is done by calling the GitHub API, and we do not collect any data from your
1111
machine during this process.
1212

13-
If you want to disable the update checks, set, the `KREW_NO_UPGRADE_CHECK`
13+
If you want to disable the update checks, set the `KREW_NO_UPGRADE_CHECK`
1414
environment variable. To permanently disable this, add the following to your
1515
`~/.bashrc`, `~/.bash_profile`, or `~/.zshrc`:
1616

17-
```text
17+
```shell
1818
export KREW_NO_UPGRADE_CHECK=1
1919
```

0 commit comments

Comments
 (0)