Skip to content

Instantly share code, notes, and snippets.

View ming-chu's full-sized avatar
:octocat:
Focusing

Kenneth Chu ming-chu

:octocat:
Focusing
View GitHub Profile
@ming-chu
ming-chu / duplicates.py
Last active May 23, 2024 05:34 — forked from tfeldmann/duplicates.py
Fast duplicate file finder written in python (only show file size > 1MB)
#!/usr/bin/env python
"""
Fast duplicate file finder.
Usage: duplicates.py <folder> [<folder>...]
Based on https://stackoverflow.com/a/36113168/300783
Modified for Python3 with some small code improvements.
"""
import os
import sys
@ming-chu
ming-chu / main.dart
Last active October 4, 2024 04:26
Compare version name in Dart for DartPad share
// to see more: https://stackoverflow.com/a/79051433/5881669
import 'dart:math';
import 'package:collection/collection.dart';
void main() {
print(compareVersion('1.2.3', '12.3')); // -1
print(compareVersion('12.3', '1.2.3')); // 1
print(compareVersion('1.2.3', '1.2.3')); // 0
}
@ming-chu
ming-chu / Apple_mobile_device_types.txt
Created October 30, 2025 21:53 — forked from adamawolf/Apple_mobile_device_types.txt
List of Apple's mobile device codes types a.k.a. machine ids (e.g. `iPhone1,1`, `Watch1,1`, etc.) and their matching product names
i386 : iPhone Simulator
x86_64 : iPhone Simulator
arm64 : iPhone Simulator
iPhone1,1 : iPhone
iPhone1,2 : iPhone 3G
iPhone2,1 : iPhone 3GS
iPhone3,1 : iPhone 4
iPhone3,2 : iPhone 4 GSM Rev A
iPhone3,3 : iPhone 4 CDMA
iPhone4,1 : iPhone 4S