# Crontab 1st Sunday of every Month

You can put something like this in the crontab file:

```bash
00 09 * * 7 [ $(date +\%d) -le 07 ] && /run/your/script
```

The date +%d gives you the number of the current day, and then you can check if the day is less than or equal to 7. If it is, run your command.

If you run this script only on Sundays, it should mean that it runs only on the first Sunday of the month.

Remember that in the crontab file, the formatting options for the date command should be escaped.

As bash script:

```bash
# for crontab use 0 8 * * 1 /path/to/script
if  [ $(date +\%d) -le 07]; then
	python spamcannon.py arg1 noattach
else
	echo "Timeframe passed"
fi
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.arkannis.net/os/linux/crontab/crontab-1st-sunday-of-every-month.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
