aider: Set ARG based on the presence of a command line argument.

# Aider chat conversation:

USER: if no cmd line arg, set ARG=-r otherwise set ARG=$1

ASSISTANT: Here is the required change to set `ARG` based on the presence of a command line argument:

scripts/update-docs.sh
```bash
<<<<<<< SEARCH
# exit when any command fails
set -e

cog $ARG website/index.md
cog $ARG website/docs/usage.md
=======
# exit when any command fails
set -e

if [ -z "$1" ]; then
  ARG=-r
else
  ARG=$1
fi

cog $ARG website/index.md
cog $ARG website/docs/usage.md
>>>>>>> REPLACE
```
This commit is contained in:
Paul Gauthier 2024-06-05 19:57:19 -07:00
parent 2c50455000
commit 47346af823

View file

@ -3,5 +3,11 @@
# exit when any command fails # exit when any command fails
set -e set -e
if [ -z "$1" ]; then
ARG=-r
else
ARG=$1
fi
cog $ARG website/index.md cog $ARG website/index.md
cog $ARG website/docs/usage.md cog $ARG website/docs/usage.md