streamdown 0.35.2__py3-none-any.whl → 0.35.4__py3-none-any.whl

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.
streamdown/sd.py CHANGED
@@ -1039,7 +1039,10 @@ def parse(stream):
1039
1039
 
1040
1040
  def terminal_prep(what):
1041
1041
  if Style.Plaintext:
1042
- return strip_ansi(what)
1042
+ line = "\n".join([x.rstrip() for x in strip_ansi(what).split("\n")])
1043
+ if len(line.strip()) == 0:
1044
+ return ""
1045
+ return line
1043
1046
  return what
1044
1047
 
1045
1048
  def emit(inp):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: streamdown
3
- Version: 0.35.2
3
+ Version: 0.35.4
4
4
  Summary: A streaming markdown renderer for modern terminals with syntax highlighting
5
5
  Project-URL: Homepage, https://github.com/day50-dev/Streamdown
6
6
  Project-URL: Bug Tracker, https://github.com/day50-dev/Streamdown/issues
@@ -168,7 +168,8 @@ To override the margin.
168
168
 
169
169
  ```shell
170
170
  usage: sd [-h] [-l LOGLEVEL] [-b BASE] [-c CONFIG] [-w WIDTH] [-e EXEC]
171
- [-s SCRAPE] [filenameList ...]
171
+ [-p PROMPT] [-s SCRAPE] [-v] [--strip]
172
+ [filenameList ...]
172
173
 
173
174
  Streamdown is a streaming markdown renderer for modern terminals.
174
175
  https://github.com/day50-dev/Streamdown
@@ -180,21 +181,18 @@ paths:
180
181
  positional arguments:
181
182
  filenameList Input file to process (also takes stdin)
182
183
 
183
- optional arguments:
184
+ options:
184
185
  -h, --help show this help message and exit
185
- -l LOGLEVEL, --loglevel LOGLEVEL
186
+ -l, --loglevel LOGLEVEL
186
187
  Set the logging level
187
- -b BASE, --base BASE Set the hsv base: h,s,v
188
- -c CONFIG, --config CONFIG
189
- Use a custom config override
190
- -w WIDTH, --width WIDTH
191
- Set the width WIDTH
192
- -e EXEC, --exec EXEC Wrap a program EXEC for more 'proper' i/o handling
193
- -p PROMPT, --prompt PROMPT
194
- A PCRE regex prompt to detect (default: ^.*>\s+$)
195
- -s SCRAPE, --scrape SCRAPE
196
- Scrape code snippets to a directory SCRAPE
188
+ -b, --base BASE Set the hsv base: h,s,v
189
+ -c, --config CONFIG Use a custom config override
190
+ -w, --width WIDTH Set the width WIDTH
191
+ -e, --exec EXEC Wrap a program EXEC for more 'proper' i/o handling
192
+ -p, --prompt PROMPT A PCRE regex prompt to detect (default: ^.*>\s+$)
193
+ -s, --scrape SCRAPE Scrape code snippets to a directory SCRAPE
197
194
  -v, --version Show version information
195
+ --strip Just strip the markdown and output plaintext
198
196
  ```
199
197
 
200
198
  **Note**: Some features are not supported on some OSs. Please file a ticket if you need a feature on your platform that isn't working.
@@ -1,13 +1,13 @@
1
1
  streamdown/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
2
  streamdown/qwen3.md,sha256=1e7ELkK-quwUeOmBDwXodFH-DlnfAcQWj32rjK6Zex4,542
3
- streamdown/sd.py,sha256=RZgvIaKdNIcXaR7rGjwdvgRCogtPUXjwb7l30DYrgFE,46619
3
+ streamdown/sd.py,sha256=OTbgpr09WnkcLS_oKTkrUEW-cdt3-bzpcIFDS32J08c,46739
4
4
  streamdown/ss,sha256=sel_phpaecrw6WGIHRLROsD7BFShf0rSDHheflwdUn8,277
5
5
  streamdown/ss1,sha256=CUVf86_2zeAle2oQCeTfWYqtHBrAFR_UgvptuYMQzFU,3151
6
6
  streamdown/test.txt,sha256=j0NDRmSPa5bfid2pAcUXaxCm2Dlh3TwayItZstwyeqQ,2
7
7
  streamdown/plugins/README.md,sha256=KWqYELs9WkKJmuDzYv3cvPlZMkArsNCBUe4XDoTLjLA,1143
8
8
  streamdown/plugins/latex.py,sha256=xZMGMdx_Sw4X1piZejXFHfEG9qazU4fGeceiMI0h13Y,648
9
- streamdown-0.35.2.dist-info/METADATA,sha256=zu0sqFknJBYM-KwPuY_pt37VecnD2dz5Bje_qwE0Mog,10494
10
- streamdown-0.35.2.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
11
- streamdown-0.35.2.dist-info/entry_points.txt,sha256=HroKFsFMGf_h9PRTE96NjvjJQWupMW5TGP5RGUr1O_Q,74
12
- streamdown-0.35.2.dist-info/licenses/LICENSE.MIT,sha256=SnY46EPirUsF20dZDR8HpyVgS2_4Tjxuc6f-4OdqO7U,1070
13
- streamdown-0.35.2.dist-info/RECORD,,
9
+ streamdown-0.35.4.dist-info/METADATA,sha256=_U2yu4ZauEkmFDlTGhm9Ciwwo87jHmcnR9YDrlXOIws,10467
10
+ streamdown-0.35.4.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
11
+ streamdown-0.35.4.dist-info/entry_points.txt,sha256=HroKFsFMGf_h9PRTE96NjvjJQWupMW5TGP5RGUr1O_Q,74
12
+ streamdown-0.35.4.dist-info/licenses/LICENSE.MIT,sha256=SnY46EPirUsF20dZDR8HpyVgS2_4Tjxuc6f-4OdqO7U,1070
13
+ streamdown-0.35.4.dist-info/RECORD,,