Semantic Versioning 與 Composer 的應用

Nomad PHP EU 上的議程:「Composer: Stability and Semantic Versioning Demystified」,講 Semantic VersioningComposer 上的應用。

投影片還講到了 Composer 處理版本需求互相重疊時的情況,可能會有 conflict 的問題...

Facebook 的主程式碼放在 Git?

在一月時,Facebook 官方的 Engineering Blog 上提到 Facebook 使用 Mercurial 遇到的問題,以及所作的努力「Scaling Mercurial at Facebook」:

Facebook's main source repository is enormous--many times larger than even the Linux kernel, which checked in at 17 million lines of code and 44,000 files in 2013.

...

Instead, we chose to improve Mercurial. Mercurial is a distributed source control system similar to Git, with many equivalent features.

當時的解讀是 Facebook 把 main source repository 放到 Mercurial 上。

以 Facebook 的規模以及遇到的問題,是有能力直接改變世界的,用 Mercurial 或是 Git 都算是合理的選擇。

不過這幾天在 Twitter 上看到:

這讓人錯亂了啊 XDDD

把 Git commit 切開

在「Split a commit in two with Git」這邊看到有趣的方法:

git rebase -i <oldsha1>
# mark the expected commit as `edit` (replace pick in front of the line), save a close
git reset HEAD^
git add ...
git commit -m "First part"
git add ...
git commit -m "Second part"
git rebase --continue

squash 是把多個 commit 合起來,這個方法是拆開。還沒有 push 出去,需要整理時應該會用到...

Google 提供的 Android Dashboards...

翻文章時翻到的:「Dashboards」。

在 Dashboards 裡的數據是出自 14 天內有連到 Google Play Store 上面的數據:

Beginning in April, 2013, these charts are now built using data collected from each device when the user visits the Google Play Store.

這個數據比實際出貨的版本有意義,因為這代表了會用 Store 的人的比率。而使用者不會連到 Store 的話,開發者也比較不用管支援度的問題...

2.3.3 (API 10) 之後累積起來是 95.1%,然後幾乎所有機器都支援 OpenGL ES 2...

利用 cpanm 的資料計算 Perl 版本分佈狀況...

如標題 :p 只拿 cpanm 分析一定會有偏差,所以數字參考看看就好:「Perl versions usage stats (with cpanm)」。

Perl 其中一個討厭的問題是版本太多了... 不是官方說 EoL 就可以 EoL 啊 :/

各種 credential 儲存的方式 (像是連到資料庫的密碼)

John Resig (現在在 Khan Academy) 在月初的時候發表了「Keeping Passwords in Source Control」討論要怎麼儲存 credential。

這不只是開發者的問題而已,這跟 code deploy 機制也很有關。目前沒有完美的方案,不同的解法都是在不同的環境與限制下而誕生出的產物。