DIVE_VERSION does not need to be exported (#492)

The value of the variable DIVE_VERSION is not needed in a
spawned subprocess. Thus, the variable does not necessarily
need to be exported. Arguably, the environment is less
polluted if it is not exported.
This commit is contained in:
Rene Nyffenegger 2024-02-02 15:26:54 +01:00 committed by GitHub
parent 2d86aa7b4c
commit 7556be352a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -97,7 +97,7 @@ With valid `source` options as such:
Using debs:
```bash
export DIVE_VERSION=$(curl -sL "https://api.github.com/repos/wagoodman/dive/releases/latest" | grep '"tag_name":' | sed -E 's/.*"v([^"]+)".*/\1/')
DIVE_VERSION=$(curl -sL "https://api.github.com/repos/wagoodman/dive/releases/latest" | grep '"tag_name":' | sed -E 's/.*"v([^"]+)".*/\1/')
curl -OL https://github.com/wagoodman/dive/releases/download/v${DIVE_VERSION}/dive_${DIVE_VERSION}_linux_amd64.deb
sudo apt install ./dive_${DIVE_VERSION}_linux_amd64.deb
```
@ -112,7 +112,7 @@ sudo snap connect dive:docker-daemon docker:docker-daemon
**RHEL/Centos**
```bash
export DIVE_VERSION=$(curl -sL "https://api.github.com/repos/wagoodman/dive/releases/latest" | grep '"tag_name":' | sed -E 's/.*"v([^"]+)".*/\1/')
DIVE_VERSION=$(curl -sL "https://api.github.com/repos/wagoodman/dive/releases/latest" | grep '"tag_name":' | sed -E 's/.*"v([^"]+)".*/\1/')
curl -OL https://github.com/wagoodman/dive/releases/download/v${DIVE_VERSION}/dive_${DIVE_VERSION}_linux_amd64.rpm
rpm -i dive_${DIVE_VERSION}_linux_amd64.rpm
```