tibodog 0.1.3 → 0.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -54,16 +54,21 @@ Any RSS/Atom feed of the account works: a Nitter instance, self-hosted [RSSHub](
54
54
  (`/twitter/user/thsottiaux`), rss.app, and so on.
55
55
 
56
56
  ```bash
57
- npx tibodog --rss "https://your-rsshub.example.com/twitter/user/thsottiaux"
57
+ npx tibodog --rss "https://nitter.kareem.one/thsottiaux/rss"
58
58
  ```
59
59
 
60
+ That Nitter instance served Tibo's feed when this was written (Oct 2026); most public ones are blocked or
61
+ gone (nitter.net, xcancel.com, rsshub.app all refused). Mirrors come and go, so if it stops working, find
62
+ another or self-host RSSHub. They're run by volunteers: keep the default 5-minute interval.
63
+ tibodog only ever opens the post on x.com, never the mirror's own links.
64
+
60
65
  ## 옵션 / Options
61
66
 
62
67
  | flag | default | |
63
68
  |---|---|---|
64
69
  | `--user <handle>` | `thsottiaux` | 감시할 계정 / account to watch |
65
70
  | `--rss <url>` | | use an RSS feed instead of the X API |
66
- | `--interval <sec>` | 60 (RSS) / 300 (X) | poll interval |
71
+ | `--interval <sec>` | 300 | poll interval (min 15) |
67
72
  | `--keyword <text>` | | extra trigger phrase, repeatable |
68
73
  | `--barks <n>` | 1 | 짖는 소리 반복 횟수 / times to play the bark |
69
74
  | `--sound <file.wav\|synth>` | real recording | bring your own dog, or `synth` for the synthesized bark |
package/bin/tibodog.js CHANGED
@@ -154,7 +154,8 @@ try {
154
154
  }
155
155
 
156
156
  // Between 15 seconds and a day: anything else would hammer the feed or overflow setTimeout.
157
- const seconds = Number(opt.interval) || (opt.rss ? 60 : 300);
157
+ // RSS mirrors are mostly volunteer-run and refresh every few minutes at best: 5 minutes is plenty.
158
+ const seconds = Number(opt.interval) || 300;
158
159
  const intervalMs = Math.min(Math.max(seconds, 15), 86_400) * 1000;
159
160
  let primed = !firstRun || opt['bark-old'];
160
161
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tibodog",
3
- "version": "0.1.3",
3
+ "version": "0.1.4",
4
4
  "description": "A notch widget (Claude Code/Codex usage, Now Playing) with a dog that barks when Tibo (@thsottiaux) resets the Codex limits on X",
5
5
  "type": "module",
6
6
  "bin": {
package/src/detect.js CHANGED
@@ -3,7 +3,7 @@
3
3
  const RESET = /\b(re-?set(s|ting)?|refresh(ed|ing)?|wiped)\b|리셋|초기화/i;
4
4
  const CONTEXT = /\b(limits?|usage|rate|quotas?|codex|plans?|weekly|5h|allowance)\b|사용량|한도/i;
5
5
  // How Tibo announces a reset on its own, with no "limits" in the post ("Day 21/ ... But today is a reset.").
6
- const DECLARED = /\b(today is a reset|reset day|and reset|(have|has|been|just) reset)\b/i;
6
+ const DECLARED = /\b((is|that'?s|that’s) a reset|reset day|and reset|(have|has|been|just) reset)\b/i;
7
7
  // Cheap guard against obvious non-announcements ("password reset", "factory reset").
8
8
  const NOISE = /\b(password|factory|hard reset|git reset)\b/i;
9
9
 
package/src/i18n.js CHANGED
@@ -30,7 +30,7 @@ Sources (pick one):
30
30
 
31
31
  Options:
32
32
  --user <handle> account to watch (default: thsottiaux)
33
- --interval <sec> poll interval (default: 60 for RSS, 300 for X API)
33
+ --interval <sec> poll interval (default: 300)
34
34
  --keyword <text> extra trigger phrase, repeatable
35
35
  --barks <n> times to play the bark per alert (default: 1)
36
36
  --sound <file.wav|synth> your own dog, or 'synth' for the synthesized bark
@@ -73,7 +73,7 @@ Options:
73
73
 
74
74
  옵션:
75
75
  --user <handle> 감시할 계정 (기본: thsottiaux)
76
- --interval <초> 확인 주기 (기본: RSS 60초, X API 300초)
76
+ --interval <초> 확인 주기 (기본: 300초)
77
77
  --keyword <텍스트> 추가 트리거 문구, 여러 번 지정 가능
78
78
  --barks <n> 알림당 짖는 소리 반복 횟수 (기본: 1)
79
79
  --sound <file.wav|synth> 내 개 소리 파일, 또는 synth로 합성 소리 사용
package/src/sources.js CHANGED
@@ -128,7 +128,8 @@ const entities = (s) =>
128
128
  const decode = (s) => clean(stripTags(entities(stripTags(unwrapCdata(s))))).replace(/\s+/g, ' ').trim();
129
129
 
130
130
  // The first <name ...>...</name> (or a self-closing <name .../>) in xml.
131
- function element(xml, name) {
131
+ function element(xml, tagName) {
132
+ const name = tagName.toLowerCase(); // pubDate, ...
132
133
  const lower = xml.toLowerCase();
133
134
  let i = 0;
134
135
  while ((i = lower.indexOf(`<${name}`, i)) !== -1) {