Skip to content

Commit 94b921a

Browse files
committed
fixup! ✨(backend) update make index command
Signed-off-by: charles <charles.englebert@protonmail.com>
1 parent aabed79 commit 94b921a

2 files changed

Lines changed: 3 additions & 15 deletions

File tree

Makefile

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -259,16 +259,8 @@ demo: ## flush db then create a demo for load testing purpose
259259
@$(MANAGE) create_demo
260260
.PHONY: demo
261261

262-
index: batch_size ?=
263-
index: lower_time_bound ?=
264-
index: upper_time_bound ?=
265-
index: crash_safe_mode ?=
266-
index: ## index all documents to indexer (params: batch_size, lower_time_bound, upper_time_bound, crash_safe_mode)
267-
@$(MANAGE) index \
268-
$(if $(batch_size),--batch-size $(batch_size)) \
269-
$(if $(lower_time_bound),--lower-time-bound "$(lower_time_bound)") \
270-
$(if $(upper_time_bound),--upper-time-bound "$(upper_time_bound)") \
271-
$(if $(crash_safe_mode),--crash-safe-mode)
262+
index: ## index all documents to remote search
263+
@$(MANAGE) index $(args)
272264
.PHONY: index
273265

274266
# Nota bene: Black should come after isort just in case they don't agree...

docs/commands/index.md

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,12 +31,8 @@ The command is available in the Django admin interface:
3131
make index
3232

3333
# With custom parameters
34-
make index batch_size=200 lower_time_bound="2024-01-01T00:00:00"
34+
make index args="--batch-size 100 --lower-time-bound 2024-01-01T00:00:00 --upper-time-bound 2026-01-01T00:00:00"
3535

36-
# All parameters
37-
make index batch_size=200 \
38-
lower_time_bound="2024-01-01T00:00:00" \
39-
upper_time_bound="2024-01-31T23:59:59" \
4036
```
4137

4238
## Parameters

0 commit comments

Comments
 (0)