zlib、gzip 與 zip 的關係 (Mark Adler 的回覆)

Hacker News 上看到「How are zlib, gzip and zip related? (stackoverflow.com)」這個討論,原文是 StackOverflow 上 2013 年時的問題與回答:「How are zlib, gzip and zip related? What do they have in common and how are they different?」。

short form 算是解釋了這三個的關係,另外多帶出了其他相關的格式以及演算法:

.zip is an archive format using, usually, the Deflate compression method. The .gz gzip format is for single files, also using the Deflate compression method. Often gzip is used in combination with tar to make a compressed archive format, .tar.gz. The zlib library provides Deflate compression and decompression code for use by zip, gzip, png (which uses the zlib wrapper on deflate data), and many other applications.

而 long form 則是描述了整段歷史,完整到下面的 comment 有人提到希望能夠提供一些引用的連結,當作 reference:

This post is packed with so much history and information that I feel like some citations need be added incase people try to reference this post as an information source. Though if this information is reflected somewhere with citations like Wikipedia, a link to such similar cited work would be appreciated.

回答的作者 Mark Adler 也在 comment 上很霸氣的回:

I am the reference, having been part of all of that. This post could be cited in Wikipedia as an original source.

翻了一下他的事蹟:

老人家交代了當年的一些脈絡 (像是專利問題),會更容易理解為什麼現在發展成這樣...

Facebook 5.33 億筆個資外洩,以及 Mark Zuckerberg 的電話...

這兩天應該已經有很多其他媒體報導了 Facebook 5.33 億筆資料外洩的事情:「533 million Facebook users' phone numbers and personal data have been leaked online」。

據稱是用 2019 年的洞撈出來的,不過這份資料看起來也不是完整資料,舉個例子來說,台灣只有 73 萬筆左右,而且也少了很多地區,像是泰國就不在列表內...

另外一個比較特別的是,Mark Zuckerberg 的電話也在這次外洩資料裡面:「Mark Zuckerberg's phone number appeared among the leaked data of Facebook users, according to a researcher」,應該會換號碼了。

這包資料看起來會這陣子會很熱門...

拔掉 Medium 網站出現的 Hash Mark

Medium 會在網址上串上 Fragment identifier (就是井號 # 後面那一串),而這件事情一直頗讓人惱怒...

網路上查到的幾個解法都是針對 medium.com 再做一次 replaceState() 把 hash mark 拔掉,但這對於使用自訂網址而且 hosting 在 Medium 的網站就沒用了 (因為網域不在 medium.com 下),但一時間沒想到比較好的解法...

今天下午突然想到應該可以擋下 replaceState() 來做,就花了些時間研究一下 Medium 的實作方法,然後用 Greasemonkey script 寫了一個 prototype,看起來有達到需求:「Medium Hash Cleaner」,程式碼可以在 source page 頁直接看到 (沒幾行)。

想法是透過 @run-at 指定在 document-end 時執行,然後掃描目前所有的 script tag,如果有找到 Medium 相關的 js 就把 window.history.replaceState() 換掉,這樣比較不會造成系統負擔。

先把這個想法跑一陣子看看... 沒問題就來寫 Chrome extension?

Ubuntu 16.04 LTS 的 Codename 被命名為 Xenial Xerus

在「The Ubuntu 16.04 LTS Codename Has Been Announced」這邊看到 Ubuntu 16.04 LTS 的 codename 確認了,依照慣例以字母順序輪流使用,所以會是 x 開頭...

Mark Shuttleworth 在 blog 上說明了 Ubuntu 16.04 LTS 想要推動的東西:「X marks the spot」。

還有半年... 話說回來,我前幾個月才換 14.04,這樣 16.04 要什麼時候跳過去 :o