blob: 5ba11c9fc008e1cb88fd1b7ca52cd42e3bdac996 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
|
# Copyright (C) 2024-2026 Maria Lisina
# Copyright (C) 2024-2026 Danil Lisin
# SPDX-License-Identifier: Apache-2.0
if [[ -n "${1}" ]]
then
ib_board="${1}"
source "${units}/ib_config.zsh"
if [[ -z "${ib_data_url}" ]]
then
output_title="Invalid arguments"
output_text="Unsupported Image Board"
return
fi
shift
else
output_title="Invalid arguments"
output_text="You must specify Image Board"
return
fi
if test "${1}" -gt 0
then
inline_page=${1}
shift
else
inline_page=1
set -- -a ${@}
fi
if [[ -n "${offset}" ]]
then
inline_page=${offset}
fi
if [[ -n "${1}" ]]
then
search_query="${@}"
if ! zparseopts -D -F -K -- \
a=ib_autopaging \
m=ib_metadata \
p=ib_preview \
q=ib_quick
then
output_title="Invalid arguments"
output_text="Unsupported options"
return
fi
fi
if [[ -n "${1}" ]]
then
ib_query="${@}"
shift ${#}
fi
ib_limit=${inline_limit}
ib_page=${inline_page}
|