<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Binary on 每日拍拍</title>
    <link>https://dailypypy.org/tags/binary/</link>
    <description>Recent content in Binary on 每日拍拍</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>zh-tw</language>
    <copyright>© 2026 每日拍拍</copyright>
    <lastBuildDate>Sat, 24 Oct 2026 12:03:00 +0800</lastBuildDate><atom:link href="https://dailypypy.org/tags/binary/index.xml" rel="self" type="application/rss+xml" />
    <follow_challenge>
      <feedId>155076163427069952</feedId>
      <userId>154825760438254592</userId>
    </follow_challenge>
    
    
    <item>
      <title>Git attributes 實戰：LF/CRLF、Binary 與可審核正規化</title>
      <link>https://dailypypy.org/learn/git-attributes-line-endings/</link>
      <pubDate>Sat, 24 Oct 2026 12:03:00 +0800</pubDate>
      
      <guid>https://dailypypy.org/learn/git-attributes-line-endings/</guid>
      <description>&lt;!---
1440x768
prompt: masterpiece, best quality, highres, clean anime illustration, japanese anime style, soft shading, flat color design, 1girl, black hair, green eyes, white off-shoulder shirt, black short skirt, full body from slightly above, sitting sideways on a simple stool with both hands resting naturally on her lap, cheerful open-eyed gentle smile, looking at viewer, pastel powder blue background, neat composition, detailed eyes, cute and smart vibe, minimal background, polished illustration, no text
negative prompt: worst quality, bad eye, bad hand, extra limbs, manga, multiple views, monochrome, text, signature
dedup note: Unlike ../git-rerere/ (reusing conflict resolutions, with only a conflict-marker-size attribute example), this article specifies path-level byte/EOL contracts and audits a tracked-file renormalization. ../git-partial-clone/ concerns object transport, while ../python-precommit/ concerns commit-time quality hooks. Neither covers index/worktree EOL diagnostics, binary preservation or checkout verification.
---&gt;

&lt;h2 class=&#34;relative group&#34;&gt;一. 前言：只改一行，怎麼整份檔案都紅了？ 
    &lt;div id=&#34;一-前言只改一行怎麼整份檔案都紅了&#34; class=&#34;anchor&#34;&gt;&lt;/div&gt;
    
    &lt;span
        class=&#34;absolute top-0 w-6 transition-opacity opacity-0 ltr:-left-6 rtl:-right-6 not-prose group-hover:opacity-100&#34;&gt;
        &lt;a class=&#34;group-hover:text-primary-300 dark:group-hover:text-neutral-700&#34;
            style=&#34;text-decoration-line: none !important;&#34; href=&#34;#%e4%b8%80-%e5%89%8d%e8%a8%80%e5%8f%aa%e6%94%b9%e4%b8%80%e8%a1%8c%e6%80%8e%e9%ba%bc%e6%95%b4%e4%bb%bd%e6%aa%94%e6%a1%88%e9%83%bd%e7%b4%85%e4%ba%86&#34; aria-label=&#34;定位點&#34;&gt;#&lt;/a&gt;
    &lt;/span&gt;        
    
&lt;/h2&gt;
&lt;p&gt;拍拍君最怕看到這種 PR：功能只動三行，diff 卻有三千行。
不是程式突然長大，而是編輯器把 LF 換成了 CRLF。
更麻煩的是，兩位同事各自設定 &lt;code&gt;core.autocrlf&lt;/code&gt;，同一份檔案在不同電腦上就有不同待遇。&lt;/p&gt;
&lt;p&gt;解法不是叫每個人手動背一套設定，而是把&lt;strong&gt;哪些路徑如何處理&lt;/strong&gt;寫進版本控制：&lt;code&gt;.gitattributes&lt;/code&gt;。
這篇不談漂亮的 formatter，也不重講 &lt;a href=&#34;../git-rerere/&#34;&gt;rerere 的衝突記憶&lt;/a&gt;。
我們要完成一個小型遷移：訂換行契約、保留 binary 原樣、稽核正規化，最後用新 clone 證明 checkout 結果。&lt;/p&gt;</description>
      <media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://dailypypy.org/learn/git-attributes-line-endings/featured.png" />
    </item>
    
    <item>
      <title>Python struct 實戰：二進位資料打包、解析與檔案格式入門</title>
      <link>https://dailypypy.org/learn/python-struct/</link>
      <pubDate>Fri, 25 Sep 2026 10:09:00 +0800</pubDate>
      
      <guid>https://dailypypy.org/learn/python-struct/</guid>
      <description>&lt;!---
1440x768
prompt: masterpiece, best quality, highres, clean anime illustration, japanese anime style, soft shading, flat color design, 1girl, black hair, green eyes, white off-shoulder shirt, black short skirt, slight dutch angle, full body, sitting on a simple stool with one hand on chin thinking, slight blush shy smile, looking at viewer, powder blue background, subtle floating blank translucent byte blocks arranged in neat rows without symbols, logos, markings, numbers, letters, or text, neat composition, detailed eyes, cute and smart vibe, minimal background, polished illustration, no text
negative prompt: worst quality, bad eye, bad hand, extra limbs, manga, multiple views, monochrome, text, signature
dedup note: 2026-09-25 planned-draft rescue. The nearest published post is ../python-socket/, which uses struct only for one four-byte TCP length prefix. ../python-mmap/ focuses on memory mapping and random access, while ../python-msgspec/ focuses on typed JSON and MessagePack schemas. This article instead teaches struct format strings, explicit byte order, fixed headers and records, offset parsing, bounded validation, and a versioned miniature file format.
---&gt;
&lt;p&gt;





&lt;figure&gt;
    &lt;img class=&#34;my-0 rounded-md&#34; loading=&#34;lazy&#34; alt=&#34;featured&#34; src=&#34;./featured.png&#34; /&gt;

  
&lt;/figure&gt;
&lt;/p&gt;</description>
      <media:content xmlns:media="http://search.yahoo.com/mrss/" url="https://dailypypy.org/learn/python-struct/featured.png" />
    </item>
    
  </channel>
</rss>
