feat: follow upstream twtxt post rules: reject control characters, allow U+2028, make the length cap configurable
This commit is contained in:
parent
dd6865782a
commit
801c66d3b0
12 changed files with 63 additions and 58 deletions
|
|
@ -148,6 +148,7 @@
|
|||
data = ${cfg.dataDir}
|
||||
posts_per_day = ${toString cfg.postsPerDay}
|
||||
reposts_per_day = ${toString cfg.repostsPerDay}
|
||||
max_post_chars = ${toString cfg.maxPostChars}
|
||||
cap_bytes = ${toString cfg.capBytes}
|
||||
poll_secs = ${toString cfg.pollSecs}
|
||||
timeout = ${toString cfg.timeout}
|
||||
|
|
@ -254,6 +255,12 @@
|
|||
description = "Per-feed daily repost quota.";
|
||||
};
|
||||
|
||||
maxPostChars = mkOption {
|
||||
type = types.ints.positive;
|
||||
default = 288;
|
||||
description = "Longest post or repost text, in Unicode code points.";
|
||||
};
|
||||
|
||||
capBytes = mkOption {
|
||||
type = types.ints.positive;
|
||||
default = 1048576;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue