Skip to content

Instantly share code, notes, and snippets.

@huytd
Created December 3, 2020 00:20
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save huytd/5b6360c3b3137395bca6a97ba31a5ab6 to your computer and use it in GitHub Desktop.
Save huytd/5b6360c3b3137395bca6a97ba31a5ab6 to your computer and use it in GitHub Desktop.
Every #til entries of WeBuild since 2016
This file has been truncated, but you can view the full file.
[5/5/2016, 1:52:07 AM] [alias Trung.Le, as tle]: #elixirlang <http://kipalog.com/posts/Chen-doi-tuong-vao-mot-List-theo-chieu-nguoc-voi-ham-List-insert_at-va-index-am>
[5/15/2016, 4:51:25 AM] []: #til: Maybe Just Nothing
[5/15/2016, 4:20:09 PM] [alias Trung.Le, as tle]: *TIL* technology does not only solve biz problems but also social and political problems too. Use it wisely for the good
[5/17/2016, 8:25:18 PM] [alias Trung.Le, as tle]: *TIL* JSON Octet là gì - <http://stackoverflow.com/questions/7200554/what-is-a-json-octet-and-why-are-two-required>
[5/17/2016, 8:31:39 PM] []: #til - Bỏ bữa khiến bạn béo bụng, ăn đủ bữa bằng các loại thức ăn có lợi cho sức khỏe là con đường đúng đắn nhất giúp bạn giảm cân thành công. :parrot:
[5/17/2016, 8:34:01 PM] []: #til Muốn hiểu vì sao, hãy tự đi tìm câu trả lời bằng cái mình tự khám phá là chính xác nhất. Chỉ nghe là không đủ.
[5/17/2016, 11:52:54 PM] [alias Trung.Le, as tle]: *TIL* sprocket trong Rails 3 khi khai báo manifest thì bạn không cần phải khai báo đầy đủ path, rails 3 sẽ tự động tìm `index` file:
vd
```
my_js_module
```
với Rails 4 thì cần khai báo đầy đủ:
```
my_js_module/index
```
[5/18/2016, 12:39:05 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: TIL: một số thứ về redis cluster (build, resharding, add/remove node trong cluster)
[5/18/2016, 2:56:15 AM] [Head of Intern]: may hom nay dang code 1 bai tap
[5/18/2016, 2:56:44 AM] [Head of Intern]: Input: Array A co n phan tu [7,6,4,5,1,6,2,3] va 1 so S
[5/18/2016, 2:56:49 AM] [Head of Intern]: va 1 so S
[5/18/2016, 2:57:02 AM] [Head of Intern]: dem coi trong array nay co bao nhieu cap ma tong = S
[5/18/2016, 2:57:14 AM] [Head of Intern]: tinh coi cach nao lam thi toi uu nhat ^^
[5/18/2016, 2:59:23 AM] [huy]: bai nay la NP hard ma @lephongvu
[5/18/2016, 2:59:24 AM] [huy]: :slightly_smiling_face:
[5/18/2016, 2:59:41 AM] [huy]: ah ma la cap. a
[5/18/2016, 2:59:43 AM] [huy]: ko phai subset a?
[5/18/2016, 3:00:18 AM] [Head of Intern]: code ben C++ co the dat dc O(n) cả tgian và bộ nhớ nhé
[5/18/2016, 3:00:39 AM] [huy]: dung hash table
[5/18/2016, 3:00:41 AM] [huy]: thi take O(n)
[5/18/2016, 3:00:47 AM] [huy]: cho het vao hash
[5/18/2016, 3:00:51 AM] [huy]: loop tu dau den cuoi
[5/18/2016, 3:00:58 AM] [huy]: voi moi thagn thi looking for thang con lai by hash
[5/18/2016, 3:01:04 AM] [Head of Intern]: yub
[5/18/2016, 3:01:08 AM] [Head of Intern]: :smile:
[5/18/2016, 3:01:29 AM] [Head of Intern]: dung roi day, y tuong co ban la the,
[5/18/2016, 3:01:43 AM] [huy]: minh tuong bai subset
[5/18/2016, 3:01:43 AM] [Head of Intern]: ben ruby hay may ngon ngu khac thi the nao nhi
[5/18/2016, 3:02:19 AM] [huy]: algorithm thi dau depend vao ngon ngu
[5/18/2016, 3:02:20 AM] [huy]: :wink:
[5/18/2016, 3:02:54 AM] [Head of Intern]: ah, y minh la, ben C++ no support std::unordered_map
[5/18/2016, 3:03:10 AM] [Head of Intern]: ko biet ben ruby no la cai gi tuong tu
[5/18/2016, 3:03:27 AM] [huy]: ah no la hash table do
[5/18/2016, 3:08:38 AM] [Head of Intern]: <http://ruby-doc.org/core-1.9.3/Hash.html>
[5/18/2016, 3:08:41 AM] [Head of Intern]: cai nay nhi
[5/18/2016, 3:09:58 AM] [huy]: uh
[5/18/2016, 3:10:00 AM] [huy]: :+1:
[5/18/2016, 8:31:59 PM] []: #til : Hiểu bằng được cái chưa hiểu là điều kiện cần để nâng cao trình độ.
[5/18/2016, 9:20:15 PM] [huy]: #til: Nếu bạn đang định làm gì đó mà không thấy ai làm, hỏi thì không ai ủng hộ thì đó ắt là cái nên làm :troll:
[5/18/2016, 9:21:33 PM] [giangnh]: @snacky: nói khó hiểu quá
[5/18/2016, 9:21:43 PM] [huy]: là thế này :v
[5/18/2016, 9:22:30 PM] [huy]: nếu bạn định đi ăn trưa vào lúc 9h sáng, mà cả cty ko ai đồng ý cho bạn đi, thì ắt hẳn đó chỉ là 1 đám cừu chỉ biết đi theo đám đông, gs ngô bảo châu cũng từng nói là ko nên làm con cừu, vì thế nếu bạn tách biệt khỏi đám đông mà vươn lên thì ắt sẽ thành công
[5/18/2016, 9:23:01 PM] [huy]: hậu quả của việc đi ăn trưa voà lúc 9h có thể là sẽ bị fired =&gt; thất nghiệp =&gt; ở nhà làm startup =&gt; thành công
[5/18/2016, 9:23:14 PM] [huy]: kết quả chậm tới nhưng hẳn là những người ko dám đi ăn trưa vào lúc 9h ko ai có được rồi
[5/18/2016, 9:23:15 PM] [huy]: :troll:
[5/18/2016, 9:25:01 PM] [giangnh]: 2 vế sau
[5/18/2016, 9:25:03 PM] [giangnh]: thì sai
[5/18/2016, 9:25:12 PM] [giangnh]: startup !=&gt; thành công
[5/18/2016, 9:26:29 PM] [huy]: cái này mình biết vì mình fail 2 cái rồi, nhưng vấn đề cơ bản là phải có niềm tin mãnh liệt
[5/18/2016, 9:26:30 PM] [huy]: =))
[5/18/2016, 9:26:36 PM] [huy]: đùa tí thôi
[5/18/2016, 9:26:40 PM] [huy]: dạo này OT đau đầu quá =.=
[5/18/2016, 9:27:16 PM] [giangnh]: haha
[5/18/2016, 10:03:20 PM] [andorx]: @snacky: sắp tai biến cmnr, huhu
[5/18/2016, 10:04:10 PM] [huy]: ngủ trưa đi pa
[5/18/2016, 11:33:34 PM] [alias Trung.Le, as tle]: #til <#C0GUMNSH0> <http://kipalog.com/posts/Cat-nghia-IdleTimeout-setting-cua-AWS-Elastic-Load-Balancer>
[5/20/2016, 10:58:20 PM] [hungtd9]: một số mẫu bài pv tiếp :smile: :
cho mảng có n phần tử chưa sắp xếp, tìm k phần tử lớn nhất (cách tối ưu nhất)
[5/21/2016, 12:17:42 AM] []: ```
defmodule A do
def rema([]), do: []
def rema([first| t]), do: [first | rema(t, first)]
def rema([], _), do: []
def rema([next | t], prev), do: if (next &gt;= prev), do: [next | rema(t, next)], else: rema(t, next)
end
A.rema([5,4,5,3,5,2]) =&gt; [5,5,5]
```
[5/21/2016, 12:34:14 AM] []: benchmark:
```
- 1 million -
0.002981s
- 2 million -
0.004741s
- 3 million -
0.010741s
- 4 million -
0.008919s
- 5 million -
0.021672s
- 6 million -
0.026712s
- 7 million -
0.014305s
- 8 million -
0.022811s
- 9 million -
0.026734s
- 10 million -
0.03867s
```
[5/22/2016, 9:56:20 PM] [hungtd9]: đọc hơi khó hiểu :smile:, nhưng hình như bạn cũng sắp xếp mảng cho k phần tử
[5/22/2016, 9:56:46 PM] [hungtd9]: bài này cách tối ưu là build k cái heap,
[5/22/2016, 9:57:05 PM] []: Mình ko sắp xếp, mình chỉ giữ lại thằng nào max thôi mà
[5/22/2016, 9:59:02 PM] [hungtd9]: chi phí 1 lần tìm max của bạn là n ?
[5/22/2016, 9:59:30 PM] []: Mình có viết benchmark kìa
[5/22/2016, 9:59:44 PM] []: array 10 triệu phần tử mất 0.038s
[5/22/2016, 10:00:17 PM] [hungtd9]: ok (y)
[5/22/2016, 10:00:26 PM] []: còn solution của bạn ?
[5/22/2016, 10:01:29 PM] [hungtd9]: mình chưa benchmark, mà môi trường khác nhau, nên chỉ tham khảo solution thôi
[5/22/2016, 10:02:04 PM] []: nếu benchmark theo thống kê đc thì mọi môi trường như nhau
[5/22/2016, 10:40:23 PM] [huy]: 2 bác chat với nhau thì đổi avatar đi =))
[5/22/2016, 10:44:05 PM] []: @hungtd9: đổi trước đi bạn
[5/25/2016, 1:02:01 AM] [trexnix]: #til Sửa lại commit message khi đã lỡ push lên repo <http://stackoverflow.com/questions/8981194/changing-git-commit-message-after-push-given-that-no-one-pulled-from-remote>
[5/25/2016, 2:03:52 AM] [alias Trung.Le, as tle]: #til hầu hết mọi vấn đề khục khặc trong đội là do vấn đề giao tiếp. Khuyến khích thành viên giải quyết mâu thuẫn thông qua việc chia sẻ cảm nhận với nhau
[5/25/2016, 2:05:06 AM] [alias Trung.Le, as tle]: mình mới thổ lộ với một anh trong team mà mình không vui vì một số hành động của anh ấy. Sau khi chia sẻ cả hai đều nhận ra các vấn đề cần khắc phục và vui vẻ xin lỗi nhau
[5/25/2016, 2:26:06 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: vấn đề kỹ thuật hay vấn đề khác vậy anh?
[5/25/2016, 3:28:28 AM] [alias Trung.Le, as tle]: vấn đề con ng
[5/25/2016, 12:54:43 PM] [huy]: phải chăng là a mới thổ lộ với anh Ryan vì cái tính thích rant của anh ấy :-s
[5/25/2016, 7:08:17 PM] [giangnh]: thấy @snacky chổ nào cũng có mặt hết ta
[5/25/2016, 7:08:31 PM] [huy]: :v
[5/25/2016, 7:55:10 PM] [alias Trung.Le, as tle]: #til nếu muốn trở thành lead, phải biết lắng nghe - lập lại 3x
[5/25/2016, 8:16:16 PM] [giangnh]: <http://queue.acm.org/detail.cfm?id=2169076>
[5/25/2016, 8:16:34 PM] [giangnh]: đang tìm hiểu và reactive
[5/25/2016, 8:16:54 PM] [huy]: #til muốn nhân viên nâng cao productivity thì sếp ko nên có mặt tại văn phòng
[5/25/2016, 8:17:55 PM] [giangnh]: @snacky: tin tôi đi, dân VN không phải dân Nhật
[5/25/2016, 8:18:08 PM] [giangnh]: nên sếp ko có ở đây là kể như công việc chậm
[5/25/2016, 8:18:39 PM] [huy]: cái đó là nghệ thuật của ông sếp, phải biết xuất hiện lúc nào và ko xuất hiện lúc nào =))
[5/25/2016, 8:19:07 PM] [huy]: sếp mình khá tâm lý, ở nhà cả ngày, 6h tối mới lên cty để kiểm tra xem ai chưa làm xong việc =.=
[5/25/2016, 8:19:44 PM] [vinhnglx]: vao #random di @snacky … e quang min` khap noi… spam qua
[5/26/2016, 2:04:43 AM] [minh.nguyen]: #til Mua sách bản quyền bao giờ cũng tốt. Mặc dù hơi thốn cho túi tiền.
[5/26/2016, 2:05:12 AM] [huy]: @nguyenquangminh tai sao the ban :+1:
[5/26/2016, 2:11:25 AM] [minh.nguyen]: @huydx: Mình vừa purchase xong quyển "Everyday Rails Testing with RSpec by Aaron Sumner” được recommend trên #reading sau bao nhiêu giờ lục lọi pdf lậu với nhiều bực tức vào người. Lỗi font, khó convert được cho mobile, và thường bị outdated. Vừa purchase xong thấy một cảm giác thanh thản và thoải mái dâng tràn, đọc version mới nhất, sách được convert sẵn qua tất cả format và mọi thức được chỉnh chu, đọc rất sướng. Chưa kể nhận được email cảm ơn của tác giả cũng ấm lòng :slightly_smiling_face:. Sau này boaứt tiền ăn nhậu lại mua sách xem ra tốt hơn :smile:
[5/26/2016, 2:11:53 AM] []: :+1:
[5/26/2016, 2:12:00 AM] [huy]: :+1:
[5/26/2016, 2:12:03 AM] [huy]: minh chi thay la
[5/26/2016, 2:12:10 AM] [huy]: bo tien ma mua phai quyen sach lom thi rat uc che
[5/26/2016, 2:12:11 AM] [huy]: =)))
[5/26/2016, 2:12:21 AM] [huy]: do la motivation cao nhat de ko mua sach xin.
[5/26/2016, 2:13:51 AM] []: mình khoái cuốn nào non-tech specific hơn, chú trọng và way of thinking
[5/26/2016, 2:14:13 AM] []: nói chứ càng đọc mấy cuốn tech càng đau não, ngu người @_@
[5/26/2016, 2:14:48 AM] [huy]: agree
[5/26/2016, 2:14:56 AM] [huy]: doc non tech thu duoc nhieu hon
[5/26/2016, 2:15:01 AM] [huy]: nen ballance giua 2 cai nay
[5/26/2016, 2:15:05 AM] [huy]: ko nen chi doc tech
[5/26/2016, 2:15:21 AM] [huy]: ma sach tech thuong minh xem ban free, hoac la safarionline
[5/26/2016, 2:15:23 AM] [huy]: it khi mua
[5/26/2016, 2:37:57 AM] []: Safarionline 39 usd / month thì hơi thốn, theo kiểu 1 năm đọc chưa tới chục cuốn :disappointed:, mà 400 usd / năm.
[5/26/2016, 2:42:25 AM] [huy]: thuong cai nay la cty mua cho
[5/26/2016, 2:42:29 AM] [huy]: chu it ng tu bo tien tui lam ...
[5/26/2016, 2:42:37 AM] [huy]: hoac la 1 nhom chung tien
[5/26/2016, 2:45:55 AM] [minh.nguyen]: 39$ / tháng thì thốn thật :joy:
[5/26/2016, 2:46:43 AM] [giangnh]: đó giờ
[5/26/2016, 2:46:51 AM] [giangnh]: order được cuốn
[5/26/2016, 2:46:58 AM] [giangnh]: javascript complete guide
[5/26/2016, 2:47:05 AM] [giangnh]: từ canada chuyển về
[5/26/2016, 2:47:10 AM] [giangnh]: hơn 1.6 triệu
[5/26/2016, 2:47:11 AM] [giangnh]: :neutral_face:
[5/26/2016, 2:47:15 AM] [giangnh]: tháng đó ăn mì gói
[5/26/2016, 6:01:59 AM] [alias Trung.Le, as tle]: #til LTS in NodeJS land is in days not weeks nor months...
[5/26/2016, 5:55:26 PM] [alias Trung.Le, as tle]: #til nâng cấp gem trong Rails app rất khó, có quá nhiều dependencies, nếu không có test đủ cover thì chỉ một minor upgrade có thể phá vỡ hoàn toàn app. mình dính ít nhất 5 lần rồi
[5/27/2016, 1:44:23 AM] [mymai]: hom nay hoc duoc mot cai,
ví dụ table user &amp; talle profile có mối quan hệ 1-n (user has_one profile)
thì tạo profile chỉ cần qua 1 dòng code
`after_create :create_profile`
dòng code này tương đương
```
User#create_profile
p = Profile.new(user_id: id);
p.save
p
```
[5/27/2016, 1:51:59 AM] []: @mymai : đừng bao giờ thay đổi model khác trong model :disappointed:
[5/27/2016, 1:52:08 AM] []: bad practice
[5/27/2016, 1:56:56 AM] [mymai]: dau cai nay la create 1 profile sau khi tao 1 user
[5/27/2016, 1:57:01 AM] [mymai]: minh nghi la no van oke
[5/27/2016, 1:59:20 AM] []: ```
profile = Profile.create
user = User.create(profile: profile)
```
[5/27/2016, 1:59:36 AM] []: viết kiểu này dễ hiểu hơn
[5/27/2016, 2:00:22 AM] [mymai]: vay lam sao tim duoc user nao trong profile
[5/27/2016, 2:00:56 AM] [mymai]: profile = Profile.create
tao the nay cac file trong profile la `nil` het
[5/27/2016, 2:01:11 AM] []: à, mình lược bỏ tham số thôi
[5/27/2016, 2:01:12 AM] [noob]: ủa sao lại viết kiểu đó @checkraiser :thinking_face:
[5/27/2016, 2:01:13 AM] [anh bán chuối]: what if Profile.create ok và User.create bị lỗi
[5/27/2016, 2:02:21 AM] [anh bán chuối]: em nghĩ làm như Mai cũng OK. còn muốn hay hơn thì bỏ vô 1 cái service, create user gì đó, wrap trong 1 cái transaction :wink:
[5/27/2016, 2:04:54 AM] [mymai]: transaction nay la sao ta, minh hok biet cach nay
[5/27/2016, 2:05:07 AM] [mymai]: @longkt90: co the noi them duoc hok
[5/27/2016, 2:05:19 AM] []: @mquy bạn bỏ cái này vào 1 transaction , có vấn đề gì không ổn ?
[5/27/2016, 2:06:13 AM] [anh bán chuối]: ah nếu anh checkraiser bỏ vô 1 cái transaction thì giống em :smile:
[5/27/2016, 2:06:23 AM] [noob]: tại vì logic phải tạo user trước xong mới tạo profile mà :thinking_face:
[5/27/2016, 2:08:47 AM] [mymai]: o`, logic la nhu ban @mquy noi y
[5/27/2016, 2:09:21 AM] []: @mquy dùng cái nào cũng ok cả, quan trọng là kết quả là cả 2 record được tạo và liên quan nhau
[5/27/2016, 2:09:23 AM] []: :smile:
[5/27/2016, 2:10:22 AM] [noob]: :shuffleparrot:
[5/27/2016, 2:11:49 AM] [anh bán chuối]: @mai: xài mặc định ở callback như bạn thì tạo user và tạo profile nằm chung 1 transaction, nên nếu profile ko tạo được thì user cũng ko được tạo =&gt; OK. Nhưng lúc này model User lại làm thêm chuyện tạo Profile, ko còn single responsibility nữa
[5/27/2016, 2:12:09 AM] [anh bán chuối]: có thể move ra 1 cái class/module bên ngoài
[5/27/2016, 2:12:20 AM] [anh bán chuối]: như anh checkraiser, nhưng wrap nó vô 1 cái transaction
```
User.transaction do
user = User.create
user.create_profile
end
```
[5/27/2016, 2:13:12 AM] [trexnix]: cho em góp ý tí, theo em hiểu thì
```
profile = Profile.create
user = User.create(profile: profile)
```
=&gt; 3 queries
```
user = User.create
profile = Profile.create(user: user)
```
=&gt; 2 queries
cho vào transaction nữa là ổn.
[5/27/2016, 2:16:57 AM] [mymai]: oh, thanks
[5/27/2016, 2:17:45 AM] []: Nếu muốn dùng như @mymai, nên code lại là
```
def User.create_profile(profile)
User.create(profile: profile)
end
```
[5/27/2016, 2:19:16 AM] [anh bán chuối]: coding style cua anh checkraiser la qua
[5/27/2016, 2:19:24 AM] [mymai]: minh nghi neu da tach ra thi lam nhu cach cua @longkt90 chi, con neu de nguyen thi dung nhu cach minh trinh bay o tren. Cach do no update o rails 4
MInh moi tim hieu xong. nhu minh viet ngan gon hon
[5/27/2016, 2:19:50 AM] []: @longkt90 : Mình chỉ theo nguyên tắc là không thay đổi Model khác trong model
[5/27/2016, 2:21:32 AM] [mymai]: Minh doc o day ne
<http://api.rubyonrails.org/classes/ActiveRecord/Associations/ClassMethods.html#method-i-has_one>
nen minh dung no luon
[5/27/2016, 2:21:50 AM] [mymai]: ngay xua minh hok biet minh lam y het ban checkraiser vay ak
[5/27/2016, 2:22:27 AM] [mymai]: co dieu viet hoi khac mot chut it
[5/27/2016, 2:23:17 AM] []: @mymai Nên cẩn thận, vì không phải cái gì của Rails viết đều là cái nên theo
[5/27/2016, 2:23:47 AM] []: Đều kệ, cứ làm đi, khi nào gặp khó khăn khi debug hay thêm feature thì sẽ sửa lại thôi :smile:
[5/27/2016, 2:24:54 AM] []: Giảm bớt nguy cơ: Ồ, Rails tài tình quá =)))
[5/27/2016, 2:25:06 AM] []: Việc gọi 1 hàm ở User mà nó tạo cho mình Profile thì vi diệu, đúng ko
[5/27/2016, 2:25:12 AM] []: nhưng ai dè nó lại gây đau khổ thôi :smile:
[5/27/2016, 2:31:09 AM] [mymai]: hi` oke a
[5/27/2016, 4:59:03 PM] [alias Trung.Le, as tle]: #til using callbacks in Rails is anti-pattern
[5/27/2016, 6:55:18 PM] []: #til use in git how to delete all local branch except specific branch ( in case is my develop branch)
```
git branch | grep -v "develop" | xargs git branch -D
```
[5/27/2016, 9:09:54 PM] [hungtd9]: #chem-gio: Trong Ruby dấu ( : ) colon (string value's pointer) đc sử dụng phổ biến trong hash, attributes… ưu điểm của nó là compare nhanh, nhưng thông thường lượng attributes object, hash key ko nhiều và việc đưa thêm 1 concept vào ngôn ngữ có thể làm phức tạp thêm nếu nó ko thực sự giải quết nhiều vấn đề ngôn ngữ đó.
[5/27/2016, 9:10:38 PM] [hungtd9]: mình code Ruby chưa lâu, mọi người thể làm sáng tỏ chút 1 số ưu điểm khác mà mình chưa thấy ko nhỉ ?
[5/27/2016, 9:27:31 PM] []: Tiết kiệm số kí tự, thay vì `’a’ =&gt; 1` , viết `a: 1` ngắn hơn :smile:
[5/27/2016, 9:43:58 PM] [hungtd9]: thế thì dùng luôn cái sau dẹp cái đầu đi :smile:
[5/27/2016, 9:47:05 PM] []: ừ, thì giờ toàn dùng cái sau mà cậu
[5/27/2016, 10:01:51 PM] [huy]: cai sau mai den 1.9 moi co
[5/27/2016, 10:02:00 PM] [huy]: nen hoi do co phong trao
[5/27/2016, 10:02:06 PM] [huy]: kill hash rocket symbol do
[5/27/2016, 11:20:58 PM] []: #til Programming has no relation with a computer. Yes, you can program using only paper and pencil
[5/28/2016, 12:37:37 AM] [huynh.cam]: @hungtd9: rocket symbol van hữu dụng trong một số trường hợp nhất định vd như {a =&gt; b} với a là một var chẳng hạn
[5/28/2016, 12:37:55 AM] [huynh.cam]: Cơ mà chém gió qua #random nhé :)
[5/28/2016, 3:44:19 AM] [hungtd9]: làm việc với metadata của class thì cũng nên qua cái api nào đó của class cho an toàn, dùng kiểu này hơi lạm dụng scripting language.
[5/28/2016, 3:44:58 AM] [hungtd9]: btw, mình đã move qua #random :smile:
[5/29/2016, 1:33:48 AM] [huynh.cam]: TIL: WITH recursive tree trong postgresql
<https://wiki.postgresql.org/wiki/Getting_list_of_all_children_from_adjacency_tree>
[5/29/2016, 7:16:44 PM] [giangnh]: google morning <!here|@here>
[5/29/2016, 7:18:43 PM] [giangnh]: aggregate của mongodb khá cool
<https://docs.mongodb.com/manual/aggregation/>
[5/29/2016, 8:32:56 PM] [alias Trung.Le, as tle]: #til When you are at the 30 years of age, you start to question what’s next?
[5/29/2016, 8:34:07 PM] [giangnh]: 1/3 đời người tôi làm được 1/3 điều bác Hồ dạy, không có gì !
[5/29/2016, 8:34:13 PM] [giangnh]: :shuffleparrot:
[5/29/2016, 9:59:24 PM] [alias Trung.Le, as tle]: #til RSpec’s `stub_const` can be used to stub out a constant of a class/module
[5/30/2016, 7:26:04 AM] []: #til - Tai nạn với Redis - *Learn from mistake* - Dùng Redis làm sessions store cho một app viết bằng Rails, quên mất tiêu cái vụ set expires, thế là nó cứ âm thầm ngốn hết Ram của hệ thống :disappointed:.
```
Rails.application.config.session_store :redis_store, servers: ["#{ENV['REDIS_URL']}/1/sessions"], expires_in: 60.minutes
```
Chỉ vì thiếu đoạn expires_in.
[5/30/2016, 7:29:38 AM] []: Khi 1 user logout, mình delete từ session store rồi, sao lại ngốn RAM nhỉ @viphat
[5/30/2016, 7:33:44 AM] []: @checkraiser - thường thì mình cũng hiếm khi logout nếu dùng máy tính cá nhân / điện thoại các kiểu...
[5/30/2016, 7:34:17 AM] []: thỉnh thoảng thì vào Browser clear cache thôi :smile:
[5/30/2016, 7:38:27 AM] []: lỗi nghe bá vậy
[5/30/2016, 7:38:34 AM] []: nhưng có nghĩa là bug rồi
[5/30/2016, 7:38:38 AM] []: rails ko set default
[5/30/2016, 7:38:41 AM] []: send PR đi
[5/30/2016, 7:38:59 AM] [huynh.cam]: -_- tính ra cũng khó
[5/30/2016, 7:39:15 AM] [huynh.cam]: một số ng khó tính lại bảo session nên là ko expire by default :disappointed:
[5/30/2016, 7:40:49 AM] []: set default cũng chỉ là giải pháp tạm thời
[5/30/2016, 7:41:08 AM] []: ngắn quá ko ổn, dài quá thì cũng vẫn dính cái ngốn RAM
[5/30/2016, 7:46:18 AM] []: vẫn hơn là kiểu unlimited
[5/30/2016, 2:29:37 PM] [alias Trung.Le, as tle]: #til I am so dumb when everyone around me is so smart and inspirational. The cycle of chasing after the better me.
[5/30/2016, 2:45:17 PM] [alias Trung.Le, as tle]: #til Testing biz idea should focus on proving hypothesis, fail fast. Iterate. Many devs are too hasty to jump to tech solution without understanding that it might be not needed yet. For example, if you have an app to let people make booking, you can test the idea by having a form website and do all the booking on clients' behalf manually. Once the idea prove feasible, you bring in automation magic
[5/30/2016, 9:54:52 PM] [giangnh]: ```
Object.assign({}, obj1, obj2) !== Object.assign(obj1, obj2)
```
[5/30/2016, 9:58:46 PM] []: Vì sao ?
[5/30/2016, 9:59:01 PM] []: `===` la gi
[5/30/2016, 10:00:58 PM] [giangnh]: Object.assign({}, obj1, obj2) không thay đổi obj1
Object.assign(obj1, obj2) thay đổi giá trị của obj1
[5/30/2016, 10:04:01 PM] []: Kết quả cuối cùng là giống nhau mà
[5/30/2016, 10:04:30 PM] [giangnh]: cái này áp dụng trong reducer của redux
[5/30/2016, 10:04:53 PM] [giangnh]: cái state của nó phải immutate
[5/30/2016, 10:08:14 PM] []: trong js, nếu bạn so sánh 2 object bất kỳ, `==` và `===` luôn trả về false :stuck_out_tongue:
[5/30/2016, 10:39:54 PM] [noob]: @giangnh: thật ra cái đó nó phù phiếm lắm, chơ muốn immutate hoàn toàn phải dùng thêm lib thì phải :omg:
[5/30/2016, 10:43:27 PM] [huy]: <http://bytearcher.com/articles/equality-comparison-operator-javascript/>
[5/30/2016, 10:53:05 PM] [alias Trung.Le, as tle]: #til #elasticsearch allows using different algorithm for `similarity`, for eg `BM25` for indexing field. So google Okapi BM25 and learn
[5/31/2016, 7:42:33 PM] [alias Trung.Le, as tle]: #til Ruby's `module_function`. I leave the finding to you. Google it :smile:
[5/31/2016, 7:44:37 PM] [giangnh]: use ```<http://xhprof.io/>``` profiling php in production.
[5/31/2016, 11:00:45 PM] []: #til: encounter zoombie process in server production
<http://www.howtogeek.com/119815/htg-explains-what-is-a-zombie-process-on-linux/>
[6/1/2016, 12:51:30 AM] [noob]: một trang chứa rất nhiều thông tin hữu ích cho ruby nè
[6/1/2016, 12:51:31 AM] [noob]: <http://idiosyncratic-ruby.com/categories/>?
[6/1/2016, 12:52:24 AM] [giangnh]: query larger 10 milions record with mongodb use `Map Reduce`
[6/1/2016, 5:54:04 PM] [alias Trung.Le, as tle]: #til con người không bao giờ hoàn hảo, họ sẽ mắc sai lầm và chỉ có khi có sai lầm thì họ mới nhận thức để cải thiện để tránh lập lại sai lầm đấy lần sau. Người làm quản lý nên khen ngợi nhân viên nếu họ mắc sai lầm, khuyến khích nhân viên tự sửa sai. Chỉ trích hay đánh giá chỉ mang đến những hiệu ứng tiêu cực. Về lâu dài sẽ gây nhiều tai hại cho sự phát triển của team. Nói như thế không phải là buông thả cho nhân viên muốn mắc sai lầm, hãy thẳng thắn góp ý và chia sẻ góc nhìn của bạn nếu nhân viên thực sự buông thả phần sửa sai mỗi lần sau khi mắc sai lầm.
[6/1/2016, 6:06:09 PM] []: @tle, rất là tâm đắc với chia sẻ của bạn vì mình cũng vừa mới dính vụ này (trường hợp này mình là người mắc lỗi, sau khi git blame đủ kiểu thì line code đó do mình thêm vào 6 tháng trước), phản ứng của bạn leader là lên kênh slack của cty la đổng lên (kiểu đứa nào làm cái này đây), xong tự fix rồi gửi một cái mail dài sọc cho dev team) &gt;&gt;&gt; gây ảnh hưởng tiêu cực đến cảm xúc của người mắc lỗi, gây xu hướng chống đối và khiến không khí ngột ngạt...
[6/1/2016, 6:06:47 PM] [huy]: minh nghi ban leader sai ko chi o viec la len
[6/1/2016, 6:06:50 PM] [huy]: ma o viec merge doan code do vao
[6/1/2016, 6:06:56 PM] [huy]: stupid process make wrong code
[6/1/2016, 6:07:03 PM] [alias Trung.Le, as tle]: @viphat: quản lý là công việc con người, dealing với con người thì phải hiểu cảm xúc của họ
[6/1/2016, 6:07:35 PM] [alias Trung.Le, as tle]: tất cả issue đều ít nhiều là lỗi chung của cả team như @huydx chia sẻ
[6/1/2016, 6:08:04 PM] [alias Trung.Le, as tle]: việc đổi thừa không làm cho job của team tốt hơn, có thể nhiều lúc quản lý rất bực vì bị khách hàng chửi
[6/1/2016, 6:08:15 PM] [alias Trung.Le, as tle]: nhưng nên nén lại, suy nghĩ xem vấn đề nó ở đâu ra
[6/1/2016, 6:08:26 PM] [alias Trung.Le, as tle]: có thể do procedure chưa tốt để code shit nó lọt vào
[6/1/2016, 6:08:48 PM] [alias Trung.Le, as tle]: nói chung người quản lý luôn có một phần trách nhiệm trong đó
[6/1/2016, 6:09:31 PM] [alias Trung.Le, as tle]: quản lý tốt là người sẽ cùng team sửa sai và khen ngợi người gây lỗi vì đã giúp quản lý tìm ra sai sót
[6/1/2016, 6:09:59 PM] [huy]: @tle e nghi cach vo cung don gian la voi moi action luon dat 1 cau hoi: action nay co giup team move 4ward ko
[6/1/2016, 6:10:04 PM] [huy]: ro rang action cua ban leader kia la ko roi
[6/1/2016, 6:10:08 PM] [alias Trung.Le, as tle]: uhm
[6/1/2016, 6:10:13 PM] [huy]: nen dat do thanh 1 rule trong team
[6/1/2016, 6:10:31 PM] []: @huydx, <@U0GCPHQM7> :+1:
[6/1/2016, 6:11:37 PM] [alias Trung.Le, as tle]: @huydx: anh không là big fan của rule lắm, vì lâu dài nó tạo nên một framework cứng nhắc, rất khó innovate team (dĩ nhiên là nó mang đến trật tự) - theo anh thì một rule đơn giản là 'all for one, one for all'
[6/1/2016, 6:11:55 PM] [alias Trung.Le, as tle]: còn biến tấu ở đâu thì để kệ team nó làm
[6/1/2016, 6:12:12 PM] [huy]: @tle vang, y em ko han la rule ma la 1 dang handbook
[6/1/2016, 6:12:13 PM] [huy]: vision ay
[6/1/2016, 6:12:19 PM] [huy]: con rule thi tat nhien van can
[6/1/2016, 6:12:22 PM] [huy]: cho nhung team ko fai dream team
[6/1/2016, 6:12:37 PM] [huy]: @viphat: minh nghi ban ko nen nhan nhin, hay la chong doi
[6/1/2016, 6:12:45 PM] [huy]: vi cai day chong lai rule la: giup team move 4ward ko
[6/1/2016, 6:12:52 PM] [huy]: ban nen thang than noi trc team ve van de ve mat quan ly
[6/1/2016, 6:13:03 PM] [huy]: (voi muc dich la giup team move 4ward)
[6/1/2016, 6:13:22 PM] [huy]: ko fai la de chi trich ban leader
[6/1/2016, 8:13:13 PM] [alias Trung.Le, as tle]: #til kìm chế cái tôi khi nhận đc nhận xét phản hồi tích cực từ ng khác, nên cảm ơn họ vì bạn được họ quan tâm. Nếu họ không quan tâm thì họ sẽ lờ hẳn bạn đi và đến cái ngày bạn nhận đc tờ thôi việc đặt trên bàn
[6/1/2016, 8:26:56 PM] []: hình như anh nhầm: kìm chế cái tôi khi nhận đc nhận xét phản hồi `tiêu` cực từ ng khác
[6/1/2016, 8:29:05 PM] [alias Trung.Le, as tle]: @hieuvo: tích cực mới đúng
[6/1/2016, 8:29:18 PM] [alias Trung.Le, as tle]: dịch từ constructive ra
[6/1/2016, 8:29:32 PM] [alias Trung.Le, as tle]: còn nếu người kia mà phản hồi không có ý đóng góp
[6/1/2016, 8:29:43 PM] [alias Trung.Le, as tle]: thì thực sự họ phải xem lại
[6/1/2016, 8:29:57 PM] []: đc khen thì em thấy bình thường, bị chửi mới cần phải kiềm chế :troll:
[6/1/2016, 8:31:47 PM] [giangnh]: một số người cái tôi của họ lớn họ sẽ không bao giờ chịu nghe lại.
[6/1/2016, 8:34:12 PM] []: à, từ gốc là constructive feedback, em hiểu ý anh rồi
[6/2/2016, 12:44:05 AM] [alias Trung.Le, as tle]: #til áp dụng kỹ thuật quản lý thời gian *Podomoro* thử vào cv thì thấy hiệu quả có tăng nhưng chưa quen thì thấy hơi stress. chửa kể meeting liên tục phát nát cycle. <https://en.wikipedia.org/wiki/Pomodoro_Technique>
[6/2/2016, 2:05:43 AM] [huy]: em sau 1 tgian podomoro
[6/2/2016, 2:05:49 AM] [huy]: thi thay podomoro hoi kho de lam o cty
[6/2/2016, 2:05:52 AM] [huy]: vi hay vi disrupt
[6/2/2016, 2:07:12 AM] [alias Trung.Le, as tle]: uhm
[6/2/2016, 2:07:18 AM] [alias Trung.Le, as tle]: anh cũng thấy thế
[6/2/2016, 3:22:29 AM] [crashbell]: #til dùng `git mv` cho history tree và code review gọn gàng hơn
[6/2/2016, 3:44:53 AM] []: #til trong 1 số trường hợp, IGNORE INDEX có thể giúp mysql query chạy nhanh hơn rất nhiều
[6/2/2016, 6:31:41 AM] [huy]: @hieuvo: cu the hon di ban
[6/2/2016, 7:54:56 PM] [alias Trung.Le, as tle]: #til cảm thấy công việc có ý nghĩa khi biết việc mình làm đang thay đổi cuộc sống của người khác. Chuyện là mới gặp mua đồ của một anh bạn Ấn Độ và đc biết anh kiếm sống nhờ sản phẩm VideoHive bên mình
[6/2/2016, 7:58:58 PM] []: #til It’s really hard to fight with a person who doesn’t fight back.
[6/2/2016, 7:59:50 PM] []: @huydx: thường mysql sẽ tự parse query, rồi tự tìm index cần sử dụng sao mà optimize nhất (theo tiêu chí của mysql), nhưng một số trường hợp, index mysql chọn chạy rất chậm, mình phải chủ động force cho nó xài index khác hoặc không xài index luôn, ở cty mới thấy 1 trường, xài index chạy 4s, không xài index chạy 30ms
[6/2/2016, 8:09:30 PM] [huy]: @hieuvo: the thi minh nghi van de o cach danh index
[6/2/2016, 8:09:33 PM] [huy]: hoac la cach query
[6/2/2016, 8:09:40 PM] [huy]: disable index co ve ko phai la 1 cach lam tot
[6/2/2016, 8:10:30 PM] []: trong 1 số trường hợp full scan lại nhanh hơn index nhiều
[6/2/2016, 8:10:48 PM] []: @hieuvo nghe lạ quá nhỉ :smile:
[6/2/2016, 8:12:04 PM] []: vd nhỏ, table vài tr dòng, và result của query trả về tầm 1/3 số dòng của table, thì fullscan sẽ nhanh vượt trội index :troll:
[6/2/2016, 8:13:56 PM] []: vậy làm cách nào biết được result trả về 1/3 số dòng table nếu không query ?
[6/2/2016, 8:14:30 PM] []: chạy/ test thử query, nếu quá chậm thì optimize :smile:
[6/2/2016, 8:15:25 PM] []: ở trên là vd, lúc làm thì không quan trọng nó trả về mấy dòng, thấy chậm thì đè ra optimize thôi
[6/2/2016, 8:18:51 PM] [huy]: neu duoc ban paste 2 cai explain len dc k?
[6/2/2016, 8:18:54 PM] [huy]: khi dung index
[6/2/2016, 8:18:57 PM] [huy]: va khi fullscan
[6/2/2016, 8:20:38 PM] [alias Trung.Le, as tle]: @hieuvo: bạn có thể gửi mình xem `EXPLAIN` nó giải thích ra sao không, nghe vụ này khá tò mò
[6/2/2016, 8:22:52 PM] []: cái này hàng cty, post lên hơi ghê ghê :smile:
[6/2/2016, 8:23:11 PM] [alias Trung.Le, as tle]: bạn có thể obfusticate cái query nếu ngại
[6/2/2016, 8:23:13 PM] []: coi explain thôi nhé, em không đưa query chi tiết đc
[6/2/2016, 8:27:40 PM] [huy]: cai duoi la fullscan ha ban
[6/2/2016, 8:27:51 PM] []: uh
[6/2/2016, 8:28:01 PM] [huy]: sao so luong rows khac nhau vay nhi
[6/2/2016, 8:28:02 PM] []: đúng hơn là ignore index của table `p`
[6/2/2016, 8:28:20 PM] [huy]: chung to index la composed index dung k
[6/2/2016, 8:28:37 PM] [huy]: va cai so luong combination thi &gt; nhieu cai so luong row ma can tim kiem
[6/2/2016, 8:29:05 PM] []: thế nhưng cái sau lại chạy chỉ trong 30ms
[6/2/2016, 8:29:09 PM] []: trong khi cái đầu là 4s
[6/2/2016, 8:29:19 PM] [huy]: uh vi cai dau so luong row scan no qua lon
[6/2/2016, 8:29:26 PM] [huy]: y minh la luong index &gt; luong row
[6/2/2016, 8:29:34 PM] [huy]: nen minh doan la ban dung composed index
[6/2/2016, 8:29:38 PM] [huy]: chu k fai index cho cai row can tim
[6/2/2016, 8:30:31 PM] []: nói chung, ngồi viết query nhiều sẽ thấy, mysql chọn index đôi khi chuối lắm, mình phải chủ động force index khác hoặc không xài index
[6/2/2016, 8:30:52 PM] [huy]: no ko chuoi dau
[6/2/2016, 8:30:56 PM] [huy]: vi ban ko cho no option
[6/2/2016, 8:31:04 PM] [huy]: nen no chon cai tot nhat trong kha nang co the
[6/2/2016, 8:31:16 PM] [huy]: minh nghi o tren ban nen tao them 1 cai hashed-base index
[6/2/2016, 8:31:20 PM] [huy]: cho cai row can query thi se nhanh
[6/2/2016, 8:31:28 PM] []: bữa nào rảnh, viết 1 bài vụ này :smile:
[6/2/2016, 8:31:39 PM] [huy]: :+1:
[6/2/2016, 8:31:43 PM] []: innodb của mysql không có hash index
[6/2/2016, 8:31:46 PM] []: chỉ có BTREE thôi
[6/2/2016, 8:32:08 PM] [huy]: uhm
[6/5/2016, 10:52:12 PM] [crashbell]: #til tìm hiểu về brachistochrone để thấy đi thẳng không hẳn là đường đi ngắn nhất (tính theo thời gain). Áp dụng cho những thứ xảy ra trong công việc và cuộc sống thấy có vẻ đúng :slightly_smiling_face:
[6/6/2016, 8:22:11 PM] [alias Trung.Le, as tle]: #til thêm vào `Rack::Deflater` middleware trong Rack app vd Rails/Sinatra/Hanami để nén số payload gửi trả về, giúp rút ngắn thời gian nhận payload cho đầu cuối.
[6/6/2016, 9:39:56 PM] []: #til : Refactoring is breaking the complex parts, not separating the simple parts
[6/7/2016, 4:02:50 PM] [alias Trung.Le, as tle]: #til #aws Delegate Access Across AWS Accounts Using IAM Roles (<http://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_cross-account-with-roles.html>)
[6/7/2016, 5:05:23 PM] [alias Trung.Le, as tle]: #til một người lãnh đạo tốt không cần phải có số IQ cao, dĩ nhiên họ cần thông minh, hiểu biết về văn hoá và cảm xúc
[6/7/2016, 8:10:45 PM] [minh.nguyen]: #til Start rails với ruby flag `-d` (ví dụ sử dụng `ruby -d bin/rails server`) sẽ giúp print ra toàn bộ line mà exception được raise. Flag này đặc biệt hữu dụng khi exception bị một gem nào đó catch rồi thay đổi luôn message :parrot:
[6/7/2016, 9:08:09 PM] [alias Trung.Le, as tle]: @nguyenquangminh: chiêu này mới lợi hại
[6/8/2016, 7:53:01 PM] []: #til - mấy trick nhỏ về Index trong Postgresql để improve performance - <http://blog.scoutapp.com/articles/2016/05/31/3-postgresql-indexing-tricks-that-surprise-everyone?ct=t(June_2016_Newsletter_6_7_2016)>
[6/9/2016, 7:27:50 AM] []: #til The easiest way to begin leveling up as a programmer is to start opening 10 tabs on chrome.
[6/9/2016, 7:37:11 AM] [alias Trung.Le, as tle]: #til Being a programmers, we are all bunch of opininated creatures, it’s healthy for disagreement to thrive but only we both parties do it right, in a constructive and respectful manner
[6/9/2016, 4:42:46 PM] [alias Trung.Le, as tle]: #til the IANA protocol number list <http://www.iana.org/assignments/protocol-numbers/protocol-numbers.xhtml>, very useful when you have to code NetworkAcl in AWS Cloudformation template
[6/9/2016, 7:52:42 PM] [alias Trung.Le, as tle]: #til một là làm hai là không, có có cái vụ nguỵ biên ương ương dở dở ở giữa :slightly_smiling_face:
[6/9/2016, 7:54:57 PM] []: #til true is !false
[6/9/2016, 8:04:51 PM] [tucq88]: #til naming is one of the hardest thing in programming (not yet today i learn, but today i remind myself)
[6/9/2016, 8:51:46 PM] [crashbell]: @tucq88:
&gt; There are only two hard things in Computer Science: cache invalidation and naming things. - Phil Karlton
[6/9/2016, 8:56:18 PM] [alias Trung.Le, as tle]: @tucq88: you have not seen the worst one yet, if you are in Java world, you know what I meant
[6/9/2016, 8:59:21 PM] []: You mean the AbstractFactoryFactorySingletonBuilder ;))
[6/9/2016, 9:02:32 PM] [alias Trung.Le, as tle]: @anhduy: that’s not the longest
[6/9/2016, 9:03:32 PM] []: :troll:
[6/9/2016, 9:05:10 PM] [crashbell]: @anhduy: <https://github.com/Quotation/LongestCocoa>
[6/9/2016, 9:11:03 PM] [tucq88]: lol =)))) can't believe there's that type of repo =)))))) @crashbell
[6/9/2016, 9:13:08 PM] [giangnh]: ```CMMetadataFormatDescriptionCreateWithMetadataFormatDescriptionAndMetadataSpecifications```
[6/9/2016, 9:24:20 PM] [alias Trung.Le, as tle]: lol
[6/9/2016, 11:17:57 PM] [huy]: #til everytime we install anything with brew, brew create it own $HOME and its own environment variable
[6/9/2016, 11:18:07 PM] [huy]: so we can’t use system env variable
[6/9/2016, 11:58:16 PM] []: :| cái này mới, em xài đó giờ chưa bị, qua đâu đó share đi anh @huydx
[6/9/2016, 11:58:58 PM] [huy]: @anhduy: anh tu tao 1 cai tap
[6/9/2016, 11:59:01 PM] [huy]: formula
[6/9/2016, 11:59:05 PM] []: Dạ
[6/9/2016, 11:59:08 PM] [huy]: trong do co su dung `go install`
[6/9/2016, 11:59:13 PM] [huy]: thi no k doc dc GOPATH
[6/9/2016, 11:59:16 PM] [huy]: anh print ra env
[6/9/2016, 11:59:19 PM] [huy]: thi no chi co cua brew thoi
[6/9/2016, 11:59:32 PM] [huy]: no tao 1 cai thu muc
[6/9/2016, 11:59:33 PM] [huy]: .brew_home
[6/9/2016, 11:59:35 PM] [huy]: roi coi do la home
[6/9/2016, 11:59:40 PM] [huy]: set lai toan bo env, path...
[6/10/2016, 12:01:46 AM] []: Lạ nhỉ, đó giờ chưa nghe bao giờ, để tối về nghịch thử. Tại có nhiều formula depends go lắm mà thấy nó build bình thường
[6/10/2016, 12:03:36 AM] [tucq88]: :-s
[6/10/2016, 12:03:42 AM] [huy]: <https://gyazo.com/2bae77a1d5702b0ee0a194565fd4fe3f>
[6/10/2016, 12:03:45 AM] [huy]: thu cai bit ngay
[6/10/2016, 12:05:23 AM] [huy]: ```
➜ brew-tap git:(master) ✗ env
PATH=/Users/jp20992/.rvm/gems/ruby-2.3.0/bin:/Users/jp20992/.rvm/gems/ruby-2.3.0@global/bin:/Users/jp20992/.rvm/rubies/ruby-2.3.0/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Users/jp20992/.rvm/bin:/usr/local/sbin:/Users/jp20992/Workspace/golang/bin:/Users/jp20992/Workspace/otto
COMMAND_MODE=unix2003
TMPDIR=/var/folders/fx/gbbzrp_s1dz7b3dtxy6bzd240000gp/T/
LOGNAME=jp20992
XPC_FLAGS=0x0
HOME=/Users/jp20992
Apple_PubSub_Socket_Render=/private/tmp/com.apple.launchd.fQXsezUWb6/Render
LANG=ja_JP.UTF-8
COLORFGBG=7;0
USER=jp20992
SSH_AUTH_SOCK=/private/tmp/com.apple.launchd.JdYZvsLMBe/Listeners
TERM=xterm-256color
ITERM_PROFILE=Default
XPC_SERVICE_NAME=0
TERM_PROGRAM=iTerm.app
SHELL=/bin/zsh
ITERM_SESSION_ID=w0t1p1
PWD=/Users/jp20992/Workspace/LINE/brew-tap
__CF_USER_TEXT_ENCODING=0x1F6:0x1:0xE
SHLVL=1
OLDPWD=/Users/jp20992/Workspace/golang/src/github.com/libgit2/git2go
ZSH=/Users/jp20992/.oh-my-zsh
PAGER=less
LESS=-R
LC_CTYPE=ja_JP.UTF-8
LSCOLORS=Gxfxcxdxbxegedabagacad
GOPATH=/Users/jp20992/Workspace/golang
rvm_prefix=/Users/jp20992
rvm_path=/Users/jp20992/.rvm
rvm_bin_path=/Users/jp20992/.rvm/bin
_system_type=Darwin
_system_name=OSX
_system_version=10.11
_system_arch=x86_64
rvm_version=1.27.0 (master)
GEM_HOME=/Users/jp20992/.rvm/gems/ruby-2.3.0
GEM_PATH=/Users/jp20992/.rvm/gems/ruby-2.3.0:/Users/jp20992/.rvm/gems/ruby-2.3.0@global
MY_RUBY_HOME=/Users/jp20992/.rvm/rubies/ruby-2.3.0
IRBRC=/Users/jp20992/.rvm/rubies/ruby-2.3.0/.irbrc
RUBY_VERSION=ruby-2.3.0
rvm_alias_expanded=
rvm_bin_flag=
rvm_docs_type=
rvm_gemstone_package_file=
rvm_gemstone_url=
rvm_niceness=
rvm_nightly_flag=
rvm_only_path_flag=
rvm_proxy=
rvm_quiet_flag=
rvm_ruby_bits=
rvm_ruby_file=
rvm_ruby_make=
rvm_ruby_make_install=
rvm_ruby_mode=
rvm_script_name=
rvm_sdk=
rvm_silent_flag=
rvm_use_flag=
rvm_wrapper_name=
rvm_hook=
_=/usr/bin/env
```
[6/10/2016, 12:05:28 AM] [huy]: 2 cai khac nhau
[6/10/2016, 12:11:08 AM] []: để em thử debug nhanh toẹ
[6/10/2016, 12:32:38 AM] []: rồi, nó reset hết thật
[6/10/2016, 12:32:55 AM] []: anh check cái formula go nào rồi làm theo vậy
[6/10/2016, 12:33:11 AM] [huy]: anh tu lam 1 cai
[6/10/2016, 12:33:33 AM] [huy]: a nghi mindset brew kha hay
[6/10/2016, 12:33:36 AM] [huy]: no isolate het
[6/10/2016, 12:33:41 AM] []: ```
def install
contents = Dir["{*,.git,.gitignore}"]
gopath = buildpath/"gopath"
(gopath/"src/github.com/hashicorp/consul").install contents
ENV["GOPATH"] = gopath
ENV.prepend_create_path "PATH", gopath/"bin"
Language::Go.stage_deps resources, gopath/"src"
cd gopath/"src/github.com/hashicorp/consul" do
system "make"
bin.install "bin/consul"
zsh_completion.install "contrib/zsh-completion/_consul"
end
# install web-ui to package share folder.
(pkgshare/"web-ui").install resource("web-ui") if build.with? "web-ui"
end
```
[6/10/2016, 12:33:43 AM] [huy]: gio moi biet cai tro nay
[6/10/2016, 12:34:01 AM] [huy]: day la no set gopath cua no
[6/10/2016, 12:34:05 AM] [huy]: anh muon dung cai gopath cua anh
[6/10/2016, 12:35:10 AM] []: theo em thì ko nên làm thế
[6/10/2016, 12:35:10 AM] []: :smile:
[6/10/2016, 12:35:18 AM] []: tại anh viết formula là để share
[6/10/2016, 12:35:23 AM] []: nên mỗi người sẽ một khác
[6/10/2016, 12:35:39 AM] []: nên tốt nhất anh depend vào go formula
[6/10/2016, 12:35:53 AM] []: xong làm theo nó là được
[6/10/2016, 12:35:57 AM] []: check consul.rb á anh
[6/10/2016, 12:36:00 AM] [huy]: dung roi em
[6/10/2016, 12:36:04 AM] [huy]: co ma muc dich cai formula cua anh
[6/10/2016, 12:36:15 AM] [huy]: la de tao cai environment de dev cho 1 cai go lib
[6/10/2016, 12:36:29 AM] [huy]: nen no phai vao cai path chuan
[6/10/2016, 12:36:32 AM] [huy]: dang dung`
[6/10/2016, 12:36:35 AM] [huy]: nen a nghi lai roi
[6/10/2016, 12:36:41 AM] [huy]: dev xong het cai go lib day roi pack lai binary
[6/10/2016, 12:36:43 AM] [huy]: roi deliver
[6/10/2016, 12:36:44 AM] [huy]: :)))
[6/10/2016, 12:48:35 AM] []: ko hiểu gì luôn nhưng có vẻ tốt rồi :smile:
[6/10/2016, 4:18:18 AM] [alias Trung.Le, as tle]: #til lưu ý là CodeDeploy agent của AWS chỉ chạy với gói ruby2.0, nếu bác nào nâng lên Ubuntu 16.04 LTS thì xin cài ruby2.0 vào thông qua repo của Brightbox
[6/10/2016, 6:52:21 AM] [alias Trung.Le, as tle]: #til một mẹo nhỏ refactor cloudformation stack để setup
access cho instance truy cập vào đúng S3 bucket của
Amazon để download codedeploy-agent về, sau là rule
mà AWS khuyến khích
```
"InstanceRolePolicies": {
"Type": "AWS::IAM::Policy",
"Properties": {
"PolicyDocument": {
"Statement": [
{
"Sid" : "AllowCodeDeployInstallerAccess",
"Effect" : "Allow",
"Action" : [
"s3:Get*"
],
"Resource" : [
"arn:aws:s3:::aws-codedeploy-us-east-1/*",
"arn:aws:s3:::aws-codedeploy-us-west-1/*",
"arn:aws:s3:::aws-codedeploy-us-west-2/*",
"arn:aws:s3:::aws-codedeploy-eu-west-1/*",
"arn:aws:s3:::aws-codedeploy-eu-central-1/*",
"arn:aws:s3:::aws-codedeploy-ap-northeast-1/*",
"arn:aws:s3:::aws-codedeploy-ap-southeast-1/*",
"arn:aws:s3:::aws-codedeploy-ap-southeast-2/*",
"arn:aws:s3:::aws-codedeploy-sa-east-1/*" ]
},
]
}
}
}
```
Dĩ nhiên là oke rồi, nhưng mình nghĩ hơi thừa, vì nếu chạy
ở một region nào đó thì nên setup acccess đúng cho region đó
mình refactor lại như sau:
```
"InstanceRolePolicies": {
"Type": "AWS::IAM::Policy",
"Properties": {
"PolicyDocument": {
"Statement": [
{
"Sid" : "AllowCodeDeployInstallerAccess",
"Effect" : "Allow",
"Action" : [
"s3:Get*"
],
"Resource" : [
{ "Fn::Join" : ["arn:aws:s3:::aws-codedeploy-", [ { "Ref" : "AWS::Region" }, "/*" ] ] }
]
},
]
}
}
}
```
giờ CF stack sẽ tự động tìm ra region mà người dùng đc apply cho và chỉ thêm
vào duy nhất resource đó :smile:
[6/10/2016, 8:39:00 PM] [giangnh]: #til
use ngrok xpose a local web server to the internet.
[6/10/2016, 9:27:39 PM] [minh.nguyen]: #til sử dụng `Kernel#method` và `Method#source_location` để biết method được call implement ở file nào và line nào. Ví dụ: `user.method(:generate_commission).source_location`
[6/13/2016, 1:15:08 AM] []: #til: why is Haskell so special: <https://en.wikipedia.org/wiki/Hindley–Milner_type_system>
[6/13/2016, 1:42:52 AM] [huy]: #til : vim expect executed process has pipe-able stdin and stdout, so if you want to call vim in another language not bash (python or golang), you need to explicit set stdout and stdin
[6/13/2016, 1:59:24 AM] [huy]: #til ban co biet `git rebase —interactive` thuc ra la 1 cai shell
[6/13/2016, 1:59:29 AM] [huy]: nam o /Library/Developer/CommandLineTools/usr/libexec/git-core/git-rebase--interactive
[6/13/2016, 2:02:40 AM] [huy]: #til : android pin nhu shit, minh sai lam vi da dung android T_T
[6/13/2016, 2:02:54 AM] [huy]: (dac biet ket hop voi wireless smartwatch + wireless earphone)
[6/13/2016, 2:09:05 AM] []: @huydx: ko chỉ riêng rebase -i mà là tất cả các lệnh của git đều như vậy, git chỉ là wraper thôi
[6/13/2016, 2:09:33 AM] [huy]: uh
[6/13/2016, 2:09:39 AM] [huy]: gio a moi biet la no wrap nhieu den the
[6/13/2016, 2:09:46 AM] [huy]: minh cu to mo k hieu no goi vim the nao
[6/13/2016, 2:09:50 AM] [huy]: hoa ra la `eval`
[6/13/2016, 4:23:46 AM] [tucq88]: #til if you're the smartest one in the room (even not), you're in the wrong room
[6/13/2016, 7:20:22 AM] [rebyn]: or you're the only one in the room
[6/13/2016, 7:55:58 AM] []: Don’t be greedy guys, if you’re smartest in the room, try to teach other to overcome you, lol
[6/13/2016, 7:57:00 AM] []: what a shame i heard that from vietnamese devs
[6/13/2016, 2:22:04 PM] [alias Trung.Le, as tle]: #til passion pushes human to a new level, for example staying sleepless or half-sleep this Euro 2016 season. I guess the same goes for who whom spends all weekend learning and coding
[6/13/2016, 4:18:27 PM] [huy]: passion bring us disease...
[6/13/2016, 4:29:54 PM] [alias Trung.Le, as tle]: bố mẹ nói cái gì thái quá thì không tốt
[6/14/2016, 7:50:53 AM] []: #til Respect boundary in relationships and your code
[6/14/2016, 6:13:56 PM] [alias Trung.Le, as tle]: #til NEVER make manual changes to your AWS via GUI console, do it via SDK or CF so that a canonical source of truth is maintained. I even delete and re-create all stacks weekly to ensure to manual changes got in
[6/15/2016, 12:52:19 AM] [alias Trung.Le, as tle]: #til ElasticSearch has index warmer mechanism <https://www.elastic.co/guide/en/elasticsearch/reference/1.7/indices-warmers.html>
[6/15/2016, 2:58:21 AM] [huy]: #til golang pointer va C ve co ban la compability
[6/15/2016, 2:58:32 AM] [huy]: co the goi golang function pointer in C
[6/15/2016, 3:02:04 AM] [huy]: #til su dung “unsafe” package de thao tac voi memory tren C lib nhu free hoac calloc
[6/16/2016, 12:35:01 AM] [crashbell]: #til Trong Node, `emit()` func của EventEmitter là synchronous:
&gt; When the EventEmitter object emits an event, all of the Functions attached to that specific event are called synchronously. Any values returned by the called listeners are ignored and will be discarded.
[6/16/2016, 1:22:05 AM] [rebyn]: #til code có gớm (efficiency wise) thì cứ chạy đi rồi mới biết đường mà sửa =)) (procrastinate nguyên 1 tuần) (mind trick :flushed:)
[6/16/2016, 1:34:45 AM] []: Make it work, make it right, make it fast
[6/19/2016, 4:40:56 PM] []: #til
```
rescue =&gt; e
```
NOT
```
rescue Exception =&gt; e
```
[6/19/2016, 11:11:50 PM] [alias Trung.Le, as tle]: #til just shut up and listen
[6/19/2016, 11:45:00 PM] [tucq88]: @tle you mean `if someone is talking , others should shut up` ?
[6/19/2016, 11:58:54 PM] []: Có vẻ là nói ít thôi (ngưng ba hoa), lắng nghe người khác giúp mình học hỏi nhiều hơn.
[6/19/2016, 11:59:31 PM] [huy]: ko phải đâu, dự là a @tle đi kara, ko cướp mic để hát được nên phải ngậm ngùi làm khán giả
[6/20/2016, 2:41:37 AM] [rebyn]: ^ gia thuyet nay co ve hop ly hon
[6/21/2016, 2:21:06 AM] [alias Trung.Le, as tle]: #til KMS is a great way to store credentials for your AWS IAM
[6/21/2016, 2:21:52 AM] [rebyn]: #til (app) credentials are best left in S3
[6/21/2016, 8:15:36 AM] [alias Trung.Le, as tle]: #til `a href` tag suppors `download` attribute to allow you custom set the file to be downloaded from the link specified in `href`
[6/21/2016, 8:33:57 PM] [alias Trung.Le, as tle]: #til there is no such thing as wrong or right, it all comes down to how you perceive it
[6/21/2016, 9:36:18 PM] [vien]: #til Đôi khi nên đối diện thẳng với sự thật về bản thân mình
[6/21/2016, 9:41:17 PM] [tucq88]: @vien.vu: vote luôn luôn
[6/21/2016, 9:58:16 PM] []: #til You have to sell yourself to write test, no boss pays you for that, lol, f***k
[6/21/2016, 11:01:07 PM] [alias Trung.Le, as tle]: #til if you have to sell yourself for something that is considered standard, you are not in the right place, get out
[6/22/2016, 12:30:04 AM] [kimhieu]: #til Understand `RxJava` with `saveState` and `Android Fragment`
[6/22/2016, 7:19:54 PM] [crashbell]: #til Get first iBeacon app work :champagne:
[6/22/2016, 8:55:54 PM] [alias Trung.Le, as tle]: #til cách kiểm tra SHA1 fingerprint của một public cert `$ openssl x509 -noout -in your_public_cert.crt -fingerprint -sha1`
[6/22/2016, 9:45:18 PM] [alias Trung.Le, as tle]: #til có cái chức năng gọi là *SNI* nếu ai đụng vào SSL cert, gúc gồ để biết thêm đi nhé
[6/23/2016, 1:00:41 AM] [huy]: #til can than khi viet your own brew formula, neu k can than thi no remove /usr/local/bin nhu k
[6/23/2016, 1:00:44 AM] [huy]: van chua hieu ly do
[6/23/2016, 1:06:22 AM] [huy]: da biet ly do
[6/23/2016, 1:06:24 AM] [huy]: tai minh ngu...
[6/23/2016, 1:06:35 AM] [rebyn]: em cũng đã biết lý do
[6/23/2016, 1:07:08 AM] [huy]: thoi di meeting cong ty
[6/23/2016, 7:02:31 PM] [huy]: #til `rm -rf` một thư mục được symlink thì nó sẽ xoá nội dung cái thư mục thực tế chớ ko phải xoá cái symlink, muốn xoá cái symlink thì `rm` thôi :omg: may thôi xoá nguyên `/usr/local/bin` giống a @huydx rồi
[6/23/2016, 7:02:56 PM] [huy]: :parrot:
[6/23/2016, 7:03:00 PM] [huy]: hoi nhung nguoi thich xoa
[6/23/2016, 7:03:09 PM] [huy]: :parrot:
[6/24/2016, 8:01:42 PM] [huy]: #til DigitalOcean vẫn sẽ charge tiền cho những droplet bạn đã tắt (power off) vì nó vẫn chiếm dụng tài nguyên trên máy chủ của họ. Giải pháp là tạo snapshot cho droplet đó, xong rồi destroy cái droplet đó đi. Tránh mất tiền oan.
[6/24/2016, 8:03:04 PM] [huy]: #til số 2: DigitalOcean sẽ ko charge tiền cho 1 droplet vừa được tạo ra, cho tới khi nào nó chạy đủ 1 giờ, vì vậy có thể tạo rồi xoá liên tục nếu chỉ có nhu cầu test :troll:
[6/24/2016, 8:04:11 PM] [alias Trung.Le, as tle]: cái đó nó ghi rõ lúc mình turn off mà
[6/24/2016, 8:04:35 PM] [huy]: nhiều người ko đọc hoặc ko tìm hiểu, cứ nhắm mắt tạo bừa thôi :anguished:
[6/25/2016, 12:39:57 AM] [rebyn]: nhiều người tức là @snacky phỏng
[6/25/2016, 2:24:49 AM] [huy]: :pac:
[6/25/2016, 2:25:13 AM] [huy]: đã cố dùng biện pháp nói giảm nói tránh rồi
[6/26/2016, 10:09:09 AM] [giangnh]: #til use YCM and Tern project.
[6/26/2016, 9:03:26 PM] []: #til class_eval to define instance method, instance_eval to define class method
[6/27/2016, 1:12:54 AM] []: #til Always link to original source of your code usage
[6/27/2016, 8:34:15 PM] [huy]: #til Facebook có chế độ navigate lên xuống bằng phím J và K của VIM :omg:
[6/27/2016, 8:34:38 PM] []: Có nhiều phím lắm đó
[6/27/2016, 8:35:13 PM] [huy]: vím nào nữa
[6/27/2016, 8:35:16 PM] [huy]: L là like rồi
[6/27/2016, 8:35:31 PM] [huy]: mới test thử trên Kipalog, ko có, chẹp
[6/27/2016, 8:36:40 PM] [huy]: @snacky: i said la dung vichrome di
[6/27/2016, 8:36:41 PM] [huy]: =.=
[6/27/2016, 8:36:48 PM] [huy]: nô
[6/27/2016, 8:36:55 PM] [huy]: đại khái là hồi trưa lên cơn
[6/27/2016, 8:37:00 PM] [huy]: bán con bàn phím ồi
[6/27/2016, 8:37:06 PM] [huy]: giờ switch qua dùng phím mac
[6/27/2016, 8:37:08 PM] [huy]: nhỏ vãi
[6/27/2016, 8:37:19 PM] [huy]: mà safari hêm có vichrome a @huydx
[6/27/2016, 8:37:27 PM] [huy]: co 1 cai na na do'
[6/27/2016, 8:37:31 PM] [huy]: ko thi build one
[6/27/2016, 8:37:32 PM] [huy]: say no to plugins
[6/27/2016, 8:37:42 PM] [huy]: giong anh qua
[6/27/2016, 8:37:47 PM] [huy]: a cung vua ban con realforce
[6/27/2016, 8:37:48 PM] [huy]: =)))
[6/27/2016, 8:37:51 PM] [huy]: =))))
[6/27/2016, 8:37:52 PM] [huy]: chuyen qua mac keyboard
[6/27/2016, 8:38:02 PM] [huy]: dùng tạm thôi
[6/27/2016, 8:38:13 PM] [huy]: đang theo thọ giáo @unrealhoang với ít bữa qua thọ giáo a <@U0GCPHQM7>
[6/27/2016, 8:38:15 PM] [huy]: build 1 em
[6/27/2016, 8:38:20 PM] [huy]: phải cr7 tơi scungf
[6/27/2016, 8:38:49 PM] [huy]: =.=
[6/27/2016, 8:40:00 PM] [huy]: twitter cũng có
[6/27/2016, 8:40:08 PM] [huy]: mỗi kipalog là ko có :troll:
[6/27/2016, 8:40:47 PM] [huy]: kipalog co vichrome roi a
[6/27/2016, 8:40:59 PM] [huy]: firefox co vimperator
[6/27/2016, 8:41:02 PM] [huy]: :v
[6/27/2016, 8:41:03 PM] [huy]: vimperator la god do'
[6/27/2016, 8:44:40 PM] [alias Trung.Le, as tle]: #random di may thim
[6/28/2016, 7:53:11 PM] [vien]: Dù sao thì vẫn phải tiến lên. Tìm con đường khác...
[6/29/2016, 5:48:26 PM] []: #til: iterm, tmux và vim đã hỗ trợ true color rồi :godmode:
[6/29/2016, 5:52:38 PM] [huy]: đó là thím thôi
[6/29/2016, 5:53:52 PM] []: (nghe đồn có người ko có true color nên gato)
[6/29/2016, 5:56:29 PM] []: #til: dùng axel để download max speed trong terminal
[6/29/2016, 6:43:23 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: #til: có thể dùng vimdiff như vầy để đỡ phải gõ lại full path `vimdiff /etc/nginx/{nginx.conf,<http://nginx.conf.org|nginx.conf.org>}`
[6/29/2016, 7:11:58 PM] [huy]: ^ :+1: có thể áp dụng cách tương tự cho những lệnh khác, ví dụ:
```
cp {.vimrc,.bashrc,.bash_profile,.tmux.conf,.profile,.zprofile,.zshrc} ./dotfiles
```
[6/29/2016, 7:12:41 PM] []: #til fancy git diff <http://nathanleclaire.com/blog/2016/06/28/on-the-matter-of-beautiful-git-diffs/> (thật ra là hôm qua)
[6/29/2016, 7:12:50 PM] []: `mv .env{.example,}`
[6/29/2016, 7:13:16 PM] [huy]: update chiêu này zô bài viết đi bác @xluffy
[6/29/2016, 7:13:24 PM] [huy]: dùng tiện phết
[6/29/2016, 9:35:57 PM] [tucq88]: fancy gitdiff hình như bây giờ dc integrate default trong bản git mới nhất thì phỉa
[6/29/2016, 9:36:12 PM] [tucq88]: hồi mới biết nó, hạnh phúc vãi, như là bê được github về term :v
[6/29/2016, 9:36:18 PM] []: Qua vẫn phải cài tay
[6/29/2016, 9:36:33 PM] [tucq88]: (y)
[7/3/2016, 3:11:56 AM] [giangnh]: How can I count the number of folders in a drive using Linux
```ls -lR | grep ^d | wc -l```
[7/5/2016, 2:36:05 AM] []: #til : Cherrio auto decode entities to HTML format, so `Xổ số` became `X&amp;#x1ED5; s&amp;#x1ED1;` in string value. Add `{decodeEntities: true}` option in `cherrio.load` to get `Xổ số`
[7/5/2016, 2:45:51 AM] [alias Trung.Le, as tle]: #til someone need to give our community a quick seminar on constructive debate
[7/5/2016, 6:52:24 PM] [jinhduong]: #til vui vẻ đẻ ra tiền, keep keep
[7/5/2016, 6:55:33 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: #til mẹo để làm việc hiểu quả là leave kênh <#C0TUQGY83> hoặc mute kênh đó :troll:
[7/5/2016, 7:02:21 PM] [huy]: @xluffy: đừng leave, để e kick ra cho
[7/5/2016, 10:41:14 PM] []: #til Câu hỏi phỏng vấn: 1+1 = ?
Trả lời: Tuỳ ý ngài
[7/5/2016, 11:07:55 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: 1+1=10 :troll:
[7/5/2016, 11:34:48 PM] [rebyn]: Trả lời: _I've enough of this :shit:._
[7/6/2016, 3:48:12 AM] [unrealhoang]: #til `fiasco` = complete failure [English]
[7/7/2016, 5:00:53 PM] [alias Trung.Le, as tle]: #til `jq` is good CLI tool for parsing json
[7/8/2016, 12:08:23 AM] []: #til
```
git log --since='last month' --pretty=format:'%h,%an,%ar,%s' &gt; log.csv
```
[7/8/2016, 12:54:44 AM] [anh bán chuối]: why &gt; log.csv :neutral_face:
[7/8/2016, 12:59:49 AM] []: @longkt90: Why not ?
[7/8/2016, 1:01:24 AM] [anh bán chuối]: I thought it should be `git log --since='last month' --pretty=format:'%h,%an,%ar,%s’ &gt;&gt; log.csv` :v
[7/8/2016, 1:02:22 AM] []: Yes :smile:
[7/8/2016, 1:25:02 AM] [tucq88]: just `&gt;` is ok, tested
[7/8/2016, 1:34:31 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: @tucq88: `&gt;` overwrite file, `&gt;&gt;` append file
[7/11/2016, 6:45:56 AM] []: #til The quality of the production code depends on the tests; but the quality of the tests does not depend on the production code.
[7/11/2016, 8:34:26 AM] [alias Trung.Le, as tle]: #til quality is a product of disciplines
[7/11/2016, 8:36:19 AM] []: @tle troll à a =))))
[7/11/2016, 3:54:16 PM] [alias Trung.Le, as tle]: no, it is entirely true in my exp
[7/11/2016, 4:27:15 PM] [alias Trung.Le, as tle]: #til I am pretty dumb in technical understanding compared to all great devs out there, I think the only I am good at is to be understand them quickly and know how to connect great devs together in constructive dialog
[7/11/2016, 4:40:57 PM] [huy]: #til 2 màn hình thì tăng productivity, 3 màn hình thì productivity bắt đầu đi xuống :facepalm:
[7/11/2016, 5:03:36 PM] [alias Trung.Le, as tle]: #til I think I believe in something called ‘faith’...
[7/11/2016, 9:02:43 PM] []: @tle What’re your `principles` ??
[7/11/2016, 11:30:31 PM] [alias Trung.Le, as tle]: #til changes is inevitable, embrace and adapt :neutral_face:
[7/12/2016, 6:42:21 PM] [alias Trung.Le, as tle]: @checkraiser: stick to what you are good at, keep up the par at all times, do not let it sink any inches, progressively and slowly raise the bar. Said easy than done. If it does not take disciplines, I don’t know what it take.
[7/12/2016, 7:01:20 PM] [huy]: :+1:
[7/12/2016, 7:01:46 PM] [alias Trung.Le, as tle]: #til setting up `AWS::AutoScaling::ScalingPolicy` with so low value of `Cooldown` could lead to _flapping_ issue
[7/12/2016, 7:19:42 PM] [n]: Cover all test cases with #permutation <http://blog.arkency.com/2016/06/cover-all-test-cases-with-permutation/>
[7/13/2016, 11:29:25 PM] []: #til Rails is Ruby, don’t make Ruby is Rails
[7/14/2016, 12:22:55 AM] [alias Trung.Le, as tle]: #til Pokemon GO is a portable version of <#C0TUQGY83>, productivity drops to the lowest level, I play, my colleagues and my bosses too...so so worrying
[7/14/2016, 1:29:11 AM] [tucq88]: #til be nice with people, especially your boss, when you're leaving. Even he is not nice with you
[7/15/2016, 3:25:05 AM] [unrealhoang]: #til use <https://github.com/buunguyen/octotree> for better github experience
[7/15/2016, 10:56:21 AM] [huynh.cam]: #til `String.blank?("I love Ruby")` đẹp hơn `"I love Ruby".blank?` ngàn lần
[7/15/2016, 11:05:58 AM] []: @hqc Co gi khac nhau dau :smile:
[7/15/2016, 11:13:36 AM] [huynh.cam]: khác chứ anh `"I love Ruby".blank?` là duck-typing mà
[7/16/2016, 8:02:33 AM] []: #til TDD costs much time, but it worths it
[7/19/2016, 11:21:53 AM] [tucq88]: #til I found it helpful to me <https://github.com/nvbn/thefuck>
[7/20/2016, 12:27:45 AM] [alias Trung.Le, as tle]: #til `Mutex.new`
[7/20/2016, 12:36:56 AM] [unrealhoang]: @tle: multi-threading in Ruby :scream:, how does it feel?
[7/20/2016, 12:37:20 AM] [alias Trung.Le, as tle]: @unrealhoang: it is so _green_ as :weed:
[7/20/2016, 12:37:46 AM] [unrealhoang]: lol, I see what you did there :notbad:
[7/20/2016, 12:42:50 AM] [huynh.cam]: #til `Mutex = Hell`
[7/21/2016, 8:47:40 PM] [huynh.cam]: #til OptionParser in Ruby
[7/21/2016, 8:47:58 PM] [huynh.cam]: #til <http://whatisthor.com|whatisthor.com>
[7/22/2016, 8:48:17 PM] []: #til `gem server` to view all installed gem of current machine in a webpage
[7/22/2016, 8:48:56 PM] [huy]: thực ra ý nghĩa của nó ko phải là vậy :lol:
[7/24/2016, 6:10:32 PM] [alias Trung.Le, as tle]: #til after a week of trial no music, I find myself in good productive mood all day long, I still put on my headphone (without playing music)
[7/25/2016, 7:06:35 AM] []: #til Good judgement is the result of experience ... Experience is the result of bad judgement.
[7/25/2016, 8:31:14 PM] [alias Trung.Le, as tle]: #til get the name of the current branch with `git rev-parse --abbrev-ref HEAD`
[7/25/2016, 8:37:44 PM] []: @tle Helpful trick :smile:
[7/25/2016, 8:38:17 PM] []: You can use it with `database.yml` to automatically switch database from branch
[7/25/2016, 8:38:20 PM] []: ```
test:
&lt;&lt;: *default
database: &lt;%= `git rev-parse --abbrev-ref HEAD`.gsub("\n",'') + "_dkxt_test" %&gt;
```
[7/26/2016, 3:21:09 AM] [tucq88]: @tle you could modify your bash to show the branch name close to current path. Someone already serve that <https://github.com/jimeh/git-aware-prompt>
[7/26/2016, 3:22:34 AM] []: simply use ohmyzsh for that
[7/26/2016, 3:22:50 AM] [alias Trung.Le, as tle]: yup
[7/26/2016, 3:23:03 AM] [alias Trung.Le, as tle]: ZSH... not for me
[7/26/2016, 3:23:10 AM] [tucq88]: @codeaholicguy: Can't get along with zsh. It's something that ... not for me
[7/26/2016, 3:23:10 AM] []: why not?
[7/26/2016, 3:23:24 AM] [tucq88]: but have you tried `fish shell` ?
[7/26/2016, 3:23:28 AM] [alias Trung.Le, as tle]: too bulky to load up
[7/26/2016, 3:23:37 AM] [alias Trung.Le, as tle]: fish shell?!
[7/26/2016, 3:23:40 AM] [tucq88]: yup
[7/26/2016, 3:23:46 AM] [tucq88]: pretty neat
[7/26/2016, 3:23:48 AM] [alias Trung.Le, as tle]: let me try
[7/26/2016, 3:24:02 AM] [tucq88]: <https://fishshell.com/>
[7/26/2016, 3:24:27 AM] [alias Trung.Le, as tle]: cheers
[7/26/2016, 3:24:31 AM] [tucq88]: I see it's pretty fast &amp; convenient . And simple
[7/26/2016, 3:24:55 AM] [alias Trung.Le, as tle]: shiny
[7/26/2016, 3:24:57 AM] [tucq88]: but somehow I'm just too old school to use it more than "normal" bash lol
[7/26/2016, 3:25:06 AM] [tucq88]: (y)
[7/26/2016, 3:26:45 AM] [unrealhoang]: @tle 1.5 seconds init time only :disappointed:
[7/26/2016, 3:27:06 AM] [unrealhoang]: @tle you will get plenty from it, it’s worth the trade I believe
[7/26/2016, 3:28:23 AM] [tucq88]: don't believe them @tle, zsh is a virus . I tried
[7/26/2016, 3:30:03 AM] []: virus, really?
[7/26/2016, 3:30:50 AM] []: lau lam ko dung shell hay zsh gi
[7/26/2016, 3:30:55 AM] []: toan choi terminal cua editor :v
[7/26/2016, 3:43:45 AM] []: Chắc mọi người xài oh my zsh nên bị cài tùm lum
[7/26/2016, 3:44:04 AM] []: Chứ bản thân zsh thì bình thường mà
[7/26/2016, 3:44:09 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: chuẩn rồi :smile:
[7/26/2016, 3:44:27 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: xài oh-my-zsh thì tiện, ko cần phải tìm hiểu gì, cài vào, đổi themes là xong
[7/26/2016, 3:44:44 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: bỏ oh-my-zsh đi, config từ đầu là đc :omg:
[7/26/2016, 3:45:17 AM] [unrealhoang]: xong ngồi keep-up với mấy cái command update
[7/26/2016, 3:45:25 AM] [unrealhoang]: no thanks
[7/26/2016, 3:45:30 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :smile:
[7/26/2016, 3:46:36 AM] []: Zpreztor nhá
[7/26/2016, 3:47:00 AM] []: Nhỏ gọn tiện lợi nhanh vèo vèo
[7/26/2016, 4:22:27 AM] []: ý @anhduy là prezto?
[7/26/2016, 4:22:32 AM] []: cũng base on zsh mà
[7/26/2016, 4:22:59 AM] []: Prezto, nó là config cho zsh thôi
[7/26/2016, 4:23:38 AM] []: Có phải shell khác đâu mà base on
[7/26/2016, 4:24:11 AM] []: ừ nhỉ
[7/26/2016, 4:24:46 AM] []: Zsh là xịn nhất rồi
[7/26/2016, 4:24:46 AM] []: :omg:
[7/26/2016, 4:25:23 AM] []: yes
[7/26/2016, 4:27:15 AM] []: <!here|@here> m.n quản lý time = tool gì vậy
[7/26/2016, 4:28:39 AM] [vinhnglx]: Google Calendar
[7/26/2016, 4:29:12 AM] []: Ví dụ mình cần log lại time cho 1 task/project
[7/26/2016, 4:29:18 AM] []: làm gì này nọ
[7/26/2016, 4:29:21 AM] []: export
[7/26/2016, 4:29:24 AM] []: là phải làm tay à
[7/26/2016, 4:29:29 AM] [vinhnglx]: oh
[7/26/2016, 4:29:46 AM] [vinhnglx]: the thi tuy muc dich cua ban nhi
[7/26/2016, 4:30:20 AM] [vinhnglx]: minh hay dung project tool, estimate theo point, sprint
[7/26/2016, 4:30:28 AM] [vinhnglx]: chu ko log time
[7/26/2016, 4:30:40 AM] [vinhnglx]: nghe hoi giong cham cong :troll:
[7/26/2016, 4:32:08 AM] [cangtt]: hiện tại ở cty đang sử dụng <http://Bitrix24.com|Bitrix24.com>, trong đó task có chức năng `Time Tracker`, có điều do nó có nhiều chức năng quá nên hơi chậm
[7/26/2016, 4:32:39 AM] []: :scream: track time thật à
[7/26/2016, 4:32:44 AM] []: :scream:
[7/26/2016, 4:33:42 AM] [cangtt]: còn ko thì có thể dùng Pomodoro Time (OSX App), để track là làm task đó bao nhiêu cái 25’ (bất tiện là chỉ làm tròn số lần 25’ với không note đc)
[7/26/2016, 4:34:23 AM] [cangtt]: @anhduy thật ra nó là cái ticker (bitrix24), khi mình start 1 task nào đó thì click để nó bắt đầu đếm, khi xong thì click 1 lần nữa để stop thôi :smile:
[7/26/2016, 4:34:36 AM] [cangtt]: quên stop thì coi như nó đếm suốt đời =))
[7/26/2016, 4:35:33 AM] []: À à
[7/26/2016, 4:36:39 AM] []: thật ra công sức 1 cú click ko lo, mệt là cái overhead phải note lại nó :)))
[7/26/2016, 4:37:22 AM] [crashbell]: @checkraiser: thử qua wakatime chưa? nó integrate vô sublime và atom để biết đang work trên project nào (code only). Còn dùng rescuetime thì biết rõ là spend time lên tool hoặc web nào :sexy:
[7/26/2016, 4:37:51 AM] []: @crashbell: OK, command line ha cau
[7/26/2016, 4:38:05 AM] [crashbell]: à không là app chạy background thôi :”&gt;
[7/26/2016, 4:38:14 AM] [cangtt]: wakatime chỉ log time thôi, ko có note
[7/26/2016, 4:38:51 AM] [crashbell]: <https://vietnamrb.slack.com/archives/til/p1469532552000072>
Theo mong muốn của bác @checkraiser thôi :slightly_smiling_face:
[7/26/2016, 4:39:30 AM] [cangtt]: rescuetime có thể log kìa, nhưng phải trả phí :smile:
[7/26/2016, 4:39:32 AM] []: :smile: , log time thì mặc định phải có note chứ, ko thì useless rồi (chưa tính export)
[7/26/2016, 4:39:35 AM] [cangtt]: <https://www.rescuetime.com/plans>
[7/26/2016, 4:39:53 AM] [unrealhoang]: Mình nghĩ mọi người nên move qua #general hay <#C0TUQGY83|random>
[7/26/2016, 4:40:16 AM] [unrealhoang]: Spam #til trôi hêt log mất
[7/26/2016, 5:29:41 AM] [anh bán chuối]: ko spam nó cũng trôi =))
[7/26/2016, 7:13:13 AM] []: vừa tải xong trial factorio rồi @unrealhoang
[7/26/2016, 7:13:15 AM] []: :omg:
[7/26/2016, 7:13:27 AM] [unrealhoang]: :omg:
[7/26/2016, 7:13:43 AM] []: qua #game nhe’ may’ thim'
[7/27/2016, 1:39:25 AM] [tucq88]: @codeaholicguy: troll vu zsh virus thoi ma :smile: zsh ngon, chi la minh thay no roi ram kho' dung qua :smile:
[7/27/2016, 2:29:31 AM] [minh.nguyen]: #til Trying to do things you don't know without embarrassing is the fastest way to enlarge your knowledge
[7/27/2016, 2:35:33 AM] []: #til Prefering endeep to enlarge is the fastest way to enhance your knowledge
[7/27/2016, 9:48:30 PM] [alias Trung.Le, as tle]: #til always be humble, be listening and you will be surprised how much you would learn and grow :wink:
[7/27/2016, 10:43:30 PM] [huynh.cam]: #til never rely on Github
[7/27/2016, 10:52:55 PM] [alias Trung.Le, as tle]: #til GitHub is human-made product, human always make mistake but human is forgiving kind :wink:
[7/28/2016, 1:39:14 AM] [huy]: #til : lam 1 cai protype that nhanh va that shit, sau do dap di lam lai
[7/28/2016, 1:39:24 AM] [huy]: cai tiep theo se rat dep ca ve mat domain lan architecture
[7/28/2016, 1:39:34 AM] [huy]: (ap dung cho moi san pham software)
[7/28/2016, 1:39:49 AM] [tucq88]: @huydx true story
[7/28/2016, 1:40:09 AM] [huy]: co ma ko code nhanh dc thi dung lam theo
[7/28/2016, 1:40:10 AM] [huy]: :v
[7/28/2016, 1:40:44 AM] []: #til Learning by making shit ASAP :))
[7/28/2016, 1:42:00 AM] [tucq88]: thật ra là build MVP trước, chạy lấy feedback
[7/28/2016, 1:42:15 AM] [tucq88]: rồi 1 là improve, 2 là build lại cho phù hợp feedback :smile:
[7/28/2016, 1:56:34 AM] [huynh.cam]: #til learned from @huydx, startup developers have a tendency of writing shit code
[7/28/2016, 1:57:52 AM] [huy]: @hqc: nham voi huydx a :neutral_face:
[7/28/2016, 1:58:10 AM] [huynh.cam]: @huydx: lộn =]]]]
[7/28/2016, 1:58:42 AM] [alias Trung.Le, as tle]: #til without discipline anything could become the next <#C0TUQGY83>
[7/28/2016, 7:33:45 AM] []: #til Even with discipline, we always have exceptions
[7/28/2016, 12:46:28 PM] [huy]: #tir For programmers who are used to writing `for` loops, recursion can be confusing
[7/28/2016, 6:51:06 PM] [alias Trung.Le, as tle]: #til With discpline, one should never forget to handle exception unless you are a believer of fail fast
[7/28/2016, 9:33:56 PM] [alias Trung.Le, as tle]: #til `docker run --restart=unless-stopped` see? I could do devops
[7/28/2016, 11:20:11 PM] []: #til Naming tells more about you than your program
[7/29/2016, 12:00:28 AM] [huynh.cam]: @khanhdang: bạn qua #general hỏi nhé
[8/6/2016, 9:58:47 AM] [unrealhoang]: #til Ruby’s Thread by default will not throw exception on error/failure
[8/6/2016, 10:01:47 AM] [unrealhoang]: We can config it to throw error:
```
t = Thread.new do
long_running;
end
t.abort_on_exception = true
```
[8/6/2016, 7:49:59 PM] [unrealhoang]: #til You can use `C-x C-e` to edit your current bash command in your $EDITOR @anhduy <@U0GECN1NH>
[8/6/2016, 9:01:28 PM] []: Nên đọc cái readline
[8/6/2016, 9:01:37 PM] []: Đi từ cái đó ra hết đó
[8/6/2016, 9:18:13 PM] [huy]: @unrealhoang: edit làm sao :thinking_face:
[8/6/2016, 11:30:06 PM] [unrealhoang]: @snacky: thì nó mở vim lên rồi chỉnh sửa gì đó
[8/6/2016, 11:30:30 PM] [unrealhoang]: Khi muốn chạy thì `:wq` thôi
[8/7/2016, 12:24:06 AM] [huy]: sửa gì á :v
[8/7/2016, 12:24:19 AM] [huy]: edit your current bash command
[8/7/2016, 12:24:21 AM] [huy]: what is it :disappointed:
[8/7/2016, 12:27:01 AM] [unrealhoang]: Ặc. Ý là khi mà gõ 1 lệnh dài mà sai ở đâu đó muốn sửa thì dùng `C-x C-e` đó
[8/7/2016, 12:30:11 AM] [huy]: à à à
[8/7/2016, 12:30:22 AM] [huy]: móa, tưởng đâu sửa đc source của bash command luôn chớ :v
[8/10/2016, 12:45:47 AM] [alias Trung.Le, as tle]: @#til the 20:80 rules, 20% customers would buy 80% of your products
[8/14/2016, 6:54:43 PM] [huy]: #til khi cảm thấy có quá nhiều việc mà không biết nên làm gì trước thì nên đi tắm trước :v
[8/14/2016, 7:05:57 PM] [unrealhoang]: thế đi tắm cả ngày à :omg:
[8/14/2016, 7:06:56 PM] [huy]: :omg:
[8/15/2016, 8:55:35 PM] [mido]: #til mock một hàm trong RSpec và set hàm này trả ra output theo thứ tự định sẵn.
<https://relishapp.com/rspec/rspec-mocks/v/3-3/docs/configuring-responses/returning-a-value#specify-different-return-values-for-multiple-calls>
[8/16/2016, 2:00:29 AM] [tucq88]: #til Đợt vừa bên Laravel PHP mới có conf, có bài talk khá hay của Sandi Metz, hope ae enjoy
<https://streamacon.com/video/laracon-us/sandi-metz-get-a-whiff-of-this>
[8/16/2016, 2:15:57 AM] []: Hôm nọ có nói bên general quá trời mà :omg:
[8/16/2016, 10:11:24 PM] [tucq88]: @anhduy the a :smile:
[8/16/2016, 10:11:35 PM] [tucq88]: PHP gay tieng vang, hi' hi'
[8/16/2016, 10:30:19 PM] []: Bà đó nói trong rails conf mà
[8/16/2016, 10:30:25 PM] []: Liên quan gì php đâu
[8/16/2016, 10:30:28 PM] []: :trollface:
[8/17/2016, 9:16:13 AM] [huynh.cam]: #til `100.lần { “Explicit over Implicit” }`
[8/17/2016, 10:29:43 AM] [huy]: thanh niên chép phạt của năm
[8/17/2016, 9:27:50 PM] [alias Trung.Le, as tle]: #til Varnish - set object TTL in `vcl_fetch() - beresp.ttl`
[8/19/2016, 5:03:24 AM] [tucq88]: #til MySQL - Rows to Columns <http://stackoverflow.com/a/9668036/1113103?stw=2>
[8/19/2016, 11:16:15 PM] [huynh.cam]: #til `ActiveRecord.none`
[8/24/2016, 2:18:50 AM] [alias Trung.Le, as tle]: #til commitment is hardcore
[8/24/2016, 9:21:09 AM] [tucq88]: #til Danang is conquered by Chinese
[8/24/2016, 11:22:23 AM] [huy]: lol...
[8/24/2016, 11:22:27 AM] [huy]: really? @tucq88
[8/24/2016, 6:57:15 PM] []: Nha Trang, too
[8/26/2016, 1:03:33 AM] [giangnh]: In Rust `'.'` has type `char` and `"."` has type `&amp;'static str`
[8/30/2016, 10:42:33 AM] [giangnh]: ```On HTTP 1.0/1.1 connections, Chrome enforces a maximum of six TCP connections per host```
[8/30/2016, 6:00:11 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :+1: mỗi trình duyệt có 1 con số khác nhau nhé
[8/30/2016, 7:25:10 PM] [giangnh]: ```Domain sharding is a technique for splitting resources across multiple domains, improving page load time and search engine visibility```
[8/30/2016, 7:26:33 PM] [alias Trung.Le, as tle]: indeed
[8/30/2016, 7:27:32 PM] [huy]: no goi la domain load balancing
[8/30/2016, 7:50:57 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: bởi vậy nên nếu để ý mấy trang như fb, flickr static như img, js, css tụi nó luôn có 1 cái domain khác ko liên quan , kiểu `<http://scontent-sit4-1.xx.fbcdn.net|scontent-sit4-1.xx.fbcdn.net>`
[8/30/2016, 7:52:36 PM] [giangnh]: mới đọc bài trên maxcdn mới biết thêm về vụ này :slightly_smiling_face:
[9/2/2016, 11:53:16 PM] [n]: <https://makandracards.com/makandra/1659-use-a-ruby-method-like-a-block-or-lambda>
[9/2/2016, 11:58:43 PM] [huy]: <https://twitter.com/rakyll/status/771957992417820672>
[9/3/2016, 2:44:17 AM] []: y chang cái hôm bữa e nói =))
[9/3/2016, 2:44:23 AM] []: thanh niên này giống e
[9/3/2016, 3:35:06 AM] [n]: lol
[9/4/2016, 7:38:36 PM] [tucq88]: when you "bí" message à :smile:
[9/5/2016, 7:40:47 PM] [giangnh]: ```The two most important Days of your Life are the day you are born, and the day you find out why.........```
[9/5/2016, 11:01:56 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: #til: tmux broadcast `:setw synchronize-panes`
[9/6/2016, 12:17:28 AM] [alias Trung.Le, as tle]: #til `Hash#dig` can traverse array!!
```
h = { foo: { array: [{ bar: 'foobar' }] }
h.dig(:foo, :array, 0, :bar) == 'foobar'
```
[9/6/2016, 1:40:03 AM] [huy]: #til you can use `disown` instead of `nohup` to run background process
[9/6/2016, 1:40:59 AM] [huy]: difference is that disown run `after` process is ran, and nohup run `before`
[9/6/2016, 1:42:00 AM] [huy]: @xluffy biet cai tren k em
[9/6/2016, 1:44:33 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: em biết nohup thôi anh, cơ mà em ko thích nó lắm :smile:
[9/6/2016, 1:45:26 AM] [huy]: the thi e co the dung disown
[9/6/2016, 1:45:27 AM] [huy]: =)))
[9/6/2016, 1:45:33 AM] [huy]: ai ghet nohup thi dung disown
[9/6/2016, 1:45:39 AM] [huy]: ko bi nohup log file
[9/6/2016, 1:53:26 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: ý là em ko thích cái kiểu chạy bg của nohup í, chứ ko phải vụ log
[9/6/2016, 1:53:36 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: ví dụ cần restart `kill -15/-9 xxx`
[9/6/2016, 1:53:40 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: xong lại nohup
[9/6/2016, 1:58:14 AM] [huy]: thi do'
[9/6/2016, 1:58:19 AM] [huy]: the nen moi dung disown di
[9/6/2016, 1:58:23 AM] [huy]: e hay dung cai gi de chay daemon
[9/6/2016, 1:58:49 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: tự viết script systemv hoặc systemd anh :smile:
[9/6/2016, 1:58:59 AM] [huy]: systemd a`
[9/6/2016, 1:59:00 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: nó có cú pháp mà
[9/6/2016, 1:59:05 AM] [huy]: hmm
[9/6/2016, 1:59:07 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: nếu dùng centos7 thì systemd
[9/6/2016, 2:34:40 AM] [giangnh]: #til: `window.navigator.hardwareConcurrency` returns the number of logical processors available to run threads on the user's computer.
[9/7/2016, 9:19:10 PM] [alias Trung.Le, as tle]: #til NodeJS is :shit: for backend app
[9/9/2016, 3:14:25 AM] []: #til you will meet with thousands of trade offs every day and you must learn how to deal with it. Inline style with React is great till you come with some complex animation, you will only want to scream f***.
[9/9/2016, 10:31:41 AM] [huy]: @codeaholicguy inline style is never been a good solution on the web, not before or after React
[9/9/2016, 10:32:55 AM] []: :joy:
[9/11/2016, 1:38:46 AM] [rebyn]: inline styling is good for mails bruv
[9/11/2016, 4:00:32 PM] [alias Trung.Le, as tle]: @rebyn it just shows how out of touch mail templating standard is
[9/11/2016, 7:40:52 PM] [rebyn]: @tle sure? they are 2 things to me though. liquid is cool and fun, and inline styling is a performance thing. inline does it better than css files.
[9/11/2016, 7:46:15 PM] [huy]: #til email is the bad... no... the worst thing ever invented
[9/11/2016, 7:47:22 PM] [rebyn]: #til it's the best thing :full_moon_with_face:
[9/11/2016, 7:48:05 PM] [huy]: you can have multiple ( around 20 ) email thread, talking about the same thing
[9/11/2016, 7:48:06 PM] [huy]: lollllll
[9/11/2016, 7:51:09 PM] [rebyn]: it's a human thing
[9/11/2016, 7:51:12 PM] [rebyn]: not an email thing
[9/11/2016, 7:51:15 PM] [rebyn]: you're not doing emails right bruv
[9/11/2016, 7:52:30 PM] [unrealhoang]: @rebyn <@U0GECN1NH> please move to #random for your argument
[9/14/2016, 12:56:42 AM] [giangnh]: Rust: ```The conventional lifetime specifier is 'a. I do not know why that was picked, but let’s go with that```
[9/14/2016, 5:36:59 AM] [huy]: mới biết trò này
[9/14/2016, 5:59:35 AM] [alias Trung.Le, as tle]: :smile:
[9/14/2016, 5:59:46 AM] [alias Trung.Le, as tle]: cái đó lợi hại thật
[9/14/2016, 9:12:28 AM] []: #til use `git reflog` to see what you did in `git`, when you deleted wrong branch that you did not want to, use `git branch branchName &lt;sha1&gt;` from `git reflog`, it saved my day
[9/15/2016, 11:05:21 PM] [alias Trung.Le, as tle]: #til UNIX `trap` command
[9/15/2016, 11:05:22 PM] [alias Trung.Le, as tle]: oh yah
[9/15/2016, 11:06:48 PM] [alias Trung.Le, as tle]: `kill -l` to list out all signals
[9/15/2016, 11:12:43 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: có 1 bài post trene kipalog á anh :smile:
[9/15/2016, 11:13:07 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: <http://kipalog.com/posts/shell--trap--la-gi--for-shell-beginner>
[9/17/2016, 3:01:50 PM] [tan.duong]: ```Since scroll events can fire at a high rate, the event handler shouldn't execute computationally expensive operations such as DOM modifications. Instead, it is recommended to throttle the event using requestAnimationFrame, setTimeout or customEvent.```
<https://developer.mozilla.org/en-US/docs/Web/Events/scroll>
[9/17/2016, 3:12:19 PM] [huy]: Thực ra setTimeout cũng hơi bị cosy đấy. Tốt nhất là debounce hoặc throttle
[9/17/2016, 3:12:56 PM] [huy]: *high cost
[9/18/2016, 1:59:53 AM] [anh bán chuối]: ```
The term Third World arose during the Cold War to define countries that remained non-aligned with either NATO, or the Communist Bloc. The United States, Western European nations and their allies represented the First World, while the Soviet Union, China, Cuba, and their allies represented the Second World.
```
[9/18/2016, 12:20:37 PM] [huy]: &gt; Never hold back anything from the past if it's not your anymore
[9/18/2016, 1:10:54 PM] [tan.duong]: @snacky setTimeout nói tới ở đây chính là debounce đấy. Nếu ko phải debounce thì setTimeout làm gì :wink:
[9/18/2016, 7:24:51 PM] [anh bán chuối]: la sao @snacky
[9/18/2016, 7:24:57 PM] [anh bán chuối]: vd nhu cai gi :smile:
[9/18/2016, 10:16:13 PM] [alias Trung.Le, as tle]: #til responsive is the key to sales success
[9/18/2016, 10:16:48 PM] [alias Trung.Le, as tle]: #til I am now turning into a salesman, a bit worried, but it is an essential skill for any startup founder :disappointed:
[9/18/2016, 10:22:35 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :pac: bán themes dạo hả anh?
[9/18/2016, 10:23:37 PM] [alias Trung.Le, as tle]: qua #random nhé
[9/18/2016, 10:32:25 PM] [huynh.cam]: #til perfectionism kills productivity
[9/18/2016, 11:15:07 PM] [alias Trung.Le, as tle]: #til <https://developers.google.com/analytics/devguides/collection/analyticsjs/cross-domain>
[9/19/2016, 12:50:02 AM] [alias Trung.Le, as tle]: #til vocal warm up <https://youtu.be/Q5hS7eukUbQ>
[9/20/2016, 3:29:00 PM] []: #til `brew unlink $(brew list); brew link $(brew list)`
[9/20/2016, 7:32:56 PM] [giangnh]: #til: The `URLSearchParams` interface defines utility methods to work with the query string of a URL.
[9/20/2016, 7:33:01 PM] [giangnh]: <https://developer.mozilla.org/en-US/docs/Web/API/URLSearchParams>
[9/20/2016, 7:37:36 PM] [huy]: #til take notes everyday about stuff/bug/fixes/tricks you did :thinking_face:
[9/20/2016, 7:38:04 PM] [huy]: #til take note vao kipalog TIL nha
[9/20/2016, 7:39:05 PM] [huy]: ko phải cái gì cũng free đâu nha :troll:
[9/20/2016, 11:39:22 PM] [alias Trung.Le, as tle]: #til i am getting old..not happy...
[9/28/2016, 1:02:40 AM] [alias Trung.Le, as tle]: #til I learn about `onEnter` hook of `&lt;Match&gt;` component of `react-router` and again it feels weird that SPA app has server side delegate the routing to react-router too :disappointed:
[9/28/2016, 8:58:53 PM] [giangnh]: #til convert from `String` to `&amp;str` : `string.as_str()`, `&amp;str` to `String`: `str.to_string()`
[9/29/2016, 2:06:56 AM] [huynh.cam]: #til `retry` keyword in Ruby
[9/29/2016, 7:28:20 PM] [rebyn]: #til you don't know your unknowns :expressionless:
[10/3/2016, 7:22:54 PM] [alias Trung.Le, as tle]: well #til this
[10/3/2016, 7:22:56 PM] [alias Trung.Le, as tle]: &gt; This is a critical difference between CommonJS modules and ECMAScript modules because while exports of a CommonJS module are defined dynamically while the wrapper function is being evaluated, the exports of an ESM are defined lexically. That is, the symbols exported by an ESM are determined when the JavaScript code is being parsed before it is actually evaluated.
[10/6/2016, 12:04:34 AM] [lucdang]: Helper methods often aren’t tested even when they contain significant amounts of logic.
[10/10/2016, 1:03:40 AM] [tucq88]: #til linux tricks | Add `-X` if you want to list order in type /. E.g : `ls -X` or `ls -lahX`
[10/10/2016, 6:15:35 PM] [alias Trung.Le, as tle]: Whenever I upgrade OSX, I have to do `rm -rf ~/.rbenv/`
[10/10/2016, 8:18:52 PM] [rebyn]: If you log in to a WIFI on your phone you don't need to log in again on your Mac. Sorcery.
[10/10/2016, 8:28:56 PM] [tucq88]: @rebyn You have to sync your laptop first, I think :-?
[10/10/2016, 8:46:27 PM] [minh.nguyen]: @rebyn The same happens with my Mac and my iPad. I logged in Wifi on my Mac, then my ipad connects to the Wifi automatically
[10/10/2016, 9:08:49 PM] [anh bán chuối]: You cannot view your entered wifi password on your iphone but can see it by using your mac’s keychain :smile:
[10/10/2016, 9:10:31 PM] [tucq88]: <https://github.com/rauchg/wifi-password>
[10/10/2016, 9:51:34 PM] [tay vịn của anh bán chuối - cty A tìm FE]: @tucq88 full features mac-cli <https://github.com/guarinogabriel/Mac-CLI>
[10/10/2016, 11:48:37 PM] [tucq88]: #til There's a University that teach you to apply to Google <https://github.com/jwasham/google-interview-university>
[10/11/2016, 8:15:51 AM] [huynh.cam]: #til <http://dba.stackexchange.com/questions/6051/what-is-the-default-order-of-records-for-a-select-statement-in-mysql>
[10/16/2016, 5:58:10 PM] [alias Trung.Le, as tle]: #til In rails 4.2 headers (which are of class
`ActionDispatch::Http::Headers`) do not respond to the `keys` method, we
must first convert them to a hash to grab the keys.
[10/17/2016, 4:41:12 AM] [unrealhoang]: vim command:
```
:v/pattern/d =&gt; remove everything but the lines that match pattern
:g/pattern/d =&gt; keeps everything but the lines that match pattern
```
[10/17/2016, 9:04:09 PM] [minh.nguyen]: #til It is better to read the documents of all versions carefully before wasting many hours implementing some plugins for a gem to avoid the case that the author of the gem implemented exactly the same as you do in a newer version :rip:
[10/17/2016, 9:24:03 PM] []: :rip:
[10/17/2016, 9:24:07 PM] []: :rofl:
[10/18/2016, 9:35:26 PM] [huynh.cam]: #til `puts a.inspect` over `p a`
[10/18/2016, 11:16:46 PM] [alias Trung.Le, as tle]: nah
[10/18/2016, 11:16:50 PM] [alias Trung.Le, as tle]: do `pp a`
[10/18/2016, 11:16:51 PM] [alias Trung.Le, as tle]: lol
[10/18/2016, 11:20:41 PM] [minh.nguyen]: `aw a`
[10/19/2016, 12:34:37 AM] [alias Trung.Le, as tle]: ap chứ
[10/19/2016, 12:35:06 AM] [minh.nguyen]: Oops. `ap` :stuck_out_tongue:
[10/19/2016, 9:49:01 PM] [manhdv]: #til
Không nên tạo 1 partition có dung lượng bằng dung lượng của 1 partition có sẵn, tránh việc install đè nhầm lên partition có sẵn đó :disappointed:
Hơi bị đau lòng.
[10/19/2016, 11:47:25 PM] [alias Trung.Le, as tle]: #til maintaining a positive thinking
[10/20/2016, 2:01:00 AM] [rebyn]: ^ will only make it worse in the end. Be realistic.
[10/20/2016, 1:51:06 PM] [huy]: #til Developer's life is a sine wave, sometimes you look at your code and just want to jump off the bridge, then you go home, have a terrible nightmare, and you wake up with all the bugs fixed, magically...
[10/20/2016, 7:44:57 PM] [rebyn]: <http://images-cdn.9gag.com/photo/anYZ9Eo_700b.jpg>
[10/21/2016, 7:55:20 AM] [anh bán chuối]: `kill -TTIN sidekiq_pid` :smile:
[10/22/2016, 9:48:41 PM] [alias Trung.Le, as tle]: @rebyn has mastered 'em all! Lol
[10/24/2016, 1:06:47 AM] [tucq88]: #til `git branch -va` - so all branches with latest commit ./ `-v` option does the trick.
This is pretty useful when you want to quick verify process of other branches
[10/24/2016, 2:34:37 AM] [vien]: Read carefully all documents :disappointed:
[10/24/2016, 2:36:41 AM] [cangtt]: ^ even the template's (theme) document
[10/24/2016, 3:13:06 AM] [manhdv]: Design pattern in category:
<https://sourcemaking.com/design_patterns>
[10/25/2016, 10:26:32 PM] [tay vịn của anh bán chuối - cty A tìm FE]: If you do not want to apply opacity to child elements, like in our example above, use RGBA color values.
[10/25/2016, 10:26:47 PM] [tay vịn của anh bán chuối - cty A tìm FE]: CSS
[10/25/2016, 11:44:53 PM] [alias Trung.Le, as tle]: #til readline hot shortcuts <http://readline.kablamo.org/emacs.html>
[10/26/2016, 6:36:05 PM] [huy]: #til usage of `pushd`, `popd`
[10/26/2016, 6:44:37 PM] [alias Trung.Le, as tle]: @huydx em có biết vụ `-` luôn không
[10/26/2016, 6:44:55 PM] [alias Trung.Le, as tle]: `cd -` để quay về directory cũ ở trước trong history
[10/26/2016, 6:45:01 PM] [huy]: ah cai do e biet
[10/26/2016, 6:45:27 PM] [huy]: neu dung zsh thi khi an `cd -` va tab thi no se autocomplete voi N entries from history
[10/26/2016, 6:45:46 PM] [alias Trung.Le, as tle]: uhm
[10/26/2016, 6:45:59 PM] [alias Trung.Le, as tle]: chiêu đó anh thấy quá tiện
[10/26/2016, 6:49:36 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: có 1 mẹo như vầy nữa
```
ls /var/log/nginx
cd $_
pwd
```
[10/26/2016, 6:49:38 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :smile:
[10/26/2016, 11:34:07 PM] [unrealhoang]: #til Ruby’s Array’s `bsearch`
[10/27/2016, 12:39:03 AM] []: #til View rails routes : <http://localhost:3000/rails/info/routes>
[10/27/2016, 12:39:35 AM] [tucq88]: This site can’t be reached :disappointed:
[10/27/2016, 12:39:44 AM] [tucq88]: why it doesn't work on my computer
[10/27/2016, 12:41:18 AM] []: @tucq88 Anh chạy server rails trên local ý anh. Thì mới view thấy ạ
[10/27/2016, 12:41:59 AM] [giangnh]: thấy bên laravel có `php artisan routes`
[10/27/2016, 12:42:12 AM] [tucq88]: @giangnh ;;)
[10/27/2016, 12:42:23 AM] [tucq88]: nhưng laravel ko có `rails console`
[10/27/2016, 12:42:33 AM] [tucq88]: @haond thanks for the tip :+1:
[10/27/2016, 12:44:01 AM] [hoanghiep90]: Laravel có `php artisan tinker`. Issue của bạn thử clear cache or chạy trình duyệt ẩn danh xem :disappointed:
[10/27/2016, 12:45:06 AM] [huy]: <https://vietnamrb.slack.com/archives/til/p1477554143000215> cái này a xoá cache 7 lần rồi f5 thêm 5 lần nữa nhé. Là sẽ thấy nó ko có thật đâu
[10/27/2016, 12:45:42 AM] [tucq88]: @snacky :rage:
[10/27/2016, 1:11:51 AM] [minh.nguyen]: @haond đây là link xem routes của mình: <http://localhost:3000/adshgkashdglkahskldg>
[10/27/2016, 1:11:52 AM] [minh.nguyen]: :smile:
[10/27/2016, 1:13:03 AM] []: @nguyenquangminh Có thấy gì đâu :smile:
[10/27/2016, 1:16:49 AM] []: :lol:
[10/27/2016, 1:20:05 AM] [giangnh]: chet lo cty kia
[10/27/2016, 1:21:19 AM] [huy]: :lol:
[10/27/2016, 1:27:25 AM] [giangnh]: không chơi với mấy thim intellji
[10/27/2016, 1:27:26 AM] [giangnh]: =))
[10/27/2016, 1:27:46 AM] [tucq88]: hay ma :3
[10/27/2016, 1:29:00 AM] []: Matz khuyên ko cần IDE
[10/27/2016, 1:29:17 AM] []: HDD cũng vậy lun :troll:
[10/27/2016, 1:33:01 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: HDD là ai thế :troll:
[10/27/2016, 1:34:01 AM] []: Là bác ổ cứng, bà con với bác SSD :troll:
[10/27/2016, 1:38:44 AM] [lucdang]: sung sướng ko muốn, chi cực dzậy
[10/27/2016, 1:38:59 AM] [lucdang]: Giang ca ca @giangnh :troll:
[10/27/2016, 1:39:08 AM] [giangnh]: qua #random di
[10/27/2016, 6:58:35 PM] []: #til Load classes from extend folder ```config.autoload_paths &lt;&lt; "#{Rails.root}/extend"```
[10/27/2016, 9:47:35 PM] [kimhieu]: Tùy ngôn ngữ thôi
[10/27/2016, 9:47:43 PM] [kimhieu]: Thông dịch ko cần IDE
[10/27/2016, 9:47:47 PM] [kimhieu]: Biên dịch thì nên có IDE
[10/27/2016, 9:47:59 PM] [kimhieu]: VD như C++ hay Java ko có IDE hơi khó code
[10/27/2016, 9:48:12 PM] [kimhieu]: Còn `scripting language` cứ thế mà táng
[10/30/2016, 11:21:11 PM] [trexnix]: #til Dùng `tee` để ghi stream ra đồng thời `stdout` và 1 hay nhiều file khác.
Vd: *cat file1 file2 | tee file3*
[11/1/2016, 5:52:19 PM] [alias Trung.Le, as tle]: nice ^
[11/1/2016, 10:01:34 PM] [alias Trung.Le, as tle]: #til `enum_for` - lazy version of `to_enum`
[11/1/2016, 10:01:35 PM] [alias Trung.Le, as tle]: :smile:
[11/2/2016, 3:16:55 AM] [toanha]: #til `style="white-space: pre-line”`
[11/2/2016, 3:18:46 AM] [manhdv]: @tle #til của vụ drop index ra lò chưa anh ơi? cho em hóng với.
[11/3/2016, 12:46:50 AM] [anh bán chuối]: vẫn hóng anh @tle
[11/3/2016, 2:01:16 AM] [cangtt]: #til PHP = Phillipines Pesos :troll:
[11/3/2016, 7:45:21 PM] [tucq88]: #til Nginx, you have to config `listen :80 default_server;` if you want to point your local `127.0.0.1` to a default host
[11/3/2016, 8:41:04 PM] [alias Trung.Le, as tle]: @manhdv issue hôm nọ là `remove_index` không đc wrap trong LHM
[11/3/2016, 9:05:07 PM] [manhdv]: @tle có phải cái lhm của tụi soundcloud đó hả anh?
[11/3/2016, 9:08:53 PM] [alias Trung.Le, as tle]: yup
[11/4/2016, 1:49:57 AM] [alias Trung.Le, as tle]: #til interview submission is so poor when AR is the only god they worship
[11/4/2016, 1:50:50 AM] []: :omg:
[11/4/2016, 1:51:22 AM] [alias Trung.Le, as tle]: It is true...
[11/4/2016, 1:51:29 AM] [alias Trung.Le, as tle]: :weight_lifter:‍♀️
[11/4/2016, 1:51:35 AM] [unrealhoang]: :dhh:
[11/4/2016, 1:51:43 AM] [alias Trung.Le, as tle]: Sa mạc lời
[11/4/2016, 1:52:08 AM] [alias Trung.Le, as tle]: Không cần péistence mà các thánh nộp vẫn táng
[11/4/2016, 1:52:17 AM] [alias Trung.Le, as tle]: Hỏi sao không active_model
[11/4/2016, 1:52:23 AM] [alias Trung.Le, as tle]: Thì không giải thích đc
[11/4/2016, 1:52:29 AM] [unrealhoang]: lỡ người ta xài raw sql
[11/4/2016, 1:52:34 AM] [unrealhoang]: :omg:
[11/4/2016, 1:52:46 AM] [alias Trung.Le, as tle]: Bài không cần đụng đến AR luôn
[11/4/2016, 1:52:59 AM] [alias Trung.Le, as tle]: Hỏi ra chỉ biết Rails
[11/4/2016, 1:53:04 AM] [alias Trung.Le, as tle]: Không biết Ruby
[11/4/2016, 1:53:17 AM] [alias Trung.Le, as tle]: Nà nàm thao
[11/4/2016, 1:53:32 AM] [unrealhoang]: typical Rails developer
[11/4/2016, 1:53:33 AM] [unrealhoang]: :smile:
[11/4/2016, 1:53:47 AM] [alias Trung.Le, as tle]: :thinking_face:
[11/4/2016, 1:54:11 AM] [alias Trung.Le, as tle]: Hổ thêm SRP
[11/4/2016, 1:54:27 AM] [alias Trung.Le, as tle]: Bác ấy nói AR là điển hình
[11/4/2016, 1:54:29 AM] [alias Trung.Le, as tle]: Hả
[11/4/2016, 1:54:38 AM] [alias Trung.Le, as tle]: Mình chỉ biết câm nín
[11/4/2016, 1:54:41 AM] [unrealhoang]: wow
[11/4/2016, 1:54:45 AM] [unrealhoang]: :doge:
[11/4/2016, 1:55:08 AM] [alias Trung.Le, as tle]: Không biết nhưng tỏ ra rất nguy hiểm
[11/4/2016, 1:55:19 AM] [unrealhoang]: có chí khí
[11/4/2016, 1:55:21 AM] [unrealhoang]: :notbad:
[11/4/2016, 1:55:39 AM] [alias Trung.Le, as tle]: Yeah
[11/4/2016, 1:55:51 AM] [alias Trung.Le, as tle]: Dân mộ đạo
[11/4/2016, 1:55:56 AM] [alias Trung.Le, as tle]: Niềm tin mãnh liệt
[11/4/2016, 1:56:00 AM] [alias Trung.Le, as tle]: :troll:
[11/7/2016, 1:02:52 AM] []: #til
- Get current file migrate ```rake db:version```
- Get status migrate ```rake db:migrate:status```
[11/7/2016, 1:12:28 AM] []: Migrate single file : ```rake db:migrate:up VERSION=20161107085430```
[11/7/2016, 5:53:05 AM] [pmint93]: #til that create a model with field name `method` make me crazy when i want to make change to a field whenever another field value presence
Example:
Whenever a `Payment` succedded with `status: 'success'`, i would like to `method(:succedded_at=).call(Time.zone.now)`
But, i have to:
```
Payment.instance_method(:method).bind(self).super_method.call(:succedded_at=).call(Time.zone.now)
```
Fortunately, i can compact it to
```
self.class.instance_method(:succedded_at=).bind(self).call(Time.zone.now)
```
:v
[11/7/2016, 3:49:13 PM] [alias Trung.Le, as tle]: #til has anyone ever DB migration rollback on prod? :troll:
[11/7/2016, 4:52:47 PM] [manhdv]: ^ that should be a critical mistake of product owner.
how can code control with new data that has been removed/added?
[11/7/2016, 4:53:21 PM] [manhdv]: @tle please share your case :heart:
[11/7/2016, 4:54:11 PM] [alias Trung.Le, as tle]: “One never touch data in db migration” said the wise
[11/7/2016, 4:55:16 PM] [manhdv]: so, what did you do on migration? :smile:
[11/7/2016, 5:48:29 PM] [alias Trung.Le, as tle]: schema structure only
[11/7/2016, 6:46:59 PM] [anh bán chuối]: @tle then how do you sync the data betweens developers and other environments like staging - dev …?
I always create rake task for data processing but then to sync between envs I need to invoke that rake task inside a migration
[11/7/2016, 6:47:54 PM] [anh bán chuối]: =&gt; migration still change data
[11/7/2016, 8:46:39 PM] [alias Trung.Le, as tle]: @longkt90 it is always an issue
[11/7/2016, 8:47:37 PM] [alias Trung.Le, as tle]: @longkt90 it is hard to get everything synced up if devs forget to run data migration tasks
[11/7/2016, 8:48:14 PM] [alias Trung.Le, as tle]: the org way of our app breaks it to many teams and each teams kinda only care partially about the data in DB
[11/7/2016, 8:48:34 PM] [alias Trung.Le, as tle]: should something in data breaks, they should take care themselves
[11/7/2016, 8:48:35 PM] [alias Trung.Le, as tle]: OR
[11/7/2016, 8:49:01 PM] [alias Trung.Le, as tle]: grabbing a the latest dump from prod, run it through a data sanitisation pipeline then import to their local box
[11/7/2016, 8:49:15 PM] [alias Trung.Le, as tle]: some team is now playing with idea of staging DB which is always up to date
[11/7/2016, 8:52:06 PM] [kimhieu]: @longkt90 I use heroku for staging and almost things I do is `pg`. So I use `heroku db dump` and import :smile:
[11/7/2016, 8:52:24 PM] [alias Trung.Le, as tle]: Move it to #general
[11/7/2016, 8:52:26 PM] [kimhieu]: <https://devcenter.heroku.com/articles/heroku-postgres-import-export>
[11/7/2016, 8:52:41 PM] [alias Trung.Le, as tle]: @kimhieu move it to #general
[11/7/2016, 10:49:12 PM] [alias Trung.Le, as tle]: #til Fujitsu Australia toàn chơi Ruby
[11/9/2016, 9:25:45 AM] []: #til use `utf8mb4` for MySQL instead of `utf8` or better use Postgresql instead
[11/9/2016, 5:55:15 PM] [alias Trung.Le, as tle]: #til if he can, I can
[11/9/2016, 6:29:06 PM] [anh bán chuối]: #til `array of array always be sanitized to an array with form-data and RSpec by default posts it as form-data`
[11/9/2016, 8:51:57 PM] [huy]: #til using .gitattributes file to add some interesting preprocessor to git
[11/12/2016, 8:16:42 PM] []: #til
```sudo apt-get install vim-nox
vimtutor
```
Matching parentheses search *%*
[11/14/2016, 2:42:52 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til đừng `dại` mà trả tiền (100%) mua hàng trước.
[11/17/2016, 1:33:55 PM] [huy]: #til There is a marketplace for algorithms :scream: <https://algorithmia.com/algorithms>
[11/20/2016, 5:00:42 AM] [lucdang]: vote ban cuốn “Elixir in Action”, lên thẳng trang chủ học hợp lý hơn
[11/20/2016, 3:58:24 PM] [alias Trung.Le, as tle]: @lucdang sao lại ban
[11/20/2016, 3:58:35 PM] [alias Trung.Le, as tle]: ở trên trang chủ thông tin tản mạn hơn
[11/20/2016, 3:58:37 PM] [alias Trung.Le, as tle]: ít vd hơn
[11/20/2016, 3:58:45 PM] [alias Trung.Le, as tle]: trong khi cuốn EIA khá là oke
[11/20/2016, 6:24:41 PM] [lucdang]: dạ nó đi lòng vòng chi tiết mấy cái khái niệm đoạn đầu, ráng note lại bay xuống chap11 làm product mà nó lang mang ko ra vấn đề anh ^^
[11/20/2016, 6:25:25 PM] [lucdang]: chui vào official document của Elixir làm project luôn có vẻ lẹ hơn, summarize lại được ý chính. Thường thường mà em hiểu là ai cũng hiểu hết ^^.
[11/20/2016, 7:01:24 PM] [alias Trung.Le, as tle]: hmmm
[11/23/2016, 1:43:18 AM] []: #til
&gt;a LIKE expression that starts with a wild card. Such a LIKE expression cannot serve as an access predicate. The database has to scan the entire table if there are no other conditions that provide access predicates.
[11/23/2016, 7:49:14 PM] [giangnh]: #til Diff trait `From` vs `Into`: `From` constructions `Self,` `Into` consume `self`
[11/23/2016, 7:50:55 PM] [unrealhoang]: là sao @giangnh
[11/23/2016, 7:51:23 PM] [alias Trung.Le, as tle]: @haond thực ra đó không phải DRY
[11/23/2016, 7:51:57 PM] [alias Trung.Le, as tle]: cái code sau đc sử dụng nếu có trên 1 biến, nó giúp dễ dàng nhận dạng field name
[11/23/2016, 7:52:25 PM] [alias Trung.Le, as tle]: ở trên cũng ngẫu nhiên tiết kiệm đc 1 tí code nhưng thực sự theo mình mục đíchc nó không phải là DRY
[11/23/2016, 7:53:01 PM] [unrealhoang]: @giangnh `From` với `Into` là 2 trait ngược nhau nhỉ
[11/23/2016, 7:53:34 PM] []: Dạ anh @tle
[11/23/2016, 7:54:21 PM] [unrealhoang]: @haond đừng quá coi trọng DRY
[11/23/2016, 7:55:33 PM] []: Lý do là gì anh ơi ?
[11/23/2016, 7:55:35 PM] [alias Trung.Le, as tle]: @haond nên hiểu đúng DRY
[11/23/2016, 7:55:45 PM] [unrealhoang]: chỉ khi nào repeat quá nhiều, và cost thay đổi cao
[11/23/2016, 7:55:47 PM] [alias Trung.Le, as tle]: cái câu gì mà @hieuk09 nói ấy nhỉ
[11/23/2016, 7:55:49 PM] [alias Trung.Le, as tle]: quên rồi
[11/23/2016, 7:55:51 PM] [unrealhoang]: thì hãy nên DRY
[11/23/2016, 7:56:02 PM] [alias Trung.Le, as tle]: quote của bà
[11/23/2016, 7:56:08 PM] [alias Trung.Le, as tle]: quên tên bà ấy rồi
[11/23/2016, 7:56:21 PM] [unrealhoang]: `repetition is much better than wrong abstraction`
[11/23/2016, 7:56:24 PM] [alias Trung.Le, as tle]: yeah
[11/23/2016, 7:56:26 PM] [alias Trung.Le, as tle]: đúng rồi
[11/23/2016, 7:56:29 PM] [unrealhoang]: - Sandy Metz
[11/23/2016, 7:56:34 PM] [alias Trung.Le, as tle]: đúng đúng
[11/23/2016, 7:56:36 PM] [alias Trung.Le, as tle]: quên xừ
[11/23/2016, 7:58:13 PM] []: Da thank anh @tle , <@U0GCK0JTW>
[11/23/2016, 8:08:17 PM] [giangnh]: anh @unrealhoang theom em hiểu nó không ngược nhau, `Into&lt;T&gt;` thì nó consume `self` để thành `T` còn `From&lt;T&gt;` thì nó consume `T` để thành `Self`
[11/23/2016, 8:08:30 PM] [giangnh]: `self # Self`
[11/23/2016, 8:11:57 PM] [giangnh]: `Into` với `From` có mối quan hệ : `From&lt;T&gt; for U` &lt;=&gt; `Into&lt;U&gt; for T` :troll:
[11/23/2016, 8:12:54 PM] [giangnh]: vd: `From&lt;Vec&lt;u8&gt;&gt; for String` &lt;=&gt; `Into&lt;String&gt; for Vec&lt;u8&gt;`
[11/27/2016, 10:41:40 PM] [alias Trung.Le, as tle]: TIL PostgreSQL advisory lock
[11/28/2016, 12:56:51 AM] [tucq88]: #til HAVING in SQL is pretty useful <http://stackoverflow.com/questions/2905292/where-vs-having>
[11/28/2016, 1:00:47 AM] [manhdv]: #til In case of protected methods, you can call them from the scope of any object belonging to the same class.
```
class Person
def older_than?(other_person)
age &gt; other_person.age
end
protected
def age
@age
end
end
```
[11/28/2016, 1:12:31 AM] [ko luong thien]: #til there is no good practices in Front End implementation. Only seek for suitable ones.
[11/28/2016, 4:38:49 AM] [unrealhoang]: @thien: same :hankey: everywhere
[11/28/2016, 4:39:30 AM] [ko luong thien]: @unrealhoang you got me man
[11/28/2016, 4:39:37 AM] [ko luong thien]: but it's time for me to shine, again :v
[11/28/2016, 4:39:53 AM] [ko luong thien]: trong cv k gì sáng bằng hốt shit front-end :v
[11/28/2016, 4:40:08 AM] [ko luong thien]: "I refactor the whole company's front-end codebase and everyone love me"
[11/28/2016, 7:23:07 AM] [tucq88]: #til
Use `ClassName.method(:magic_method).source_location` to reveal rails magic, from @lucdang
[11/28/2016, 5:56:20 PM] [alias Trung.Le, as tle]: #til `&lt;dl&gt;,&lt;dt&gt;, &lt;dd&gt;` HTML tag
[11/28/2016, 5:57:32 PM] [huy]: and even supported by IE + Opera
[11/28/2016, 6:21:39 PM] [alias Trung.Le, as tle]: true true
[11/28/2016, 6:21:50 PM] [alias Trung.Le, as tle]: #til `position: sticky` CSS
[11/28/2016, 6:22:39 PM] [huy]: err... i'd recommend stay away from experimental features :joy:
[11/28/2016, 7:07:52 PM] [tucq88]: so hard to debug and it's not widely support yet.
[11/29/2016, 11:24:29 PM] [tay vịn của anh bán chuối - cty A tìm FE]: #til HDD is how teams bring doom on themselves
The root of all evil seems to be social media — where new ideas spread much faster than they get tested. Much faster than people are able to understand their pros and cons.
[11/30/2016, 12:21:34 AM] [tucq88]: sorry, what's is HDD ? Hard disk drive ?
[11/30/2016, 12:22:56 AM] [tay vịn của anh bán chuối - cty A tìm FE]: @tucq88 Hype Driven Development
[11/30/2016, 12:23:12 AM] [tucq88]: :joy:
[12/1/2016, 1:48:06 AM] [manhdv]: #til On thi DH cap toc
<https://github.com/MaximAbramchuck/awesome-interview-questions>
[12/2/2016, 8:49:42 PM] [huy]: #til &gt;In 1999-2003, AMD extended this 32-bit architecture to 64 bits and referred to it as x86-64 in early documents and later as AMD64. Intel soon adopted AMD's architectural extensions under the name IA-32e which was later renamed EM64T and finally Intel 64.
[12/4/2016, 10:32:14 PM] [tay vịn của anh bán chuối - cty A tìm FE]: #til &lt;ruby&gt;, &lt;rp&gt;, &lt;rt&gt; html tag
[12/4/2016, 11:53:21 PM] []: #til `rake time:zones:all` finding time zone names
[12/5/2016, 12:12:02 AM] [manhdv]: @haond
try `rake - -task` to list all tasks by rake and read overview about them.
[12/5/2016, 12:13:05 AM] []: @manhdv
```
$rake - -task
rake aborted!
Rake::CommandLineOptionError: Unrecognized --trace option 'ask'```
[12/5/2016, 12:14:03 AM] [manhdv]: `rake —task` with double `-`
Slack auto merge 2 `-` to `— `:(
[12/5/2016, 12:16:28 AM] []: yes, ```rake --task```
[12/5/2016, 12:24:27 AM] []: @manhdv : replace ` by ``` to format code :smile:
[12/6/2016, 7:34:18 PM] []: #til: Auto to reload page
`browser-sync start --server --directory --files "**/*"`
[12/7/2016, 12:53:15 AM] []: #til: gulp + expressjs + nodemon + browser-sync
`<https://gist.github.com/sogko/b53d33d4f3b40d3b4b2e>`
[12/8/2016, 2:15:30 AM] [giangnh]: `a.replace(/.(?=....)/g, '#’)`
[12/8/2016, 2:19:19 AM] [manhdv]: ^ Replace string `a` to `#` exclude last 4 characters.
[12/8/2016, 8:01:51 PM] [alias Trung.Le, as tle]: #til một helper đơn giản để enable CSRF cho Rails app trong môi trường test cho một cucumber test cụ thể, cho code sau vào `features/support/env.rb`:
```
Around('@csrf') do |scenario, block|
with_forgery_protection do
block.call
end
end
def with_forgery_protection
orig = ActionController::Base.allow_forgery_protection
begin
ActionController::Base.allow_forgery_protection = true
yield if block_given?
ensure
ActionController::Base.allow_forgery_protection = orig
end
end
```
[12/8/2016, 8:02:23 PM] [alias Trung.Le, as tle]: rồi khi khai báo cuke scenario chỉ cần cho tag `@csrf` vào:
```
@csrf
Scenario: blah blah
Given blah bah
...
```
[12/9/2016, 1:14:24 AM] [huy]: #til ncdu super duper convenient
[12/9/2016, 1:14:34 AM] [huy]: `brew install ncdu`
[12/9/2016, 1:51:45 AM] [huy]: #til `script` is the command to capture your current tty session :think:
[12/9/2016, 2:24:07 AM] [vien]: #til separate wokring good is a miracle. :laughing:
[12/10/2016, 6:19:47 PM] [rebyn]: làm cái #ThisYearILearnt đi @tle
[12/11/2016, 4:32:09 PM] [alias Trung.Le, as tle]: @rebyn UBER IDEA!
[12/11/2016, 4:32:18 PM] [alias Trung.Le, as tle]: @rebyn let's bring it to #general for further discussion
[12/11/2016, 4:32:21 PM] [alias Trung.Le, as tle]: btw
[12/11/2016, 4:33:21 PM] [alias Trung.Le, as tle]: #til Rails 3.2 does not have CSRF exception handling mechanism like Rails 4.2, what it does is it resets the session and `continue the operation`, this could lead to unexpected operation. Rails 4.2 instead raise exception and the the operation stopped there.
[12/12/2016, 4:32:56 PM] []: #til:
Install wireshark in ubuntu
```
sudo apt-get install wireshark
sudo groupadd wireshark
sudo usermod -a -G wireshark $USER
sudo chgrp wireshark /usr/bin/dumpcap
sudo chmod 750 /usr/bin/dumpcap
sudo setcap cap_net_raw,cap_net_admin=eip /usr/bin/dumpcap
sudo getcap /usr/bin/dumpcap
sudo dpkg-reconfigure wireshark-common
Logout/login
```
[12/12/2016, 6:41:45 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :smile: tsao phải cài wireshark trên server trong khi đã có tcpdump
[12/12/2016, 7:49:52 PM] [huy]: Output của tcpdump ko đẹp bằng wireshark nhé :v
[12/12/2016, 7:58:03 PM] [giangnh]: #til go to dev tools settings and check `Log XMLHttpRequests` and open your console :fastparrot:
[12/12/2016, 8:05:30 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: @snacky cùng định dạng pcap thôi mà, capture trên server rồi kéo về local xem bằng wireshark thôi
[12/12/2016, 8:06:07 PM] [giangnh]: anh @xluffy có tip nào về tcpdump không anh ?
[12/12/2016, 8:06:20 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: ý tưởng là tối thiểu service, package trên server, cái gì ko cần thì nhất quyết ko cần cài
[12/12/2016, 8:06:28 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: @giangnh tip gì em, em muốn làm gì?
[12/12/2016, 8:07:22 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: tcpdump thì em có thể capture package qua network theo port, service, interface -&gt; ghi ra file pcap, rồi đem về máy xem bằng wireshark
[12/12/2016, 8:07:46 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: thường dùng để debug, troubleshoot liên quan đến network
[12/12/2016, 8:08:06 PM] [giangnh]: nó capture được package mình gửi đi là gì không nhỉ ? (hỏi ngu)
[12/12/2016, 8:08:35 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: đc em
[12/12/2016, 8:11:43 PM] [giangnh]: tính hỏi nửa mà thôi để tự tìm hiểu vậy thanks anh @xluffy
[12/12/2016, 8:13:48 PM] [tay vịn của anh bán chuối - cty A tìm FE]: @giangnh `Log XMLHttpRequests` I never enable this option. when do you need it?
[12/12/2016, 8:16:13 PM] [hieu.huynh]: tức là wireshark dựa trên tcpdump :thinking_face:
[12/12/2016, 8:17:05 PM] [giangnh]: @nhducit: nó cũng giống như tab network nhưng thím đang bên tab console muốn xem nhanh có XHR gì được gửi và không muốn qua tab network để xem XHR request thì có thể enable nó lên hoặc for fun :smile:
[12/12/2016, 8:17:43 PM] [tay vịn của anh bán chuối - cty A tìm FE]: em dùng luôn tab network, tại thấy nó log nhiều quá :disappointed:
[12/12/2016, 8:18:45 PM] [giangnh]: để nhìn cũng vui mà :think:
[12/12/2016, 8:25:12 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: @hieu.huynh bọn nó đều dùng chung chuẩn, thư viện libcap thì phải, wireshark kiểu như 1 GUI tool thôi em, còn tcpdump là command-line tool
[12/12/2016, 8:36:59 PM] [huy]: @giangnh: dùng tcpdump hoặc wireshark có thể capture đc cả in/out request từ mấy thiết bị bên ngoài như là iPhone, ipad các kiểu nữa đó
[12/12/2016, 8:38:18 PM] [giangnh]: @snacky nếu muốn capture kiểu đó
[12/12/2016, 8:38:26 PM] [giangnh]: thì có bài viết nào nói về đó không bác
[12/12/2016, 8:41:11 PM] [huy]: <http://useyourloaf.com/blog/remote-packet-capture-for-ios-devices/> đây bác. Ra #random típ nhé
[12/13/2016, 5:09:37 PM] [sondnm]: #til latest neovim always expect 3 arguments for event handlers
[12/15/2016, 5:45:18 PM] [huy]: #til regex replace feature of intellij is sooooo convenience
[12/15/2016, 5:48:56 PM] [unrealhoang]: @huydx: có gì hơn vim anh
[12/15/2016, 5:49:06 PM] [huy]: live preview em
[12/15/2016, 5:49:18 PM] [unrealhoang]: Neovim cũng có
[12/15/2016, 5:49:20 PM] [huy]: dac biet incase em dung capture group
[12/15/2016, 5:49:26 PM] [huy]: e biet ngay no dung hay sai
[12/15/2016, 5:49:32 PM] [huy]: no hien ngay cai trc khi replace voi sau khi replace
[12/15/2016, 5:49:38 PM] [huy]: a doan neovim k lam dc dau
[12/15/2016, 5:49:41 PM] [unrealhoang]: Live preview
[12/15/2016, 5:49:50 PM] [huy]: live preview day la edit
[12/15/2016, 5:49:57 PM] [huy]: doi ti a thu cho
[12/15/2016, 5:51:36 PM] [huy]: <https://gyazo.com/bc2c157efa3734b46c96f18eb309968c>
[12/15/2016, 5:51:55 PM] [huy]: no hien luon ket qua o duoi
[12/15/2016, 5:52:32 PM] [huy]: capture group tien vai
[12/15/2016, 5:52:40 PM] [huy]: cai nay ma k co live preview thi an shit ngay
[12/15/2016, 5:52:45 PM] [unrealhoang]: Ok tí em thử neovim cho
[12/15/2016, 7:10:09 PM] [unrealhoang]: inc command ngon lành nhé @huydx
[12/15/2016, 7:10:23 PM] [huy]: capture xem ta
[12/15/2016, 7:10:35 PM] [unrealhoang]: tool gì capture nhỉ
[12/15/2016, 7:10:56 PM] [huy]: gyazo gif
[12/15/2016, 7:11:14 PM] [huy]: hoac asciinema
[12/15/2016, 7:11:15 PM] [unrealhoang]: ok
[12/15/2016, 7:18:26 PM] [unrealhoang]: <https://gyazo.com/816b4ef0aaf208ddc5df12b90436b152>
[12/15/2016, 7:18:54 PM] [unrealhoang]: màn hình bự quá nên hơi khó nhìn
[12/15/2016, 7:20:06 PM] [huy]: co' group reference k em
[12/15/2016, 7:20:13 PM] [unrealhoang]: có đấy anh
[12/15/2016, 7:20:42 PM] [unrealhoang]: search query là `/\(.\)et/`
[12/15/2016, 7:21:00 PM] [unrealhoang]: replace là `%s//\1at/`
[12/15/2016, 7:21:18 PM] [unrealhoang]: mà cũng đâu có gì khó
[12/15/2016, 7:21:30 PM] [unrealhoang]: nó thử rồi redraw thôi mà
[12/15/2016, 7:21:34 PM] [unrealhoang]: thằng nào chẳng làm được
[12/15/2016, 7:21:36 PM] [unrealhoang]: :omg:
[12/15/2016, 7:22:48 PM] [huy]: vim thuong co lam dc dau :omg:
[12/15/2016, 7:29:23 PM] []: mào tím mộng mơ
[12/15/2016, 7:29:25 PM] []: :omg:
[12/15/2016, 7:52:56 PM] [hasagi]: neovim bản update vừa rồi
[12/15/2016, 7:52:59 PM] [hasagi]: mới có live replace mà
[12/15/2016, 7:53:03 PM] [hasagi]: :))
[12/15/2016, 7:53:06 PM] [alias Trung.Le, as tle]: #til CFO bên cty có ... 21 tuổi. Cảm thấy mình quá còn thấp kém...
[12/15/2016, 8:01:31 PM] [tucq88]: #til nên sống lạc quan và ko nên so sánh mình với talent :v
[12/15/2016, 8:02:01 PM] []: 21 tuổi sao đủ kinh nghiệm làm finance nhỉ
[12/15/2016, 8:05:51 PM] [tucq88]: talent mà :s genius cũng nên :disappointed:
[12/15/2016, 8:05:52 PM] [tay vịn của anh bán chuối - cty A tìm FE]: 21 :omg:
[12/15/2016, 8:06:17 PM] [tay vịn của anh bán chuối - cty A tìm FE]: vừa học đh vừa đi làm hay không học luôn ta :neutral_face:
[12/15/2016, 8:07:00 PM] [tucq88]: kiểu đấy chắc 16 tuổi học xong PhD, sau đó 5 năm làm thực tế
[12/15/2016, 8:08:49 PM] [alias Trung.Le, as tle]: nhận đc cái card chúc mừng giáng sinh...ghi 21 tuổi
[12/15/2016, 8:08:51 PM] [alias Trung.Le, as tle]: hết hồn
[12/15/2016, 8:08:56 PM] [alias Trung.Le, as tle]: nhìn mặt thì tầm 30
[12/15/2016, 8:09:09 PM] [alias Trung.Le, as tle]: dù gì cũng là dân Châu Á
[12/15/2016, 8:09:16 PM] [alias Trung.Le, as tle]: cũng tự hào có người Á làm chức to
[12/15/2016, 8:09:29 PM] [huy]: con trai cua CEO :thinking_face:
[12/15/2016, 8:09:34 PM] [huy]: (think like vietnamese)
[12/15/2016, 8:10:29 PM] [tucq88]: `nhìn mặt thì tầm 30` =&gt; vậy là nó overtime rồi anh =)))
[12/15/2016, 8:12:32 PM] [alias Trung.Le, as tle]: @huydx CEO không phải Á anh
[12/15/2016, 8:12:36 PM] [alias Trung.Le, as tle]: và ổng có con bé tuổi
[12/15/2016, 8:12:36 PM] [alias Trung.Le, as tle]: LOL
[12/15/2016, 8:12:53 PM] [alias Trung.Le, as tle]: để hỏi lại
[12/15/2016, 8:12:56 PM] [alias Trung.Le, as tle]: chắc ng ta troll
[12/15/2016, 8:12:58 PM] [alias Trung.Le, as tle]: mặt tuy trẻ
[12/15/2016, 8:13:02 PM] [alias Trung.Le, as tle]: nhưng 21 tuổi hơn quá
[12/15/2016, 8:13:05 PM] [alias Trung.Le, as tle]: sao đủ kn
[12/15/2016, 8:13:23 PM] [alias Trung.Le, as tle]: mà nếu là thiệt chắc là cá biệt thần đồng...
[12/15/2016, 8:13:29 PM] [alias Trung.Le, as tle]: cty ăn nên làm ra...
[12/15/2016, 8:13:31 PM] [alias Trung.Le, as tle]: vkl...
[12/15/2016, 8:16:34 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: chắc troll cho vui :smile: ví dụ sinh nhật 21 tuổi lần thứ 15 :smile:
[12/15/2016, 9:08:46 PM] [unrealhoang]: Hoặc bác ấy sinh vào 29/2
[12/15/2016, 10:34:35 PM] [manhdv]: 21 tuổi làm CFO đâu có gì đâu anh
vẫn có thanh niên 26 tuổi, thạo 4 thứ tiếng và làm vụ phó đấy thôi :smile:
[12/15/2016, 10:35:50 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: =))
[12/15/2016, 10:36:49 PM] [hieu.huynh]: =))))))
[12/15/2016, 11:06:52 PM] [alias Trung.Le, as tle]: @manhdv: thâm thuý quá
[12/15/2016, 11:06:59 PM] [alias Trung.Le, as tle]: :smoking:
[12/16/2016, 2:19:30 AM] [manhdv]: #til cả đời mò mẫm ko bằng 5 phút dựa dẫm :neutral_face:
[12/16/2016, 6:53:47 AM] [minh.nguyen]: #til Directory is a type of file in Unix and Unix-like systems and everything is file :rip:
[12/16/2016, 7:22:43 AM] [huynh.cam]: @nguyenquangminh ahihi ngạc nhiên chưa
[12/17/2016, 3:04:29 AM] [minh.nguyen]: #til <http://silverhammermba.github.io/emberb/c/>
[12/18/2016, 12:58:13 AM] [sondnm]: #til if you have trouble when using arrow key or `Ctrl` key in `irb`, it's because you didn't compile ruby with `readline` library. Using `rbenv` to install ruby by `RUBY_CONFIGURE_OPTS=--with-readline-dir="/usr/lib" rbenv install 2.3.1` in condition that you have `readline` installed in `/usr/lib`
[12/18/2016, 1:17:09 AM] [hieu.huynh]: #til thêm dòng này `export HISTTIMEFORMAT="%d/%m/%y [%T] &gt; “ `
[12/18/2016, 1:17:38 AM] [hieu.huynh]: vào `~/.bashrc` linux
[12/18/2016, 1:18:09 AM] [hieu.huynh]: khi gõ lệnh history, nó sẽ cho biết thêm ngày giờ thực hiện của từng command trước đó
[12/19/2016, 12:04:31 AM] [manhdv]: #til
ActiveSupport::Notifications
<http://api.rubyonrails.org/classes/ActiveSupport/Notifications.html>
<https://speakerdeck.com/nextmat/digging-deep-with-activesupportnotifications>
[12/19/2016, 1:32:11 AM] [lucdang]: In general, the safest path to writing concurrent code in JRuby is the same as on any other platform:
1 - Don't do it, if you can avoid it.
2 - If you must do it, don't share data across threads.
3 - If you must share data across threads, don't share mutable data.
4 - If you must share mutable data across threads, synchronize access to that data.
Nguồn ^^: <https://github.com/jruby/jruby/wiki/Concurrency-in-jruby#thread_safety>
[12/19/2016, 5:09:23 AM] [huynh.cam]: @lucdang TLDR Don't write code in JRuby
[12/19/2016, 5:17:52 AM] [lucdang]: em maintain code in JRuby anh @hqc =.=
[12/19/2016, 9:11:28 PM] [alias Trung.Le, as tle]: #til how to find a commit is an ancestor of other commit in GIT? use `git merge-base --is-ancestor`
[12/20/2016, 2:26:07 AM] [ko luong thien]: #til heroku is case sensitive, mac by default is not case sensitive, git can be case sensitive or not
[12/22/2016, 1:17:53 AM] [manhdv]: #til
How to make generators
<http://railscasts.com/episodes/218-making-generators-in-rails-3?view=asciicast>
[12/27/2016, 2:55:29 AM] [hieu.huynh]: #til Trong Jira, ở bất kì page nào, gõ `?` sẽ hiện lên bảng phím tắt của Jira
Trick này có ở Confluence, Bitbucket (chắc là toàn bộ sp của Atlassian, em ko chắc)
Có ở github luôn
[12/27/2016, 10:54:08 PM] []: #til systemd-nspawn thật là lợi hại
[12/28/2016, 11:26:05 PM] [sondnm]: #til with vim-rails `C-W gf` will open a relative file in a new tab
[1/1/2017, 2:04:06 AM] [alias Trung.Le, as tle]: #til Gregorian vs Julian calendar
[1/2/2017, 5:26:11 AM] []: #til shameless green
[1/4/2017, 8:34:59 PM] [hieu.huynh]: #til
Disk usage tracking of folder
In linux
`sudo du -hs * | sort -h`
In Mac, need homebrew, then install `brew install coreutils`
`sudo du -hs * | gsort -h`
[1/5/2017, 2:26:44 AM] [huynh.cam]: #til <https://kipalog.com/posts/Default-Order-trong-SQL>
[1/5/2017, 6:31:00 AM] [tay vịn của anh bán chuối - cty A tìm FE]: <http://0.30000000000000004.com/>
[1/5/2017, 7:40:58 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: <https://vietnamrb.slack.com/archives/til/p1483590899000170> you can use `ncdu`
[1/5/2017, 7:42:56 PM] [hieu.huynh]: thanks @xluffy :tada:
[1/8/2017, 7:23:50 AM] [jinhduong]: <https://github.com/AngularClass/awesome-angular2>
[1/8/2017, 5:07:53 PM] [huy]: #til you can even put a comment inside a regex. here is the keyword: `regex inline comment`
[1/9/2017, 3:46:19 PM] [huy]: #til sometimes, bug fixing mean: remove all the code from a guy sit next to you :rofl:
[1/9/2017, 5:57:31 PM] [alias Trung.Le, as tle]: #til rescue exception of rails in router <https://gist.github.com/joneslee85/f2b4565949f7c988c9481b3c5dc15dba>
[1/9/2017, 7:07:35 PM] [rebyn]: #til I hate Python syntax
[1/9/2017, 7:55:34 PM] [manhdv]: Scan port of host or domain:
`nmap -sT -vv -p 1-65535 host_ip_or_domain`
if host prevent ping:
`nmap -sT -vv -Pn -p 1-65535 host_ip_or_domain`
[1/10/2017, 7:18:05 PM] [minh.nguyen]: #til Never redirect stderr when using `Kernel.system`. It returns status `0` right away and stop watching for the currently created process.
[1/12/2017, 9:05:01 AM] [sondnm]: #til if your REPL does not include `readline`, install and use `rlwrap` like this `rlwrap mit-scheme`
[1/15/2017, 11:27:53 PM] []: #til <https://www.blockloop.io/mastering-bash-and-terminal>
[1/16/2017, 12:47:18 AM] [hasagi]: #til Methods in Go are just syntactic sugar for a function which passes the receiver as the first formal parameter.
[1/16/2017, 12:47:45 AM] [unrealhoang]: :neutral_face:
[1/16/2017, 12:48:04 AM] [unrealhoang]: @runi_mage it’s almost same for every languages
[1/16/2017, 12:48:25 AM] [hasagi]: it is?
[1/16/2017, 12:48:41 AM] [unrealhoang]: yes, you can take a look at python
[1/16/2017, 12:48:43 AM] [unrealhoang]: Rust
[1/16/2017, 12:48:51 AM] [hasagi]: hm…
[1/16/2017, 12:48:54 AM] [hasagi]: interesting
[1/16/2017, 12:54:01 AM] [giangnh]: hmm...
[1/16/2017, 12:54:04 AM] [giangnh]: interesting
[1/16/2017, 12:59:11 AM] [unrealhoang]: and if you think it that way, you don’t need to care about OOP anymore
[1/16/2017, 12:59:12 AM] [unrealhoang]: @runi_mage
[1/16/2017, 1:00:04 AM] [hasagi]: I see
[1/16/2017, 1:01:45 AM] [unrealhoang]: so programming is just simply either transforming data (`map/reduce`) or do side effect
[1/16/2017, 1:04:50 AM] [huy]: The Physiology of Programming
[1/16/2017, 4:59:56 PM] [unrealhoang]: #til `a union` not `an union` @giangnh
[1/16/2017, 5:00:00 PM] [unrealhoang]: :rip:
[1/16/2017, 5:19:05 PM] [sondnm]: #til to exclude a file from stylesheet manifest file in rails, use `*= stub &lt;FILENAME&gt;`
[1/17/2017, 1:00:15 AM] [unrealhoang]: #til you can provide capacity for String in Ruby 2.4.0 by: `String.new(””, capacity: size)`
[1/17/2017, 5:45:35 AM] []: #til <http://postgres.cz/wiki/PostgreSQL_SQL_Tricks_I>
[1/17/2017, 7:42:27 PM] [hasagi]: #til typecast # type conversion/assertion
[1/21/2017, 9:27:10 AM] []: Scroll shell output in tmux
- Enable scroll : `Ctrl-b` then `[`
- Goto line: `:` then `line number`
[1/21/2017, 11:20:49 AM] [huuson235]: #til in rust: Expression return value, Statement doesn't return anthing.
[1/21/2017, 5:01:55 PM] []: #til Check if tables need to be VACUUM base on columns `n_dead_tup`, `n_tup_upd`, `n_tup_del`
`SELECT * FROM pg_stat_all_tables ORDER BY n_dead_tup DESC`
<http://dba.stackexchange.com/a/18695/109419>
[1/22/2017, 2:52:46 AM] [hasagi]: @huuson235 it’s not only in rust
[1/22/2017, 12:53:55 PM] [huuson235]: #til Rust: Stack =&gt; Copy, Heap =&gt; Move
[1/22/2017, 7:06:15 PM] [alias Trung.Le, as tle]: <https://camo.githubusercontent.com/1ae853b7204cd1dd1df9098e0113110fb0d2ac7f/687474703a2f2f7777772e67696662696e2e636f6d2f62696e2f3039323031332f313338303733343039365f72616d656e5f6e6f6f646c65735f62656172645f626f776c2e676966>
[1/22/2017, 7:08:26 PM] [huy]: @tle I think only you can do it here
[1/22/2017, 7:19:36 PM] [alias Trung.Le, as tle]: lol
[1/22/2017, 11:21:43 PM] [tay vịn của anh bán chuối - cty A tìm FE]: #til Record and share your terminal sessions, the right way. <https://asciinema.org/>
[1/23/2017, 10:44:25 PM] [huuson235]: #til Rust: “string slice” is written as &amp;str:
[2/3/2017, 3:23:55 AM] []: #til <https://explain.depesz.com/>
PostgreSQL's explain analyze made readable
[2/3/2017, 6:32:32 AM] []: #til PostgreSQL Hardware Performance Tuning
<https://momjian.us/main/writings/pgsql/hw_performance/>
[2/3/2017, 10:27:39 PM] [lucdang]: - If you're doing TDD process, you shouldn't start from the idea that your Task belongs to a Project. Rather, as you describe features the relationship is implied from the feature tests that you're writing. (Rails Test Prescription, page 94)
```ruby
# Implementation test: Should be not used
describe Task do
it{ should belong_to(:project) }
it{ should ensure_presence(:name) }
end
# Feture test: Should be used
it "does not allow creation of a tesk without a name" do
task = Task.new(name: "search a book", size: 5)
expect(task.size).to be_presence
end
```
[2/6/2017, 7:15:18 PM] [tay vịn của anh bán chuối - cty A tìm FE]: #til canonical URLs
[2/6/2017, 7:15:19 PM] [tay vịn của anh bán chuối - cty A tìm FE]: <https://support.google.com/webmasters/answer/139066?visit_id=1-636219831361325220-3373763690&amp;hl=en&amp;rd=1>
[2/8/2017, 2:20:17 AM] [manhdv]: #whylargeamounts
<http://tech.mercari.com/entry/2017/01/18/123944>
[2/8/2017, 2:54:37 PM] [huy]: #TIL Mongoose's Schema is REALLY strict about object creation. It will strip out everything that not defined and parse any type into the defined type. :notbad:
[2/9/2017, 7:17:24 AM] [giangnh]: #til `RUST_LOG={info, debug, level, error} cargo run` hoặc `RUST_LOG={info, debug, level, error} execuable` sẽ show ra hết toàn bộ log trong chương trình đang chạy
[2/12/2017, 8:47:56 PM] [hasagi]: #til kipalog button is not like button
[2/12/2017, 8:57:02 PM] [hieu.huynh]: #til take a week to learn `How to identify Replication Delay`, not one day :disappointed:
<https://planet.mysql.com/entry/?id=684389>
[2/13/2017, 2:58:26 AM] [manhdv]: #DoOrDont-NoTry
<https://engineering.pinterest.com/blog/sharding-pinterest-how-we-scaled-our-mysql-fleet>
[2/16/2017, 4:24:55 PM] [alias Trung.Le, as tle]: @manhdv good read for brain
[2/16/2017, 4:50:47 PM] [manhdv]: Em có thắc mắc là mysql đã cung cấp gói mysql fabric với chức năng auto sharding rồi, tại sao developer không dùng mà thường tự cấu hình và tạo thuật toán sharding lấy? Vì developer giỏi? Vì gói mysql fabric không đáng tin? Hay vì hồi triển khai chưa có gói này?
[2/16/2017, 5:09:18 PM] [sondnm]: #til special case pattern to avoid nil object <https://www.rubytapas.com/2017/01/31/two-screencasts-two-ways-eradicate-ruby-nil-values/>
[2/16/2017, 5:38:48 PM] [alias Trung.Le, as tle]: ^ valuable pattern
[2/16/2017, 5:39:17 PM] [alias Trung.Le, as tle]: the less `if`, the better
[2/16/2017, 5:39:58 PM] [alias Trung.Le, as tle]: @sondang just use Elixir, you don't have to worry about writing any condition
[2/16/2017, 5:42:48 PM] [minh.nguyen]: or Haskell :troll:
[2/16/2017, 5:44:10 PM] [alias Trung.Le, as tle]: lol
[2/16/2017, 5:45:56 PM] [alias Trung.Le, as tle]: anh cũng mới biết về cái fabric luôn, có thể thời điểm lúc đó fabric chưa ổn định chăng? hay là bên đấy muốn hoàn toàn nắm phần implementation này vì không có muốn lệ thuộc hoàn toàn vào fabric?
[2/16/2017, 5:47:25 PM] [alias Trung.Le, as tle]: dựa vào app bên cty thì một trong những tiêu chí chọn giải pháp là có expert về mảng đó. và nếu giải pháp nào nhiều black magic quá cũng là vấn đề vì support cho nó sẽ khó hơn
[2/16/2017, 5:50:43 PM] [alias Trung.Le, as tle]: @manhdv mấy bài này hay, lần sau em drop qua bên #devops
[2/16/2017, 6:16:15 PM] [huy]: go 12
[2/16/2017, 6:44:11 PM] [unrealhoang]: or Rust
[2/16/2017, 6:45:09 PM] [unrealhoang]: no more NULL: <https://kipalog.com/posts/Rust-khong-co-NULL-thi-code-kieu-gi>
[2/16/2017, 6:47:50 PM] [huy]: :think:
[2/16/2017, 7:04:32 PM] [alias Trung.Le, as tle]: ...
[2/16/2017, 7:04:35 PM] [alias Trung.Le, as tle]: =_=
[2/16/2017, 7:10:36 PM] [giangnh]: ```jekyll serve —host=0.0.0.0```
[2/20/2017, 8:44:16 PM] [ko luong thien]: #til react-dev-tools extension fire `message` event on `window`. Therefore if you use postMessage for cross-domain communicating, you will see a lot of `message` event from the tool beside yours
[2/21/2017, 10:24:18 AM] [ko luong thien]: #til <https://auth0.com/blog/what-is-serverless/>
[2/21/2017, 6:35:14 PM] [alias Trung.Le, as tle]: @anhduy there is a famous tweet on what serverless
[2/21/2017, 6:42:05 PM] []: Tweet nào anh
[2/21/2017, 8:02:31 PM] [alias Trung.Le, as tle]: @anhduy có một tweet troll vụ đó
[2/21/2017, 8:02:37 PM] [alias Trung.Le, as tle]: Để anh moi lại
[2/21/2017, 10:28:01 PM] [ko luong thien]: moi ra chưa anh @tle
[2/21/2017, 11:12:11 PM] []: Chưa thấy tle tl luôn
[2/22/2017, 1:59:38 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til <https://macademic.org/2011/06/08/never-end-your-email-with-thanks-in-advance/>
[2/22/2017, 2:22:08 AM] [ko luong thien]: #til <https://webtask.io/>
[2/22/2017, 5:23:04 PM] [sondnm]: #til delete to end of previous line in vim `d?$&lt;CR&gt;` :troll:
[2/23/2017, 8:45:27 AM] [ko luong thien]: wait @sondang you are using vim too @@
[2/23/2017, 8:45:37 AM] [ko luong thien]: I didn’t see that coming..
[2/23/2017, 8:45:52 AM] [ko luong thien]: I always thought you sublime with me..
[2/23/2017, 4:48:16 PM] [sondnm]: @thien vim from the beginning dude. sublime is out of my league :))
[2/23/2017, 10:47:38 PM] [huynh.cam]: @thien <@U0U1BKCKB> We expect no chitchat here :D
[2/28/2017, 9:50:23 PM] [ko luong thien]: #til in Javascript:
```
null / 0 === NaN
1 / 0 === Infinity
null / 1 === 0
```
[2/28/2017, 9:51:48 PM] [ko luong thien]: also
[2/28/2017, 9:52:01 PM] [ko luong thien]: ```
isFinite(null) === true
```
[3/1/2017, 1:32:13 AM] [manhdv]: #til `sudo gem list` vs `gem list`
[3/1/2017, 2:26:53 AM] []: Sudo là chết nha
[3/1/2017, 3:20:15 AM] []: ai lại đi sudo
[3/1/2017, 3:20:42 AM] []: cái nào mình ko `own` thì phải biến nó về mình `own` chứ
[3/1/2017, 3:20:45 AM] []: :omg:
[3/1/2017, 6:56:12 PM] [hieu.huynh]: #til Nhờ cái `archive các messages với <http://slackarchive.io|slackarchive.io>` của BĐH
nên em phát hiện ra rằng mình có thể vào xem rất nhiều community mà không cần register
Một số community chất lượng:
+ <http://mesos.slackarchive.io/>
+ <http://kubernetes.slackarchive.io/>
+ <http://sqlcommunity.slackarchive.io/>
[3/2/2017, 8:17:47 AM] []: @hieu.huynh rat huu ich, thanks :+1::+1::+1:
[3/5/2017, 6:36:04 AM] [unrealhoang]: ```
Nobody actually creates perfect code the first time around, except me. But there’s only one of me.
— Linus Torvalds
```
quote lụm được từ kipalog
[3/5/2017, 6:32:11 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: My name is Linus, and I am your God. - Linus Torvalds :omg:
[3/6/2017, 4:57:19 PM] [ko luong thien]: inputmode
&gt; A hint to the browser for which keyboard to display. This attribute applies when the value of the type attribute is text, password, email, or url. Possible values are:
(attribute of &lt;input /&gt;)
[3/6/2017, 6:08:30 PM] [ko luong thien]: #til RegEx for Japanese <https://gist.github.com/terrancesnyder/1345094>
[3/6/2017, 10:50:08 PM] [huynh.cam]: #til ifconfig = interface config :scream: viết tắt
[3/6/2017, 11:12:35 PM] [alias Trung.Le, as tle]: #til most people bash other's people choice of stack before they know thoroughly other stacks
[3/7/2017, 2:37:49 AM] [ko luong thien]: #til <https://i.stack.imgur.com/LSIG4.png>
[3/7/2017, 7:32:43 PM] [ko luong thien]: #til children callback / use function as children in React
```
&lt;Fetch path="/data"&gt;
(data, error, done) =&gt; done &amp;&amp; &lt;Data … /&gt;
&lt;/Fetch&gt;
```
thank to @huygn
[3/7/2017, 10:36:41 PM] [ko luong thien]: #til
&gt; If the finally block returns a value, this value becomes the return value of the entire try-catch-finally production, regardless of any return statements in the try and catch blocks
- MDN -
```
function hello() {
try {
return "Yo!";
} finally {
return "Aw!";
}
}
hello(); // "Aw!"
```
thank to @snacky
[3/7/2017, 11:09:44 PM] [toanha]: #til trong elixir map co order khi loop
[3/7/2017, 11:11:45 PM] [noob]: là sao ta :think:
[3/8/2017, 8:41:57 AM] [toanha]: ví dụ nhu
```
for {k, v} &lt;- %{c: 1, b: 2, a: 3} do
IO.inspect "#{k}: #{v}"
end
```
[3/8/2017, 8:42:15 AM] [toanha]: no se in ra
```
"a: 3"
"b: 2"
"c: 1”
```
[3/8/2017, 8:42:31 AM] [toanha]: thay vi
```
"c: 1"
"b: 2”
"a: 3”
```
[3/8/2017, 11:06:41 PM] [alias Trung.Le, as tle]: #til Scenario Outlines in Cucumber can be very useful to implement looping scenario through a set of values
[3/8/2017, 11:14:59 PM] [hieu.huynh]: #til How is Redis pronounced?
&gt; It's "red" like the color, then “iss”.
[3/11/2017, 9:58:03 PM] [dan]: #til Class.superclass =&gt; Module
[3/14/2017, 7:11:28 PM] [sondnm]: #til how to test Google Analytics on localhost <http://blog.jessitron.com/2012/05/testing-google-analytics-locally.html>
[3/16/2017, 2:37:53 AM] [ko luong thien]: #til <https://www.smashingmagazine.com/2017/03/interactive-command-line-application-node-js/>
[3/16/2017, 6:44:27 AM] [ko luong thien]: #til css grid layout is complicated
[3/16/2017, 6:44:33 AM] [ko luong thien]: but useful, indeed
[3/16/2017, 7:03:22 AM] [giangnh]: @thien why complicate ?
[3/16/2017, 7:04:14 AM] [ko luong thien]: @giangnh more complicate than flexbox as far as I learned
[3/16/2017, 7:04:25 AM] [ko luong thien]: Still haven't get it all
[3/16/2017, 7:04:43 AM] [ko luong thien]: Basically, it introduce new concepts and terms like flexbox
[3/16/2017, 7:04:46 AM] [ko luong thien]: But more
[3/16/2017, 7:04:55 AM] [giangnh]: but it powerful
[3/16/2017, 7:05:30 AM] [ko luong thien]: Have you used it?
[3/16/2017, 7:05:59 AM] [giangnh]: Not yet! :lol:
[3/16/2017, 7:06:46 AM] [ko luong thien]: :(
[3/16/2017, 7:07:34 AM] [ko luong thien]: Anyway we are going to have it on our production as an experimental feature :)) will tell more what I will learn
[3/17/2017, 5:02:23 AM] []: #til <https://github.com/bmorelli25/Become-A-Full-Stack-Web-Developer/>
[3/19/2017, 6:54:25 PM] [dan]: #til class &lt;&lt; obj; def func; and def obj.func is not interchangeable in some cases
[3/19/2017, 11:02:30 PM] [alias Trung.Le, as tle]: Nói rõ một chút không nhỉ?
[3/21/2017, 9:13:47 PM] [manhdv]: <https://cloud.google.com/free/docs/map-aws-google-cloud-platform>
[3/22/2017, 3:51:53 AM] [unrealhoang]: <https://www.inputoutput.io/lookbehind-lookahead-regex-in-vim/>
[3/22/2017, 7:52:34 PM] []: #til - *Everything in Ruby is Object*, so Ruby is Object-oriented programming. But Ruby has borrowed some of functional programming concepts
[3/22/2017, 8:14:56 PM] [huy]: #til xài ibus-bogo thay vì ibus-unikey để gõ tiếng việt không preedit, vì một thế giới không preedit :adore:
[3/23/2017, 3:09:04 AM] [hieu.huynh]: #til Enable aws cli command completion
<http://docs.aws.amazon.com/cli/latest/userguide/cli-command-completion.html>
go <#C0GUMNSH0|devops>
[3/23/2017, 5:09:31 AM] [dan]: Nó khác về scope của constant
```
N = 1
obj = Object.new
class &lt;&lt; obj
N = 2
end
def obj.func1
p N
end
class &lt;&lt; obj
def func2
p N
end
end
obj.func1 =&gt; 1
obj.func2 =&gt; 2
```
[3/24/2017, 10:54:17 PM] [giangnh]: #rustlang `cargo run --release`
[3/26/2017, 12:30:57 AM] [minh.nguyen]: #til <http://www.rubydoc.info/github/rack/rack/file/SPEC>
[3/29/2017, 10:35:35 AM] [ko luong thien]: #til <https://medium.com/javascript-scene/javascript-factory-functions-vs-constructor-functions-vs-classes-2f22ceddf33e>
[3/29/2017, 7:27:06 PM] [tay vịn của anh bán chuối - cty A tìm FE]: cái bê đê của class là define function xong phải `bind(thís)`
[3/31/2017, 12:59:35 AM] [hasagi]: #til add thêm lib nào thì add luôn vào vendor của project, đừng xài lẫn lộn với $GOPATH kẻo gặp miracle bugs :omg:
[3/31/2017, 2:29:30 AM] [noob]: $GOPATH sao lại liên qua đến Miracle- :think:
[3/31/2017, 2:30:32 AM] [hasagi]: @mquy ggwp
[4/1/2017, 2:45:47 AM] [sondnm]: #til <https://github.com/iridakos/table_flipper> :omg:
[4/1/2017, 6:26:21 AM] [ko luong thien]: #til there is command line version of speedtest..
[4/2/2017, 8:56:24 PM] [ko luong thien]: #til hôm nay có chuyện vui =)) đưa file json cho đồng nghiệp người TQ nhờ nó dịch mấy từ trong đó
[4/2/2017, 8:56:39 PM] [ko luong thien]: lúc nhận về eslint báo lỗi Expected indentation of 2 spaces but found 0
[4/2/2017, 8:56:58 PM] [ko luong thien]: mở code ra thì thấy đúng là có 2 spaces
```
"back-to-trading": "返回交易",
```
[4/2/2017, 8:57:11 PM] [ko luong thien]: hồi sau mới phát hiện
[4/2/2017, 8:57:17 PM] [ko luong thien]: space đó là space của CJK =))
[4/2/2017, 10:05:01 PM] [alias Trung.Le, as tle]: lol
[4/3/2017, 7:45:07 PM] [huy]: #til Hà Nội (hà = sông, nội = trong, hà nội = thành phố nằm trong các dòng sông). Sài Gòn (sài = gỗ, gòn = bông gòn, vùng này hồi xưa có nhiều 2 thứ này nên gọi mãi thành tên) :think: <https://2008.viettug.org/blogs/546.html>
[4/3/2017, 7:46:55 PM] [hieu.huynh]: really :think:
[4/3/2017, 7:50:58 PM] [unrealhoang]: So deep Adele can roll in it
[4/3/2017, 7:54:34 PM] [huy]: tin hay ko thì chắc phải mua sách về đọc thôi :think:
[4/3/2017, 8:24:44 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: cái từ Sài Gòn nó lằng nhằng lắm :smile:
[4/3/2017, 8:25:28 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: đọc quyển Sài Gòn Năm Xưa của Vương Hồng Sến mà cũng thua, vì lịch sử của cái từ này nó lằng nhẵng v~
[4/6/2017, 5:35:39 AM] [dan]: #til nếu mình throw exception trong rescue thì rails vẫn hiện log của exception ngoài
[4/8/2017, 5:43:00 AM] [hieu.huynh]: #til *Amazon Route 53* (Route 53) is a scalable and highly available Domain Name System (DNS)
Why 53? The name is a reference to TCP or UDP `port 53`, where DNS server requests are addressed
[4/8/2017, 5:43:12 AM] [hieu.huynh]: :sexy:
[4/9/2017, 12:36:42 AM] [minh.nguyen]: @lucdang module nó cũng có instance variable :smile:
[4/9/2017, 12:37:00 AM] [lucdang]: uhm Module với Class là 2 chị em mà
[4/9/2017, 12:37:20 AM] [lucdang]: có điều Class nó có thêm 3 method, :new với gì quên rồi, nên tạo object được
[4/9/2017, 12:37:59 AM] [minh.nguyen]: `[:allocate, :new, :superclass]`
[4/9/2017, 12:42:10 AM] [lucdang]: ku minh như cái google ấy
[4/9/2017, 12:42:11 AM] [lucdang]: =))
[4/9/2017, 12:42:28 AM] [minh.nguyen]: trong irb có đó anh =))
[4/9/2017, 1:22:39 AM] [dan]: Class.superclass #=&gt; Module
[4/9/2017, 1:34:11 AM] []: @lucdang ko học ruby đàng hoàng, cái vụ class là object là cơ bản msf
[4/9/2017, 1:34:43 AM] [lucdang]: động cơ của em là chia sẽ mà
[4/9/2017, 1:34:44 AM] [lucdang]: hehe
[4/9/2017, 1:35:50 AM] [lucdang]: @anhduy để keyword là lucdang đúng ko, canh bóp e ko :cry: :crying:
[4/9/2017, 2:31:49 AM] [dan]: #til in es6
```
function func(a) { return a}
func`abc` // =&gt; ['abc']
```
[4/11/2017, 2:57:14 AM] [sondnm]: #til <http://api.rubyonrails.org/classes/ActiveSupport/Notifications.html>
[4/13/2017, 2:57:03 AM] [huynh.cam]: #til raising `ActionController::BadRequest` in Rails controller will end up giving you 500 Internal Server Error :thinking_face: :shrug:
[4/13/2017, 3:00:15 AM] [alias Trung.Le, as tle]: #til how to write singleton with ES6
[4/15/2017, 9:37:09 AM] [minh.nguyen]: #til test viết càng sớm càng tốt, TDD thì quá tuyêt. Đừng đợi nó phình lên rồi mới viết. Ngán lắm :cry:
[4/16/2017, 5:56:25 AM] [lucdang]: ```
As all good designers know, semantic markup is king
1 - Every element in the page that wraps specific content should have a class or id attribute applied to it that identifies that content.
2 - The right tags should be used for the right content
3 - Styling should be done at the CSS level and never on the element direct ly
Link: Rails AntiPatterns at 107 page.
```
[4/16/2017, 5:59:57 AM] [lucdang]: Ngán hok, product owner gạt tiền vào má bốp bốp là tỉnh liền à e.
Hết ngán hahaha
[4/16/2017, 8:15:46 PM] [hieu.huynh]: :notbad:
[4/16/2017, 9:26:24 PM] [tucq88]: #til Elvis Operator `?:` for smarter code
<https://en.wikipedia.org/wiki/Elvis_operator>
[4/16/2017, 9:37:19 PM] [ko luong thien]: what a name
[4/17/2017, 12:59:24 AM] [giangnh]: #til tokio-rs + libcurl
```
// Create an event loop that we'll run on, as well as an HTTP `Session`
// which we'll be routing all requests through.
let mut lp = Core::new().unwrap();
let session = Session::new(lp.handle());
// Prepare the HTTP request to be sent.
let mut req = Easy::new();
req.get(true).unwrap();
req.url("<https://www.rust-lang.org>").unwrap();
req.write_function(|data| {
io::stdout().write_all(data).unwrap();
Ok(data.len())
}).unwrap();
// Once we've got our session, issue an HTTP request to download the
// rust-lang home page
let request = session.perform(req);
// Execute the request, and print the response code as well as the error
// that happened (if any).
let mut req = lp.run(request).unwrap();
println!("{:?}", req.response_code());
```
[4/18/2017, 6:43:12 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til <http://stackoverflow.com/questions/35464067/flexbox-not-working-on-button-element-in-some-browsers>
[4/18/2017, 7:02:14 AM] [ko luong thien]: a có xem cái này k a <https://github.com/philipwalton/flexbugs>
[4/18/2017, 7:15:54 AM] [tay vịn của anh bán chuối - cty A tìm FE]: uhm, anh có biết list này, nhưng mà lười đọc, giờ gặp bug :lol:
[4/18/2017, 6:34:54 PM] [alias Trung.Le, as tle]: &gt; the annual risk of a given person being hit by a meteorite is estimated to be one chance in 17 billion, which means the probability is about 0.00000000006 (6 × 10−11), equivalent to the odds of creating a few tens of trillions of UUIDs in a year and having one duplicate. In other words, only after generating 1 billion UUIDs every second for the next 100 years, the probability of creating just one duplicate would be about 50%. #til
[4/18/2017, 9:29:11 PM] [ko luong thien]: e gặp bug xong mới biết nó :v
[4/18/2017, 11:56:38 PM] [giangnh]: Create image url with Blob API
```
const imageURL = 'some_url';
const img = document.createElement('image');
var xhr = new XMLHttpRequest;
xhr.open('get', imageURL);
xhr.responseType = 'arraybuffer';
xhr.onload = function (e) {
const url = window.URL.createObjectURL(e.target.result); // "blob:<http://localhost/UUID>
img.src = url;
document.body.appendChild(img);
};
xhr.send();
```
[4/19/2017, 12:18:31 AM] [alias Trung.Le, as tle]: @giangnh fetch time
[4/19/2017, 2:43:20 AM] [giangnh]: Anh @tle dùng fetch em chưa tìm được cách listen cái event `onprpgress` để feedback lại có bao nhieu bytes đã được upload.
[4/19/2017, 2:43:31 AM] [giangnh]: nên giờ em vẫn dùng xhr :slightly_smiling_face:
[4/19/2017, 3:01:29 AM] [tucq88]: lol co han 1 repo ve flex bugs ah
[4/19/2017, 3:01:40 AM] [tucq88]: trc lam flexbox tren safari painful vai chuong :disappointed:
[4/19/2017, 3:01:48 AM] [ko luong thien]: bug nhiều hơn a nghĩ đấy :-&lt;
[4/19/2017, 3:27:24 AM] [tay vịn của anh bán chuối - cty A tìm FE]: em đang có bug bên IE11
[4/19/2017, 3:27:33 AM] [tay vịn của anh bán chuối - cty A tìm FE]: mà lầy lầy chưa sửa nữa :v
[4/20/2017, 4:35:46 PM] [alias Trung.Le, as tle]: Cái đó anh chưa đụng vào sâu nên cũng hóng
[4/23/2017, 10:29:20 PM] [ko luong thien]: WAIT NO MORE MY FRIENDS!
[4/23/2017, 10:29:22 PM] [ko luong thien]: <https://fetch.spec.whatwg.org/#fetch-api>
[4/23/2017, 10:29:26 PM] [ko luong thien]: TLDR: you can't
[4/23/2017, 10:29:41 PM] [ko luong thien]: &gt; The fetch() method is relatively low-level API for fetching resources. It covers slightly more ground than XMLHttpRequest, although it is currently lacking when it comes to request progression (not response progression).
[4/23/2017, 10:30:43 PM] [ko luong thien]: Longer version: you can, but it is quite complicated.. like reading the content length, and continuously check how much bytes have been downloaded.. I haven't do this, but some said that..
[4/23/2017, 10:31:38 PM] [ko luong thien]: my choice is a fake progress bar.. it will fill 50% of remaining progress after every x seconds, and fast forward to 100% on done
[4/24/2017, 6:28:09 AM] [hieu.huynh]: #til <https://github.com/hieuhtr/Blog/issues/35>
:troll:
[4/24/2017, 7:04:02 AM] [hasagi]: nhắc tới đau lưng
[4/24/2017, 7:04:04 AM] [hasagi]: :confused:
[4/24/2017, 7:04:14 AM] [hasagi]: có ai thấy bị đau lưng ko :joy:
[4/24/2017, 7:04:18 AM] [hasagi]: nguy hiểm vãi
[4/24/2017, 7:07:53 AM] [hieu.huynh]: :police_car: #random
[4/24/2017, 7:10:29 AM] [hasagi]: Ủa lộn room sr
[4/24/2017, 8:31:13 PM] [meowwwwwwwwwwwwwwww]: @hieu.huynh Sao em viet crontab trong Ubuntu ma no khong chay. ta :disappointed:
[4/24/2017, 8:32:01 PM] [hieu.huynh]: không chạy sao :think:
[4/24/2017, 8:32:14 PM] [hieu.huynh]: quăng cái `crontab -l` lên coi thử
[4/24/2017, 8:32:18 PM] [meowwwwwwwwwwwwwwww]: */1 * * * * /home/framgia/Desktop/Water.sh
[4/24/2017, 8:32:35 PM] [hieu.huynh]: :notbad:
[4/24/2017, 8:32:57 PM] [hieu.huynh]: cái guide này viết cho apple mà, bằng applescript
[4/24/2017, 8:33:14 PM] [meowwwwwwwwwwwwwwww]: em chay dc script = cai notify-send
[4/24/2017, 8:33:38 PM] [meowwwwwwwwwwwwwwww]: notify-send "Hey, Tran Xuan Nam" "Ngồi thẳng lưng + uống nước ngay." --urgency=critical --icon=warning --expire-time=6000
[4/24/2017, 8:33:42 PM] [hieu.huynh]: à, đã modify lại script cho ubuntu rồi hả
[4/24/2017, 8:33:48 PM] [meowwwwwwwwwwwwwwww]: uhm anh,
[4/24/2017, 8:33:54 PM] [meowwwwwwwwwwwwwwww]: em chạy file sh bằng tay thì được.
[4/24/2017, 8:33:56 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: sai cú pháp crontab rồi
[4/24/2017, 8:33:58 PM] [hieu.huynh]: cho nó quyền execute chưa?
[4/24/2017, 8:34:09 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: 5 cái * lận
[4/24/2017, 8:34:40 PM] [meowwwwwwwwwwwwwwww]: */1 * * * * /home/framgia/Desktop/Water.sh
[4/24/2017, 8:34:47 PM] [hieu.huynh]: ừ há, có 5 cái dấu * để set datetime lận, thiếu 1 cái rồi
[4/24/2017, 8:34:57 PM] [hieu.huynh]: <https://crontab.guru/>
[4/24/2017, 8:35:08 PM] [meowwwwwwwwwwwwwwww]: không anh ơi. có 5 cái, mà lên đây markdown nó che mất 1 cái rồi (khoc)
[4/24/2017, 8:35:08 PM] [hieu.huynh]: lên đây check cái cấu hình scheduler
[4/24/2017, 8:35:18 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: wrap code đi
[4/24/2017, 8:35:43 PM] [hieu.huynh]: &gt; cho nó quyền execute chưa?
[4/24/2017, 8:36:20 PM] [meowwwwwwwwwwwwwwww]: `*/1 * * * * /home/framgia/Desktop/Water.sh`
[4/24/2017, 8:38:08 PM] [meowwwwwwwwwwwwwwww]: <http://imgur.com/a/Mkj9e>
[4/24/2017, 8:40:11 PM] [hieu.huynh]: có thấy nó báo cái mail nào không?
vô `/var/mail/` xem thử :think:
[4/24/2017, 8:40:54 PM] [hieu.huynh]: debug bọn crontab này bằng mail, nếu có issue gì thì nó sẽ bắn 1 cái mail tới, mở cái mail ra để coi lỗi
[4/24/2017, 8:42:49 PM] [meowwwwwwwwwwwwwwww]: ```/var/mail/``` không thấy gì :cry:
[4/24/2017, 8:44:03 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: `grep -i cron /var/log/syslog`
[4/24/2017, 8:44:10 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: xem nó có chạy trước ko đã
[4/24/2017, 8:44:48 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: mà em chạy từng phút thì `* * * * * ` là đc rồi, ko cần `*/1`
[4/24/2017, 8:45:25 PM] [hieu.huynh]: uống nước từng phút luôn hả :notbad:
[4/24/2017, 8:46:07 PM] [meowwwwwwwwwwwwwwww]: @hieu.huynh test mà anh :disappointed:
[4/24/2017, 8:46:11 PM] [meowwwwwwwwwwwwwwww]: ```
Apr 25 10:45:01 framgiaa CRON[30912]: (framgia) CMD (/home/framgia/Desktop/Water.sh)
Apr 25 10:45:01 framgiaa CRON[30911]: (root) CMD (command -v debian-sa1 &gt; /dev/null &amp;&amp; debian-sa1 1 1)
```
[4/24/2017, 8:47:37 PM] [meowwwwwwwwwwwwwwww]: sao nó vẫn chạy, mà lại không ra cái qq gì cả là sao ta :cry:
test nó chạy mà nhỉ ? :cry:
[4/24/2017, 8:48:00 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: vậy là nó chạy rồi đó, em thử sửa lại cái script đi
[4/24/2017, 8:48:10 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: thêm 1 phần log ra file ở đâu đó
[4/24/2017, 8:48:39 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: ví dụ thêm `touch /home/framgia/Desktop/ahihi.log` :sexy:
[4/24/2017, 8:50:45 PM] [hieu.huynh]: hmmm, đúng là nó đã chạy, sao nó ko bắn ra noti gì nhỉ?
[4/24/2017, 8:51:21 PM] [meowwwwwwwwwwwwwwww]: :)) em cũng chạy được = tay mà không có notify gì đó anh (khoc)
[4/24/2017, 8:58:51 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: bt em ơi, check như anh nói đi
[4/24/2017, 9:01:41 PM] [meowwwwwwwwwwwwwwww]: @xluffy em check rồi. có có touch hằng phút anh ơi
[4/24/2017, 9:01:55 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :smile:
[4/24/2017, 9:02:37 PM] [hieu.huynh]: quăng cái file script với cái chỗ permission lên sem thử :think:
[4/24/2017, 9:02:52 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: vậy có thể là `notify-send` ko work với crontab, search từ khóa `notify-send crontab` đi em, là ra à
[4/24/2017, 9:04:39 PM] [hieu.huynh]: &gt; <https://askubuntu.com/a/298622/668849>
[4/24/2017, 9:04:42 PM] [hieu.huynh]: :think:
[4/24/2017, 9:05:08 PM] [hieu.huynh]: có cái `/usr/bin/notify-send` hông?
[4/24/2017, 9:13:33 PM] [meowwwwwwwwwwwwwwww]: có đại ca
[4/24/2017, 9:14:06 PM] [hieu.huynh]: :lol: magic
[4/24/2017, 9:17:02 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: em xem mấy cái về DISPLAY hay Xserver á, do khi em run nó ở môi trường có giao diện nên nó work bt, nhưng khi chạy crontab thì ko chắc
[4/24/2017, 10:45:04 PM] [meowwwwwwwwwwwwwwww]: em thử export DISPLAY=:0 rồi mà vẫn không được (khoc)
[4/24/2017, 11:04:36 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: export là sai roài
[4/24/2017, 11:08:24 PM] [meowwwwwwwwwwwwwwww]: đại ca có cao kiến nào không? em search google thấy mấy thằng nó chỉ thía mà :3
[4/24/2017, 11:12:03 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: a ko có dùng ubuntu nên ko test cho em đc, default cái biến DISPLAY nó có rồi, em cần xem nó hiện tại là gì rồi đem vào script mà xài
[4/24/2017, 11:13:27 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: nói chung quanh quanh cái DISPLAY, DBUS_SESSION_BUS_ADDRESS
[4/24/2017, 11:13:32 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: mấy cái đó đó thôi
[4/24/2017, 11:16:21 PM] [meowwwwwwwwwwwwwwww]: em `echo $DISPLAY` nó ra :0
[4/24/2017, 11:32:10 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: giờ em export rồi thì nó là vậy là đúng rồi
[4/24/2017, 11:38:37 PM] [meowwwwwwwwwwwwwwww]: ý em là em echo trong cái cmd á anh. chứ không echo trong crontab.
[4/25/2017, 5:18:43 AM] [meowwwwwwwwwwwwwwww]: @xluffy , <@U1Z3R6W8Y>
Em làm được rồi 2 bác ạ (tungtang)
```
eval "export $(egrep -z DBUS_SESSION_BUS_ADDRESS /proc/$(pgrep -u $LOGNAME gnome-session)/environ)";
DISPLAY=:0 notify-send "Hey, Tran Xuan Nam" "Keep your back straight and drink water!"
```
[4/25/2017, 12:47:37 PM] []: chạy crontab cái này tốn nhiều tài nguyên ko bác. khi `login window` thì có chạy ko bác.
[4/25/2017, 7:27:08 PM] [hieu.huynh]: câu hỏi hay đó @dungtv, việc bắn notification thì không tốn quá nhiều tài nguyên đâu
[4/25/2017, 7:27:29 PM] [hieu.huynh]: nhưng tài nguyên để crontab schedule thì mình chưa biết :think: để đi research phát
[4/25/2017, 7:27:49 PM] [hieu.huynh]: còn `khi login window thì có chạy ko` này hổng hiểu câu hỏi
[4/25/2017, 7:37:15 PM] [hieu.huynh]: ủa mà có hiểu tại sao phải export rồi egrep rồi DISPLAY các thứ không :think:
[4/25/2017, 8:01:30 PM] [hieu.huynh]: mới check, crontab không tốn nhiều resource nha
[4/25/2017, 8:20:34 PM] []: thanks bác (like)
à khi logout account ra í bác, ko biết nó có chạy ko.
[4/25/2017, 9:50:51 PM] [giangnh]: #til `&amp;[T] # [T; N]`
[4/26/2017, 12:45:36 AM] [ko luong thien]: #til the second part of border-radius thank to @nhducit <@U1A3P75CZ> <@U0GECN1NH>
&gt; The border-radius property is specified as:
&gt; - one, two, three, or four &lt;length&gt; or &lt;percentage&gt; values. This is used to set a single radius for the corners.
&gt; *- followed optionally by "/" followed by one, two, three, or four &lt;length&gt; or &lt;percentage&gt; values. This is used to set an additional radius, so you can have elliptical corners.*
[4/26/2017, 12:46:23 AM] [ko luong thien]: in other words: `border-radius: 10px 5% / 20px;`
more (that not specs): <https://developer.mozilla.org/en-US/docs/Web/CSS/border-radius?v=example>
[4/26/2017, 1:22:36 AM] [tucq88]: read 3 times but still not very clear :-s @thien
[4/26/2017, 1:26:04 AM] [tay vịn của anh bán chuối - cty A tìm FE]: @tucq88 qua #front-end có use case cụ thể đó a
[4/26/2017, 1:55:16 AM] [sondnm]: #til "A Linux system, just like UNIX, makes no difference between a file and a directory, since a directory is just a file containing names of other files."
[4/26/2017, 1:56:08 AM] [huy]: that's why you can't have file and directory with same name in same place
[4/26/2017, 2:00:20 AM] [unrealhoang]: then why can’t you `cat` a directory :omg:
[4/26/2017, 2:00:43 AM] [huy]: you can, it just return an error :stuck_out_tongue:
[4/26/2017, 2:36:10 AM] [ko luong thien]: #til a sad truth: Edge can't run on Windows 8.1, therefore IE11 is still MS's latest supported browser on Windows 8.1. Because Windows 8.1 will be supported until 2023, therefore IE11 will be supported officially by MS until 2023 along with Windows 8.1
[4/26/2017, 2:38:19 AM] [ko luong thien]: that also explained why the number of IE11 users will still be high: the number of Windows 7 to 8.1 users is still a lot more than Windows 10
[4/26/2017, 3:25:48 AM] [alias Trung.Le, as tle]: i also file or directory are described as inode in fs
[4/26/2017, 3:26:21 AM] [alias Trung.Le, as tle]: :facepalm:
[4/26/2017, 7:36:40 PM] []: #til `i` helper in iex will print relevant info about data structure you give, ex: `iex&gt; i 10`
[4/26/2017, 10:19:54 PM] [huy]: #til in bash, to pass exported value to child shell which use sudo, need -E option
[4/26/2017, 11:33:21 PM] [alias Trung.Le, as tle]: TIL splunk supports piping like UNIX, `rex` takes Perl regex to match data, `timechart`, `chart`, `streamstats` -- so MANY powerful functions
[4/26/2017, 11:36:42 PM] []: Splunk là vô đối rồi
[4/26/2017, 11:36:57 PM] []: Chỉ là ko có tiền xài thôi :v
[4/28/2017, 9:11:11 AM] [ko luong thien]: #til to use
```.item + .item { border-bottom: solid }
```
as an alternative for
```.item { border-bottom: solid }
.item:last-child { border-bottom: none }
```
thank to @quangnpd
[4/28/2017, 9:49:50 AM] [giangnh]: #rustlang để convert giữa 2 type khác nhau bạn có thể dùng trait `From` hoặc `Into` nhưng bạn nên dùng `From` hơn là `Into`.
```
// doc
impl&lt;T, U&gt; Into&lt;U&gt; for T where U: From&lt;T&gt;
```
Ví dụ:
```
use std::convert::From;
#[derive(Debug)]
struct Y;
#[derive(Debug)]
struct X;
impl From&lt;Y&gt; for X {
fn from(y: Y) -&gt; X {
X
}
}
fn main() {
let y = Y {};
let x: X = y.into();
println!("Debug x: {:?}", x); // X
}
```
[4/28/2017, 10:35:40 AM] [huy]: Why @giangnh ?
[4/28/2017, 10:50:46 AM] [giangnh]: Vì document ở trên đó @snacky
```
impl&lt;T, U&gt; Into&lt;U&gt; for T where U: From&lt;T&gt;
```
Cái này nó flexible hơn, ý ở đây là nếu muốn vào U từ T thì nên implement trait `From&lt;T&gt;` cho U
[4/28/2017, 10:51:08 AM] [giangnh]: Nên chỉ cần implement trait `From` là `Into` auto implement
[4/28/2017, 11:02:45 AM] [unrealhoang]: Cái này là vì không impl cho type mà không được định nghĩa trong crate của mình được
[4/28/2017, 11:04:17 AM] [unrealhoang]: Nên ví dụ của @giangnh chuyển qua into sẽ là `impl Into&lt;X&gt; for Y`
[4/28/2017, 11:04:33 AM] [unrealhoang]: Nếu Y mà là type từ crate khác
[4/28/2017, 11:04:40 AM] [unrealhoang]: Thì không làm đc
[4/28/2017, 11:06:50 AM] [huy]: đang nghĩ là cả From và Into đều là 2 cách giải quyết 1 vấn đề, kiểu top-down và bottom-up
[4/28/2017, 11:06:55 AM] [huy]: ko hiểu vì sao nó lại hiệu quả hơn
[4/28/2017, 11:09:51 AM] [huy]: 2 ông thần qua #rustlang bàn cái :disappointed:
[4/28/2017, 11:09:56 AM] [huy]: đi ngủ rồi à
[4/28/2017, 11:25:29 AM] [giangnh]: Trường hợp của anh @unrealhoang nói hay gặp nhất là foreign một error khác vào một error mình định nghĩa đó.
[5/1/2017, 6:01:44 AM] [manhdv]: <http://weblog.rubyonrails.org/2017/4/27/Rails-5-1-final/>
[5/1/2017, 9:45:22 PM] [manhdv]: <https://ruby-doc.org/core-2.2.0/Struct.html>
[5/3/2017, 7:59:46 PM] [giangnh]: #til linux perf tools full
<http://www.brendangregg.com/Perf/linux_perf_tools_full.png>
[5/3/2017, 9:40:16 PM] [hieu.huynh]: cái hình này hay á anh @giangnh
[5/3/2017, 9:40:36 PM] [hieu.huynh]: nó cho mình biết kiến trúc Operating system tổng thể nó như nào
[5/3/2017, 9:41:22 PM] [hieu.huynh]: và từng component của OS thì mình có tool nào để coi peformance và hỗ trợ debug
[5/3/2017, 9:42:42 PM] [hieu.huynh]: em đọc cái này từ mấy tháng trước, mà đến giờ mới hiểu dc có vài tool với vài component
[5/3/2017, 9:42:45 PM] [hieu.huynh]: :doubt:
[5/3/2017, 9:42:52 PM] [hieu.huynh]: OS coi vậy mà bự quá
[5/4/2017, 4:35:23 PM] [alias Trung.Le, as tle]: #til Apache Kylin
[5/4/2017, 8:08:50 PM] [tanlinhnd]: `$?` is a variable holding the return value of the last command. Usage example
```#!/bin/bash
ping -c 3 127.0.0.1
if [ $? -ne 0 ]; then
printf "Couldn't ping to 127.0.0.1"
fi
```
[5/4/2017, 10:07:53 PM] [Stephen]: A super simple and useful *text expander*. Only 27 sloc bash script.
<https://github.com/leehblue/texpander>
[5/6/2017, 3:35:14 AM] [dan]: #til `cd -` =&gt; `cd` to previous folder
[5/6/2017, 3:36:55 AM] [Stephen]: ^ or just `-` with `zsh` :wink:
[5/6/2017, 3:38:00 AM] [minh.nguyen]: or `cd ~3` to go to 3 previous folders in the directory stacks
[5/6/2017, 3:39:44 AM] [minh.nguyen]: `dirs` to view current directory stacks
[5/7/2017, 5:09:04 AM] [alias Trung.Le, as tle]: TIL <http://osxdaily.com/2007/03/05/manipulating-the-clipboard-from-the-command-line/>
[5/7/2017, 5:22:12 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til <https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Iteration_protocols>
[5/7/2017, 7:21:07 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til <https://developer.mozilla.org/en-US/docs/Web/JavaScript/Equality_comparisons_and_sameness>
[5/7/2017, 7:22:54 AM] [tay vịn của anh bán chuối - cty A tìm FE]: <http://dorey.github.io/JavaScript-Equality-Table/>
[5/11/2017, 1:50:55 AM] [manhdv]: #til keyword-arguments
<https://robots.thoughtbot.com/ruby-2-keyword-arguments>
[5/11/2017, 1:51:36 AM] [hasagi]: #til IEx.pry for debugging
[5/11/2017, 2:35:46 AM] [noob]: @runi_mage :roflrofl:
[5/11/2017, 2:38:23 AM] [hasagi]: cười cái gì vậy :think:
[5/11/2017, 2:38:39 AM] [noob]: :sexy:
[5/11/2017, 8:29:22 AM] []: #til raising limit of file descriptors
<https://underyx.me/2015/05/18/raising-the-maximum-number-of-file-descriptors>
[5/11/2017, 8:45:30 AM] [huynh.cam]: Điểm trừ của bare metal: Sẽ có những lúc lỏng dây
[5/11/2017, 10:57:27 AM] [hieu.huynh]: nhưng thực chất con instance này RAM 4GB, nó đang free tận 3.4GB :expressionless: RAM dư quá dư để chạy
[5/11/2017, 6:14:49 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: @hieu.huynh kiếm bài của anh trên kipalog đọc về cái buffers và cached nhé
[5/11/2017, 6:15:33 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: cái (available) 3419 ~ free + buffers + cached
[5/11/2017, 6:58:04 PM] [meowwwwwwwwwwwwwwww]: #til forty_two
Find the forty-second record
:think:
[5/11/2017, 7:52:06 PM] [hieu.huynh]: càng đọc càng ngáo là sao ta anh @xluffy :thinking_face:
[5/11/2017, 7:52:38 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: trong mysql em có 1 cái gọi là inno_buffer á, em hiểu sao về cái đó
[5/11/2017, 7:53:05 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: tại sao khi em cấu hình, em luôn set nó ở mức cỡ 80% memory để làm gì?
[5/11/2017, 7:53:37 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: đọc thêm 1 bài về `vmtouch` anh có post trên kipalog luôn đi
[5/11/2017, 7:55:43 PM] [hieu.huynh]: khoan :think:
[5/11/2017, 7:55:55 PM] [hieu.huynh]: trở lại vấn đề xíu, cái hình của em bên trên á
[5/11/2017, 7:56:17 PM] [hieu.huynh]: như thế là có đang high RAM usage ko? em mù mờ quá
[5/11/2017, 7:57:25 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: cpu là sao :think: ở trên đang là memory mà
[5/11/2017, 7:57:43 PM] [hieu.huynh]: lộn tiệm, edited :joy:
[5/11/2017, 7:58:26 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: thì cái trên thì đúng là đang low memory mà
[5/11/2017, 7:58:43 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: con số em cần qtâm là 3419 là đúng rồi
[5/11/2017, 8:00:21 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: em xem bài vmtouch á, khi em đọc 1 file có kích thước 1 GB, nó sẽ load file đó vào memory và em sẽ thấy sự khác biệt giữa cái cột free/cache trước và sau khi load file
[5/11/2017, 8:01:16 PM] [hieu.huynh]: chỗ này `low memory usage`, hay còn quá ít ram để sử dụng?
[5/11/2017, 8:01:57 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: chỗ này là em đang dùng rất ít memory, còn lại cả mớ
[5/11/2017, 8:02:23 PM] [hieu.huynh]: à à à, ok agree agree :+1:
[5/11/2017, 8:02:34 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: total em có 4GB, em mới đang dùng có 512MB
[5/11/2017, 8:02:45 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: nếu em chỉ qtâm là nhìn con số nào mới đúng thì như ý em là đúng rồi
[5/11/2017, 8:02:59 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: còn nếu em muốn biết tsao lại như thế, thì 2 cái anh viết là về cái đó
[5/11/2017, 8:03:46 PM] [hieu.huynh]: để em đào 2 cái bài của anh :sexy:
[5/11/2017, 8:04:28 PM] [hieu.huynh]: - Đầu tiên là em đang rất muốn dc anh nào confirm là với cái hình của em bên trên, thì system em đang xài rất ít mem
- Sau đó là em muốn tìm hiểu thêm từng value trong này có ý nghĩa gì
[5/11/2017, 8:04:43 PM] [hieu.huynh]: giờ clear rồi :smile:
[5/11/2017, 8:04:53 PM] [hieu.huynh]: many thanks anh @xluffy :tada:
[5/11/2017, 8:05:10 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: cái này có rất nhiều cái liên quan, ví dụ như anh nói cái ở trên là `innodb_buffer_pool_size` hoặc WiredTiger cache trong mongodb, em hiểu cái đó sẽ hiểu tsao em lại setting như thế trong mysql
[5/11/2017, 8:09:11 PM] [hieu.huynh]: `innodb_buffer_pool_size` em chưa biết gì luôn :scream:
[5/11/2017, 8:09:32 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :neutral_face: ơ, xài mysql nhiều thế mà ko biết cái này là sao
[5/11/2017, 8:10:48 PM] [hieu.huynh]: kiến thức em còn lỗ hổng đủ thứ chỗ :disappointed:
[5/13/2017, 6:38:09 AM] [unrealhoang]: trong console thì Ctrl+a/e để tới đầu dòng/cuối dòng nhé
[5/13/2017, 6:40:54 AM] [hieu.huynh]: ngon vại :tada:
[5/13/2017, 8:26:56 AM] [trexnix]: ngoài `C-a`, `C-e` còn có `C-b`/`C-f` để move cursor backward/forward, `C-k` để xoá từ vị trí hiện tại đến cuối dòng. Những key-bindings này rất giống bên Emacs. Hình như có thể áp dụng cho bất cứ chỗ nào cho nhập liệu (đã thử test trong Chrome address bar, terminal, input/textarea HTML)
[5/13/2017, 8:56:05 AM] []: nó từ readline mà ra thì phải
[5/13/2017, 8:56:16 AM] []: có 1 từ khóa chung cho nó
[5/13/2017, 8:56:23 AM] []: gnu readline hay gnu vẹo gì đó
[5/13/2017, 8:56:35 AM] []: còn giống emacs tại emacs cũng gnu :v
[5/13/2017, 9:29:08 AM] [dan]: Có thể đổi sang kiểu của vim nếu muốn
[5/13/2017, 9:30:01 AM] [dan]: <http://vim.wikia.com/wiki/Use_vi_shortcuts_in_terminal>
[5/14/2017, 7:28:32 PM] [ko luong thien]: @unrealhoang cái này là emac style hở
[5/14/2017, 7:28:51 PM] [ko luong thien]: em đổi iterm sang hệ thống..
[5/14/2017, 7:40:29 PM] [huy]: #til Đối với bảng (`&lt;table&gt;`) quá dài thì có thể trim bớt các item cũ bằng cách dùng CSS (không cần JS)
```
table tr {
display: none;
}
table tr:nth-last-child(-n+20) {
display: table-row;
}
```
Đoạn CSS trên có tác dụng ẩn hết toàn bộ thẻ `tr` và chỉ show 20 cái `tr` cuối cùng.
[5/14/2017, 8:38:10 PM] [ko luong thien]: @snacky thảo luận phát
[5/14/2017, 8:38:17 PM] [ko luong thien]: thường tại sao a cần trim thế?
[5/14/2017, 8:38:34 PM] [ko luong thien]: bên em cần trim để tránh bị tràn bộ nhớ
[5/14/2017, 8:38:47 PM] [ko luong thien]: nếu vậy thì k dùng cách này được nhỉ?
[5/14/2017, 8:42:39 PM] [huy]: cái dashboard của a có 1 cái bảng
[5/14/2017, 8:42:49 PM] [huy]: show thông tin visit từng giây
[5/14/2017, 8:42:59 PM] [huy]: như hồi sáng lúc a share bài blog lên reddit
[5/14/2017, 8:43:05 PM] [huy]: thì cứ 10 giây có 1 visit
[5/14/2017, 8:43:07 PM] [huy]: douma
[5/14/2017, 8:43:18 PM] [huy]: sau 5 tiếng thì con số đó là như nào
[5/14/2017, 8:43:24 PM] [huy]: và nó render hết ra luôn :omg:
[5/14/2017, 8:43:49 PM] [ko luong thien]: vậy nếu a chặn bằng css
[5/14/2017, 8:43:56 PM] [ko luong thien]: thì trong memory vẫn còn lưu tụi nó
[5/14/2017, 8:43:59 PM] [ko luong thien]: chỉ là k hiện ra
[5/14/2017, 8:44:10 PM] [ko luong thien]: vậy cái vấn đề a gặp là liên quan UI?
[5/14/2017, 8:44:15 PM] [ko luong thien]: kiểu hiện nhiều quá thì k tốt?
[5/14/2017, 8:48:03 PM] [huy]: trong memory (1 cái array) nheièu quá thì cũng ko ảnh hưởng gì
[5/14/2017, 8:48:19 PM] [huy]: nhưng trên trang web
[5/14/2017, 8:48:24 PM] [huy]: render 10k cái thẻ TR
[5/14/2017, 8:48:27 PM] [huy]: là 1 chuyện lớn đó
[5/14/2017, 8:48:33 PM] [huy]: vậy nên trong đồ họa mới có kĩ thuật gọi là culling
[5/14/2017, 8:48:45 PM] [huy]: để xóa bớt những mặt khuất của 1 vật thể
[5/14/2017, 8:48:46 PM] [huy]: trên màn hình
[5/14/2017, 8:48:55 PM] [huy]: (khỏi tốn thời gian tính toán để hiển thị cho nó)
[5/14/2017, 8:48:56 PM] [ko luong thien]: ra thế
[5/14/2017, 8:49:08 PM] [ko luong thien]: em cũng chặn, nhưng e chặn từ js..
[5/14/2017, 8:49:10 PM] [huy]: UI thường tốn tiền hơn code logic mà
[5/14/2017, 8:49:20 PM] [ko luong thien]: bên e 1s nó đẩy 100 order lận..
[5/14/2017, 8:49:21 PM] [huy]: có nhiều trường hợp lắm
[5/14/2017, 8:49:28 PM] [ko luong thien]: nên mới thắc mắc
[5/14/2017, 8:49:29 PM] [huy]: ví dụ a muốn cái array vẫn nguyên vẹn
[5/14/2017, 8:49:33 PM] [ko luong thien]: sao a chặn css mà giữ js
[5/14/2017, 8:49:35 PM] [huy]: để ko ảnh hưởng kết quả tính toán
[5/14/2017, 8:49:38 PM] [huy]: nhưng UI thì ko đc show
[5/14/2017, 8:49:41 PM] [ko luong thien]: ò..
[5/14/2017, 8:50:21 PM] [ko luong thien]: hm
[5/14/2017, 8:50:24 PM] [ko luong thien]: mà e thắc mắc
[5/14/2017, 8:50:37 PM] [ko luong thien]: sao a quyết định display none ở css thay vì chặn lúc render?
[5/14/2017, 8:50:47 PM] [ko luong thien]: í là, lúc a render ra html thì a dùng js
[5/14/2017, 8:51:03 PM] [ko luong thien]: sao lúc đó thay vì render all, thì a render 20 cái cuối
[5/14/2017, 8:51:09 PM] [ko luong thien]: k phải thế đơn giản hơn hay sao?
[5/14/2017, 8:52:06 PM] [huy]: à vì a dùng firebase, nó đẩy dữ liệu về bằng websocket
[5/14/2017, 8:52:18 PM] [huy]: cứ mỗi khi có data mới thì a insert 1 element mới trực tiép vào bảng
[5/14/2017, 8:52:28 PM] [huy]: chớ ko dùng kiểu filtered array như angular
[5/14/2017, 8:52:32 PM] [huy]: hay loop như react
[5/14/2017, 8:52:34 PM] [huy]: hiểu hem
[5/14/2017, 8:53:22 PM] [ko luong thien]: dạ hiểu
[5/14/2017, 9:45:56 PM] [tay vịn của anh bán chuối - cty A tìm FE]: optimize thì cách đó chưa ngon @snacky
[5/14/2017, 9:46:03 PM] [tay vịn của anh bán chuối - cty A tìm FE]: vì nó vẫn sinh ra DOM
[5/14/2017, 9:58:18 PM] [huy]: uhm tại vì cách dùng websocket nhận data xong push liên tục đó
[5/14/2017, 9:58:31 PM] [huy]: nếu chạy loop để remove element bằng JS thì hơi tốn kém
[5/15/2017, 12:13:08 AM] [tay vịn của anh bán chuối - cty A tìm FE]: @snacky hmmm
[5/15/2017, 12:13:37 AM] [tay vịn của anh bán chuối - cty A tìm FE]: push websocket data vao 1 array
[5/15/2017, 12:13:49 AM] [tay vịn của anh bán chuối - cty A tìm FE]: moi lan render lay 20 items thoi
[5/15/2017, 12:14:07 AM] [tay vịn của anh bán chuối - cty A tìm FE]: render hết rồi đi remove chi cho khổ vậy :neutral_face:
[5/15/2017, 12:16:15 AM] [huy]: Vậy mỗi lần có data mới là lại phải chạy lệnh push, remove bớt item, rồi loop tiếp để render lại toàn bộ cái list à
[5/15/2017, 12:16:32 AM] [huy]: Làm vậy cách nào khổ hơn :omg:
[5/15/2017, 12:16:32 AM] [tay vịn của anh bán chuối - cty A tìm FE]: có dùng react hay angular hơm
[5/15/2017, 12:16:38 AM] [huy]: Ko
[5/15/2017, 12:16:41 AM] [huy]: Js chay mà
[5/15/2017, 1:06:32 AM] [ko luong thien]: cái đoạn remove bớt item cũng đơn giản mà :disappointed:
[5/15/2017, 1:06:34 AM] [ko luong thien]: .slice thôi
[5/15/2017, 1:06:50 AM] [ko luong thien]: có thêm cái đó, thì cái loop ở bước sau sẽ đỡ hơn nhiều
[5/15/2017, 1:18:11 AM] [tay vịn của anh bán chuối - cty A tìm FE]: ý mình là: có 1 hàm phụ render, lấy 20 items đầu tiên tạo dom =&gt; append vào parent
[5/15/2017, 1:18:39 AM] [tay vịn của anh bán chuối - cty A tìm FE]: mỗi lần nhận ws event thì trigger rerender
[5/15/2017, 1:19:27 AM] [tay vịn của anh bán chuối - cty A tìm FE]: cách này sẽ nhanh hơn css nếu có nhiều event
[5/16/2017, 4:31:03 PM] [huy]: #til ko bao gio duoc re-install gtk2 va gtk3
[5/16/2017, 9:24:31 PM] [giangnh]: <https://regex101.com/codegen?language=rust>
[5/16/2017, 10:50:24 PM] [alias Trung.Le, as tle]: #til không thể cứ hỏi lười, nếu không demo cho người khác thấy bạn đã bỏ ra công sức tìm lời giải thì không thể mong đợi người khác giúp mình. Nếu cho một vd thì đơn giản ghi rõ yêu cầu, input đầu vào là gì, output mong đợi là gì, lí do gì mà lại chọn cầu cứu người A thay vì người B, chỉ cần ghi rõ đủ ra thì 90% là tự giải đc, hoặc 90% sẽ đc người ta giúp
[5/16/2017, 10:51:42 PM] [huy]: @tle em có ý kiến, có 1 cái benefit từ việc này là: sau khi đã hệ thống hóa lại câu hỏi như thế, khả năng là người hỏi sẽ tự tìm ddc câu trả lời luôn và ko cần ai giúp nữa, cũng là 1 cách rát tốt để tự học
[5/16/2017, 10:52:03 PM] [huy]: hự, vừa đọc xong câu cuối, a có nói luôn rồi :luon:
[5/16/2017, 10:53:44 PM] [alias Trung.Le, as tle]: lol, ai cũng bận cả, chẳng ai có thời gian bỏ ra giúp cho ai, hoặc nếu bỏ ra thì đưa $. lol thực sự cách đặt câu hỏi cũng thể hiện xem người hỏi có tôn trọng những người tiếp nhận câu hỏi hay không
[5/16/2017, 10:55:07 PM] [huy]: nhiều khi là có tôn trọng câu hỏi không nữa
[5/16/2017, 10:56:24 PM] [alias Trung.Le, as tle]: lol
[5/16/2017, 10:56:35 PM] [alias Trung.Le, as tle]: anh té đi họp, gday e
[5/16/2017, 10:56:42 PM] [huy]: gday a
[5/16/2017, 11:39:05 PM] [alias Trung.Le, as tle]: #til people try to take down our ES by sending dirty regex input, need to up my game with input sanitisation
[5/16/2017, 11:47:01 PM] []: @tle Có example nào về dirty regex này không anh?
[5/16/2017, 11:47:18 PM] [alias Trung.Le, as tle]: để anh fix xong đã rồi sẽ share
[5/16/2017, 11:47:27 PM] []: :bow:
[5/16/2017, 11:47:29 PM] [alias Trung.Le, as tle]: không thì hacker nó đánh sập bên này mất
[5/17/2017, 1:21:53 AM] [ko luong thien]: dev có tâm :notbad:
[5/18/2017, 1:42:11 AM] [giangnh]: Cái này hay nhỉ <https://dzone.com/refcardz/getting-started-uml>
[5/18/2017, 6:16:18 AM] [hasagi]: @giangnh hay gì vậy
[5/18/2017, 6:16:21 AM] [hasagi]: :thinking_face:
[5/18/2017, 6:16:26 AM] [hasagi]: đúng là hay thật
[5/18/2017, 6:16:36 AM] [hasagi]: nhưng mà trước giờ ko xài trong product development à
[5/18/2017, 7:31:04 AM] [giangnh]: chỉ có vẽ use case với sequence diagrams chứ chưa dùng những loại UML khác
[5/18/2017, 7:32:24 AM] [hasagi]: :+1:
[5/18/2017, 9:10:18 AM] [huynh.cam]: #til how to avoid being an a**hole code reviewee? keep your changes small, keep your commits tidy, explain what you’re doing
[5/18/2017, 6:42:38 PM] [alias Trung.Le, as tle]: @hqc sometimes you can't keep it small, it'd be best to book a review session with the peer to walkthrough the PR together
[5/18/2017, 11:53:45 PM] [giangnh]: #til nodej crypto <https://nodejs.org/api/crypto.html>
[5/20/2017, 10:31:00 PM] [huy]: #til `yaourt -S redshift`
[5/20/2017, 11:18:29 PM] [Stephen]: @snacky Em vote xài `pacaur` =))
[5/20/2017, 11:29:22 PM] [huy]: =)))
[5/20/2017, 11:35:34 PM] []: Em cũng xài pacaur
[5/21/2017, 12:37:07 AM] [unrealhoang]: pacaur ftw
[5/21/2017, 12:42:29 AM] [huy]: sai roi, `pacman -Syyu` ftw
[5/21/2017, 12:42:50 AM] [huy]: **DO NOT TRY THIS AT HOME**
[5/21/2017, 12:57:07 AM] []: Yy là nó update cache thôi mà
[5/21/2017, 12:57:19 AM] []: :think:
[5/21/2017, 12:57:26 AM] [huy]: force update ma
[5/21/2017, 12:57:28 AM] [huy]: Syyu
[5/21/2017, 12:57:59 AM] []: Là Syu rồi auto y hả
[5/21/2017, 12:58:18 AM] [huy]: uhm
[5/21/2017, 12:58:23 AM] []: Hôm nọ bị corupted cache phải yy hay uu thì đó
[5/21/2017, 12:58:38 AM] []: Mà force update sao ko nên
[5/21/2017, 12:58:45 AM] []: Đường nào cuzng update mà
[5/21/2017, 12:58:53 AM] [huy]: update kernel nhiều khi ko đúng lúc
[5/21/2017, 12:58:55 AM] [huy]: như hôm bữa đó
[5/21/2017, 12:58:58 AM] [huy]: update xong
[5/21/2017, 12:59:01 AM] [huy]: ko restart
[5/21/2017, 12:59:06 AM] [huy]: lại đi reinstall gtk
[5/21/2017, 12:59:07 AM] []: Ăn ở đó
[5/21/2017, 12:59:08 AM] [huy]: :roflrofl:
[5/21/2017, 12:59:12 AM] []: Em chưa bị bao giờ
[5/21/2017, 12:59:26 AM] []: Mặc dù lần nào xài máy em cũng update trước rồi mới xài
[5/21/2017, 12:59:59 AM] [huy]: :think:
[5/21/2017, 1:00:04 AM] [huy]: update ngày một à
[5/21/2017, 1:00:18 AM] []: Ko
[5/21/2017, 1:00:22 AM] []: Thế này mới đúng
[5/21/2017, 1:00:24 AM] []: <https://goo.gl/images/NQ5kky>
[5/21/2017, 1:00:27 AM] [huynh.cam]: các bác vào thread đê :neutral_face:
[5/21/2017, 1:00:45 AM] [huy]: lol
[5/21/2017, 1:00:55 AM] []: Trên mobile ko tạo thread đc
[5/21/2017, 1:01:10 AM] [huynh.cam]: @anhduy bấm một cái vào message :smile:
[5/21/2017, 1:01:17 AM] []: À
[5/21/2017, 1:01:22 AM] []: Em toàn đè nó
[5/21/2017, 1:01:32 AM] [huynh.cam]: :smile: trc a cũng vại
[5/21/2017, 1:01:37 AM] []: @snacky em update mỗi khi chán ngồi suy nghĩ
[5/21/2017, 1:01:44 AM] [huy]: vcl
[5/21/2017, 1:01:44 AM] []: Nên ngày chạy vài lần
[5/21/2017, 1:01:45 AM] [huy]: :rip:
[5/21/2017, 8:03:51 AM] [Stephen]: #til `yarn` is amazing fast compare to `npm`
[5/21/2017, 10:38:47 PM] [alias Trung.Le, as tle]: #til GNOME Podomoro app <https://lleksah.wordpress.com/2017/05/20/setting-gnome-pomodoro-a-time-limit-app/> cc @snacky
[5/21/2017, 10:44:17 PM] [huy]: I tried to be friendly with GNOME and that Wayland thing. But my poor x220 could not. :( But the pomodoro is cool :think:
[5/21/2017, 10:48:17 PM] []: say no to GNOME
[5/21/2017, 10:48:26 PM] []: too many dependencies
[5/22/2017, 12:02:34 AM] [alias Trung.Le, as tle]: @anhduy wot?!
[5/22/2017, 12:02:38 AM] [alias Trung.Le, as tle]: look at KDE, FFS
[5/22/2017, 12:02:44 AM] [alias Trung.Le, as tle]: it is even worse
[5/22/2017, 12:03:11 AM] [alias Trung.Le, as tle]: I think GNOME is the only `desktop` solution that really cares about UI/UX
[5/22/2017, 12:03:26 AM] [alias Trung.Le, as tle]: the other solutions are merely `window manager` than a `desktop`
[5/22/2017, 12:06:08 AM] [giangnh]: #til <http://draw.io|draw.io> + github
[5/22/2017, 12:08:50 AM] [huy]: @giangnh thành cái gì?
[5/22/2017, 12:09:26 AM] [huy]: Agree. And we still use WM :D
[5/22/2017, 12:10:57 AM] [giangnh]: khoong biet no thanh gi, nhưng thiết kế UML rồi commit lên github, team có thể theo dõi được khá là tiện.
[5/22/2017, 12:13:15 AM] [hieu.huynh]: bên em xài google drive
[5/22/2017, 12:13:28 AM] [hieu.huynh]: :think:
[5/22/2017, 12:13:47 AM] []: WM ftw
[5/22/2017, 12:44:56 AM] [unrealhoang]: WM ftw
[5/22/2017, 7:47:22 AM] [alias Trung.Le, as tle]: RatpoisonWM
[5/22/2017, 7:47:24 AM] [alias Trung.Le, as tle]: FTW
[5/22/2017, 5:56:16 PM] [alias Trung.Le, as tle]: có một tool khác cũng khá hay mà bên mình hay dùng
[5/22/2017, 5:56:27 PM] [alias Trung.Le, as tle]: nếu đụng vào phải vẽ sequence diagram
[5/22/2017, 5:56:28 PM] [alias Trung.Le, as tle]: <https://www.websequencediagrams.com/>
[5/22/2017, 5:56:37 PM] [alias Trung.Le, as tle]: code bằng text rồi nó tự vẽ ra cho mình
[5/22/2017, 5:57:25 PM] [huy]: :think:
[5/22/2017, 5:57:28 PM] [huy]: mình thì vẽ tay
[5/22/2017, 5:57:33 PM] [huy]: ae chơi tool đồ ghê quá :cry:
[5/22/2017, 5:57:54 PM] [huy]: á cái tool a @tle send nhìn zui quá
[5/22/2017, 5:58:06 PM] [alias Trung.Le, as tle]: mấy ông architect bên anh dùng cái đó
[5/22/2017, 5:58:28 PM] [huy]: :+1:
[5/22/2017, 7:42:28 PM] [giangnh]: tool cua anh @tle nhin hay hay nhi
[5/23/2017, 12:11:29 AM] [huy]: #til chớ dại mà đắc tội với các lão đại :arggg:
[5/23/2017, 1:45:37 AM] [alias Trung.Le, as tle]: #til <https://www.microsoft.com/en-us/cognitive-toolkit/>
[5/23/2017, 8:05:43 AM] []: #til “3 JavaScript questions to watch out for during coding interviews” @borowskidaniel <https://medium.freecodecamp.com/3-questions-to-watch-out-for-in-a-javascript-interview-725012834ccb>
[5/23/2017, 7:19:54 PM] []: #til Bash CheatSheet for UNIX Systems
<https://gist.github.com/LeCoupa/122b12050f5fb267e75f>
[5/24/2017, 5:54:26 AM] [Stephen]: #til <https://github.com/google/yapf>
Yet Another Python Formatter from Google™
[5/24/2017, 5:54:38 AM] [Stephen]: IMHO, cooler than `autopep8`
[5/24/2017, 7:08:22 AM] [mido]: #til dùng “with” trong Elixir để code dễ đọc hơn
<https://blog.drewolson.org/elixirs-secret-weapon/?utm_campaign=elixir_radar_96&amp;utm_medium=email&amp;utm_source=RD+Station>
[5/24/2017, 9:54:57 PM] [alias Trung.Le, as tle]: #til khi vào vai trò mentor thì kỹ năng lắng nghe và phải biện cực kỳ quan trọng, lắng nghe thay vì đưa ra quan điểm để cho người hỏi có thể tự do dãi bày họ nghĩ gì, cùng lúc đó cũng luôn phải phản biện, phản biện không phải để đánh phủ đầu người ta, phản biện khác từ chối quan điểm nhé, phản biện để giúp người trình bày phải nói ra hết tất cả những gì họ đã lên kế hoạch trước khi tiếp cận, đa số khi hỏi đc thì người hỏi đã biết mình thiếu sót khúc nào để có thể tự giải quyết. Mentor giỏi là mentor chỉ làm công tác lái người hỏi đến câu trả lời chứ không phải là đi trả lời họ cho người ta. Cái này hi vọng một số bạn sắp tới tham gia Geeky Weekend với vai trò mentor lần đầu nên lưu ý
[5/24/2017, 11:34:21 PM] [giangnh]: #til `npm config ls -l` tất cả config của npm
[5/25/2017, 9:11:40 PM] [meowwwwwwwwwwwwwwww]: #til `class_eval` will create instance methods, `instance_eval` will create class methods
[5/25/2017, 11:20:19 PM] [alias Trung.Le, as tle]: #til `dynamic_templates` in ES is so powerful
[5/25/2017, 11:50:09 PM] [Stephen]: #til Trong firefox chỉnh `browser.chrome.favicon = False` để tắt tự động request `favicon.ico`; hữu ích cho bạn nào thử nghiệm rest server một cách simple, và không hiểu báo lỗi favicon.ico ở đâu
```
(sanic)[ERROR]: Traceback (most recent call last):
File "/lib/python3.6/site-packages/sanic/app.py", line 461, in handle_request
handler, args, kwargs, uri = self.router.get(request)
File "/lib/python3.6/site-packages/sanic/router.py", line 290, in get
return self._get(request.path, request.method, '')
File "/lib/python3.6/site-packages/sanic/router.py", line 339, in _get
raise NotFound('Requested URL {} not found'.format(url))
sanic.exceptions.NotFound: Requested URL /favicon.ico not found
```
[5/25/2017, 11:54:48 PM] [Stephen]: aka #til firefox tự động bất chấp request `/favicon.ico`
[5/27/2017, 5:49:10 AM] []: #til Traversable
[5/27/2017, 6:15:05 AM] [unrealhoang]: @anhduy là sao thế. Giải thích đi cưng
[5/27/2017, 6:15:37 AM] [unrealhoang]: Như iterable à
[5/27/2017, 6:18:31 AM] []: À, ví dụ cưng cần viết một hàm
[5/27/2017, 6:18:52 AM] []: Đổi từ char -&gt; morse code
[5/27/2017, 6:22:03 AM] []: hay nôm na từ type A sang type B bất kì
[5/27/2017, 6:22:12 AM] []: nhưng có thể xảy ra lỗi
[5/27/2017, 6:22:20 AM] []: thì phải dùng Option đúng ko
[5/27/2017, 6:22:28 AM] []: A -&gt; Option B
[5/27/2017, 6:22:42 AM] [unrealhoang]: Either/Result
[5/27/2017, 6:22:44 AM] [unrealhoang]: Umm
[5/27/2017, 6:22:48 AM] []: nên giả sử có 1 hàm f1 kiểu A -&gt; Option B
[5/27/2017, 6:23:00 AM] []: giờ cưng có 1 list A
[5/27/2017, 6:23:15 AM] []: cưng convert nó sang list B
[5/27/2017, 6:23:24 AM] []: thì nếu dùng f1 có sẵn
[5/27/2017, 6:23:38 AM] []: nó sẽ thành List Option B
[5/27/2017, 6:23:42 AM] []: đúng ko
[5/27/2017, 6:23:47 AM] [unrealhoang]: Đúng
[5/27/2017, 6:24:10 AM] []: nhưng cái đó ko xịn lắm, nếu nó thành Option List B thì xịn hơn đúng ko
[5/27/2017, 6:24:36 AM] [unrealhoang]: À
[5/27/2017, 6:24:42 AM] []: nên mong muốn cần viết 1 cái f2 kiểu
[5/27/2017, 6:24:53 AM] []: `f2 :: [a] -&gt; Option [b]`
[5/27/2017, 6:25:13 AM] []: trong khi có `f1 :: a -&gt; Option b`
[5/27/2017, 6:25:26 AM] [unrealhoang]: Uhm
[5/27/2017, 6:25:38 AM] []: thì đó là lúc dùng traversable
[5/27/2017, 6:26:04 AM] []: nó sẽ map thành List Option b, xong đổi chỗ List và Option cho cưng
[5/27/2017, 6:26:23 AM] [unrealhoang]: Uhm
[5/27/2017, 6:26:34 AM] [unrealhoang]: Ok
[5/27/2017, 6:26:40 AM] []: sẽ thuận tiện lúc validation các kiểu đó
[5/27/2017, 6:27:06 AM] [unrealhoang]: Bên haskell thì type của wrapper vẫn đc giữ đúng ko
[5/27/2017, 6:27:19 AM] []: là sao cưng
[5/27/2017, 6:28:19 AM] [unrealhoang]: Ví dụ là cái list đó không phải là list thường
[5/27/2017, 6:28:43 AM] [unrealhoang]: Mà là Queue chẳng hạn
[5/27/2017, 6:28:58 AM] [unrealhoang]: Thì cái kết quả sẽ là option queue
[5/27/2017, 6:29:44 AM] []: với điều kiện cái Queue phải implement Traversable
[5/27/2017, 8:37:54 AM] [huy]: Lặp-able à
[5/28/2017, 4:19:15 AM] [ko luong thien]: @tle I can't find info about that when search for the string "js dynamic template". Can you share?
[5/28/2017, 4:19:21 AM] [ko luong thien]: is it related with <https://www.styled-components.com/docs/advanced#tagged-template-literals> ?
[5/28/2017, 9:31:44 AM] [huynh.cam]: #til `&lt;meta charset="utf-8"&gt;` :facepalmanim:
[5/28/2017, 9:41:41 AM] []: không cưng
[5/28/2017, 9:41:45 AM] []: như giải thích ở trên á
[5/28/2017, 4:07:44 PM] [alias Trung.Le, as tle]: @thien lol no, it is not for JS, ES here means ElasticSearch
[5/28/2017, 6:35:14 PM] [alias Trung.Le, as tle]: ES != ES6 LOL
[5/29/2017, 1:47:02 AM] [giangnh]: #til <#C3HGW0MFZ|rustlang> `1_000_000 == 1000000`
[5/29/2017, 2:48:27 AM] [ko luong thien]: Some use ES when mentioning JS..
[5/29/2017, 3:02:18 AM] [manhdv]: #til
`ls ^`
[5/29/2017, 3:06:09 AM] [manhdv]: #til
Store DB to RAM disk to speedup test on Mac and mysql 5.17.8
```
#!/bin/bash
# Create 1GB RAM disk
diskutil erasevolume HFS+ "ramdisk" `hdiutil attach -nomount <ram://2097152>`
# Install mysql to above ramdisk, with no password
mysqld --initialize-insecure --log-error-verbosity --user=`whoami` --basedir="$(brew --prefix mysql)" --datadir=/Volumes/ramdisk/mysql --tmpdir=/tmp
# Stop current mysql if existing
mysql.server stop
# Start mysql with new data dir on ramdisk
mysql.server start --datadir=/Volumes/ramdisk/mysql
```
[5/29/2017, 3:08:27 AM] [huy]: `ls ^` de lam gi the @manhdv
[5/29/2017, 3:13:10 AM] [manhdv]: Nó liệt kê thư mục hiện tại, sort theo alphabet và liệt kê nội dung thư mục con với độ sâu 1 anh huydx ạ
```
List information about the FILEs (the current directory by default). Sort entries alphabetically if none
of -cftuvSUX nor --sort is specified.
```
Kiểu này này anh:
<https://gyazo.com/ea2e8df4e22cf8ab33363d95e0ce41eb>
Để xem overview cũng khá tiện, em nghĩ thế :smile:
[5/29/2017, 3:15:04 AM] [huy]: the khac gi `tree -L 2` ko em
[5/29/2017, 3:15:27 AM] [manhdv]: em ko go duoc `tree -L 2` tren mac
[5/29/2017, 3:15:37 AM] [manhdv]: nen search thu thay co cai nay tam thay the duoc :neutral_face:
[5/29/2017, 3:15:54 AM] [SFzxc]: @manhdv e ko đc bác ơi `ls: ^: No such file or directory`
[5/29/2017, 3:15:56 AM] [huy]: a vua go tren mac ma
[5/29/2017, 3:15:57 AM] [SFzxc]: :think:
[5/29/2017, 3:16:34 AM] [manhdv]: <https://gyazo.com/399ccdf394470933d01dee949567be31>
[5/29/2017, 3:16:43 AM] [manhdv]: em ko ro, no bao cmd 404 :neutral_face:
[5/29/2017, 3:17:03 AM] [huy]: ah a install dung` brew
[5/29/2017, 3:17:07 AM] [huy]: :roflrofl:
[5/29/2017, 3:17:10 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: cái `tree` phải cài mà
[5/29/2017, 3:17:14 AM] [huy]: sorry
[5/29/2017, 3:17:16 AM] [hieu.huynh]: me too :think:
[5/29/2017, 3:17:56 AM] [SFzxc]: `brew install tree ` xong thì xài cái a Huy thì đc
[5/29/2017, 3:18:19 AM] [manhdv]: <https://gyazo.com/15ccd27b756c4d49dd13372ccc31d7db>
:)))
[5/29/2017, 3:18:24 AM] [hieu.huynh]: xài tree lâu lâu em bị ngáo :disappointed: 
[5/29/2017, 3:18:38 AM] [manhdv]: `ls -G ^`
[5/29/2017, 3:19:01 AM] [SFzxc]: :oh:
[5/29/2017, 3:19:05 AM] [hieu.huynh]: có tree luôn, có -G luôn nhưng vẫn hổng dc
[5/29/2017, 3:19:35 AM] [manhdv]: hoa ra zsh da alias `ls -G` thanh `ls` :roflrofl:
cau lenh day du khi ko co alias la:
`ls -G ^`
[5/29/2017, 3:19:54 AM] [manhdv]: ao vay :neutral_face:
[5/29/2017, 3:20:05 AM] [SFzxc]: vẫn ko đc, comfirmed :lol:
[5/29/2017, 3:20:16 AM] [SFzxc]: mac + zsh
[5/29/2017, 3:21:24 AM] [hieu.huynh]: mac + bash, too :byeanim:
[5/29/2017, 3:24:57 AM] [manhdv]: thu install oh-my-zsh xem sao :v
[5/29/2017, 3:37:30 AM] [hieu.huynh]: bữa đọc cái bài nó compare zsh với bash :think:
thấy zsh more powerful hơn thật, mà em hổng có sài :troll:
[5/29/2017, 5:35:38 PM] [alias Trung.Le, as tle]: @giangnh Ruby cũng thế
[5/29/2017, 5:38:22 PM] []: Kotlin cũng vậy
[5/29/2017, 5:54:51 PM] [alias Trung.Le, as tle]: @thien :lol:
[5/29/2017, 10:15:56 PM] [manhdv]: #til
<https://developer.yahoo.com/performance/rules.html>
[5/30/2017, 2:15:00 PM] [huy]: <https://i.imgur.com/ElkaQaO.png>
[5/30/2017, 2:15:28 PM] [huy]: #til Dãy fibonacci được định nghĩa với mục đích ban đầu là dể diễn đạt tỉ lệ đẻ của thỏ :omg:
[5/30/2017, 2:35:49 PM] [tucq88]: the ma ngay xua duoc day la bai toan dem' tho? :v
[5/30/2017, 6:44:19 PM] [alias Trung.Le, as tle]: #til developers should meet directly with customers, understand how their customers are doing business with the help from the solutions developers
[5/30/2017, 7:16:36 PM] [tanlinhnd]: @snacky nó sinh ra từ bài toán tính số lượng thỏ đẻ đều đều mà a :omg:
[5/30/2017, 10:20:47 PM] [noob]: #til `git log --pretty=format: --name-only | sort | uniq -c | sort -rg | head -10`
[5/31/2017, 12:10:18 AM] [hieu.huynh]: #til 2 mailing lists nên subscribe để nhận latest OSS vulnerabilities
- <http://oss-security.openwall.org/wiki/mailing-lists/oss-security>
- <https://lists.ubuntu.com/mailman/listinfo/ubuntu-security-announce>
Xem thêm TIL của mình ở đây: <https://github.com/hieuhtr/Blog/issues/41>
[5/31/2017, 1:31:03 AM] [hieu.huynh]: ---------
#til khi dùng `top` command, gõ `1` thì each cpu is displayed separately
```
When you see '%Cpu(s):' in the summary area, the '1' toggle is On and all cpu information is gathered in a single line. Otherwise, each cpu is displayed separately as: '%Cpu0, %Cpu1, ...' up to available screen height.
```
[5/31/2017, 1:31:33 AM] [hieu.huynh]: example:
```
top - 08:31:23 up 18 days, 23:27, 2 users, load average: 0.09, 0.09, 0.06
Tasks: 125 total, 2 running, 123 sleeping, 0 stopped, 0 zombie
%Cpu0 : 0.0 us, 0.0 sy, 0.0 ni, 99.7 id, 0.3 wa, 0.0 hi, 0.0 si, 0.0 st
%Cpu1 : 0.0 us, 0.0 sy, 0.0 ni,100.0 id, 0.0 wa, 0.0 hi, 0.0 si, 0.0 st
%Cpu2 : 0.0 us, 0.0 sy, 0.0 ni,100.0 id, 0.0 wa, 0.0 hi, 0.0 si, 0.0 st
%Cpu3 : 0.3 us, 0.0 sy, 0.0 ni, 99.7 id, 0.0 wa, 0.0 hi, 0.0 si, 0.0 st
KiB Mem: 7659512 total, 5192360 used, 2467152 free, 218524 buffers
```
[5/31/2017, 6:05:58 PM] [huy]: #til `document.createDocumentFragment()`
[5/31/2017, 10:25:41 PM] [giangnh]: #til "Kẻ thù lớn nhất của cuộc đời mỗi người là sự ngu ngốc"
[5/31/2017, 11:37:52 PM] [anh bán chuối]: làm sao học dc?
[5/31/2017, 11:38:01 PM] [anh bán chuối]: @giangnh
[5/31/2017, 11:49:43 PM] [alias Trung.Le, as tle]: @hieu.huynh chiêu này hay à
[5/31/2017, 11:56:44 PM] [noob]: @giangnh vì sao nhỉ?
[6/1/2017, 12:02:02 AM] [giangnh]: em thấy hay hay nên share lại, cái này do suy nghĩ của mỗi người. Em nghĩ là vậy
[6/1/2017, 12:02:22 AM] [giangnh]: @longkt90 :think:
[6/1/2017, 12:29:33 AM] [manhdv]: #til
Cẩn thận với việc khai báo trong database.yml
```
・The url option will take the highest precedence even if ENV['DATABASE_URL'] is available.
・In the event that the config/database.yml file is present but has no configuration, ENV['DATABASE_URL'] will be used.
・In the event that the config/database.yml file is present with configuration, except url option, both config/database.yml and ENV['DATABASE_URL'] will be used. Rails will attempt to merge the options from both, but the ones from the environment variable will take precedence.
・If no ENV['DATABASE_URL'] is present, then the configuration in config/database.yml will be used.
```
[6/1/2017, 2:08:16 AM] [dan]: #til Hash.new([]) doesn't work because Hash.new share the same object for default under the hood
[6/1/2017, 2:08:26 AM] [dan]: <https://stackoverflow.com/questions/2698460/strange-unexpected-behavior-disappearing-changing-values-when-using-hash-defa>
[6/1/2017, 2:31:21 AM] [manhdv]: #til How to access current_user everywhere without plugin
<http://blog.bigbinary.com/2016/09/05/rails-5-adds-ability-to-create-module-and-class-level-variables-on-per-thread-basis.html>
[6/1/2017, 6:17:12 PM] [alias Trung.Le, as tle]: #til đã dùng thì phải tin, không tin thì không dùng
[6/1/2017, 6:51:42 PM] [anh bán chuối]: @tle phải tin Rails :smile:
[6/1/2017, 6:55:37 PM] [manhdv]: Vợ khuyên thì ko nên nghe, đã nghe thì người ấy ắt ko phải vợ :vvv
[6/1/2017, 6:55:53 PM] [alias Trung.Le, as tle]: ROFL
[6/1/2017, 8:54:10 PM] [alias Trung.Le, as tle]: #til <https://transferwise.com/au/>
[6/1/2017, 8:58:30 PM] [huy]: @tle a xài thử chưa, e reg thử rồi mà chưa xài nữa :think:
[6/1/2017, 8:58:50 PM] [alias Trung.Le, as tle]: cc @rebyn
[6/6/2017, 7:56:28 PM] [hieu.huynh]: #til -----
trong tmux, file config `~/.tmux.conf`, muốn dùng chuột click để chuyển sang các pane, thì bật mouse lên
bật mouse cũng scroll dc trong tmux, bình thường hình như hổng có scroll dc
```
set-option -g mouse on
```
còn muốn quét chọn cụm nào đó để copy ra ngoài, bình thường tmux cũng ko cho phép
muốn quét chọn dc, thì đè phím `option`
[6/6/2017, 9:19:02 PM] [hieu.huynh]: #til *Quick test* sending and receiving *UDP* packets
From instance A, send a simple packet to B (172.30.31.32) with IP &amp; port 1514
```
echo "Packet data right here" &gt; /dev/udp/172.30.31.32/1514
```
On instance B, using tcpdump for looking traffic incoming
```
tcpdump -nei eth0 udp port 1514
```
[6/6/2017, 11:41:53 PM] [jinhduong]: muốn đổi pass tk này log out ra tk khác mới đổi đc
[6/6/2017, 11:41:56 PM] [jinhduong]: :omg:
[6/6/2017, 11:42:02 PM] [jinhduong]: winxp
[6/7/2017, 5:34:12 PM] [alias Trung.Le, as tle]: @snacky
[6/7/2017, 5:34:20 PM] [alias Trung.Le, as tle]: dùng thử rồi và tiền cũng đã vào đúng tk ở VN
[6/7/2017, 5:34:24 PM] [alias Trung.Le, as tle]: phí thì ít hơn PayPal
[6/7/2017, 5:34:27 PM] [alias Trung.Le, as tle]: quớ ngon
[6/7/2017, 5:34:56 PM] [alias Trung.Le, as tle]: #til <https://medium.com/@pioul/modular-css-with-react-61638ae9ea3e>
[6/7/2017, 5:36:20 PM] [huy]: tốn mất mấy ngày a
[6/7/2017, 5:36:38 PM] [huy]: bên phía ngân hàng vn có check chiếc gì ko
[6/7/2017, 5:52:38 PM] [alias Trung.Le, as tle]: #til Ruby `String#codepoints`
[6/7/2017, 9:28:03 PM] [alias Trung.Le, as tle]: @snacky mất 3 ngày, chẳng thấy có vụ check chiếc gì cả
[6/7/2017, 9:29:57 PM] [huy]: hay thé, a gửi vào ngân hàng nào vậy, e cũng đang muốn gửi về thanh toán tiền thẻ tín dụng HSBC nhưng nó bắt phải chuyển từ tk trong nước, ko biết cách này có work ko
[6/9/2017, 8:58:49 PM] [SFzxc]: #til`self.abstract_class = true`
[6/10/2017, 2:44:44 AM] [minh.nguyen]: #til
```ruby
h2 = { two: 2 }
{ one: 1, **h2 }
```
Is 2 times faster than
```ruby
h2 = { two: 2 }
{ one: 1 }.merge(h2)
```
[6/10/2017, 5:40:31 AM] []: Can you give a detailed explanation why it's 2 times faster?
[6/11/2017, 3:58:03 AM] [Cậu Làm Vườn]: @lmduc I'm also new to that behaviour but maybe I can offer some insight.
Digging into the code base for `merge`, we see this:
```
static VALUE
rb_hash_merge(VALUE hash1, VALUE hash2)
{
return rb_hash_update(rb_obj_dup(hash1), hash2);
}
```
So first it will duplicate the first hash --&gt; O(m), and then call hash update, which will result in an iteration through the second hash `rb_hash_foreach(hash2, rb_hash_update_i, hash1)` --&gt; O(n)
So the whole merge operation will have O(m+n)
I cannot find the source code for splat operation, but I guess what it does is writing the value from the second hash into the first hash, so only O(n) maybe?
I'm new to algorithm... Please correct me if I'm wrong somewhere...
[6/11/2017, 4:31:26 AM] [minh.nguyen]: @lmduc <@U39QVF5UZ> the speed differences are from the compilation of the code snippets. We can easily print out the YARV instructions of those two with this: `RubyVM::InstructionSequence.compile(code).disasm`.
For the first snippet (`{ one: 1, **h2 }`), Ruby generates those YARV instructions:
```
0013 putobject :one
0015 putobject_OP_INT2FIX_O_1_C_
0016 newhash 2
0018 putspecialobject 1
0020 swap
0021 getlocal_OP__WC__0 2
0023 opt_send_without_block &lt;callinfo!mid:core#hash_merge_kwd, argc:2, ARGS_SIMPLE&gt;, &lt;callcache&gt;
```
At the beginning, Ruby creates an empty hash, then put the first pair of key and value (:one) into that hash. Then, it call `hash_merge_kwd` method in `vm.c`. That method modifies the newly created hash and sequently adds each pair of key and value of hash h2 into the new hash
In the second code snippet (`{ one: 1 }.merge(h2)`), the main intructions are:
```
0013 putspecialobject 1
0015 putobject [:one, 1]
0017 opt_send_without_block &lt;callinfo!mid:core#hash_from_ary, argc:1, ARGS_SIMPLE&gt;, &lt;callcache&gt;
0020 getlocal_OP__WC__0 2
0022 opt_send_without_block &lt;callinfo!mid:merge, argc:1, ARGS_SIMPLE&gt;, &lt;callcache&gt;
0025 leave
```
First, it puts an array (`[:one, 1]` into the internal YARV stack), then calls `hash_from_ary` method in `vm.c`. This method creates new empty hash, then loop through the array in the internal stack and adds into the hash. Then, it continues to call `rb_hash_merge` to loop through the keys and values in the hash and adds to the newly created hash.
So, the slowness is the overhead problem, not the algorithm complexity. The splat approach jumps directly into hash creation and merging, while the merge approach creates hash, collect hash data from array and then merging
[6/11/2017, 4:49:56 AM] [Cậu Làm Vườn]: The extra overhead is the looping through the array.
so if the second hash is really big and the first hash is relatively small, there is not much performance difference between the two approaches, no?
[6/11/2017, 5:09:19 AM] [Cậu Làm Vườn]: Anw, big thank for the information.
I believe lots of people didn't know or pay attention to this problem before. :+1:
[6/11/2017, 8:23:41 AM] [minh.nguyen]: Yeah. When the number of second hash's keys is huge, they run nearly the same. In normal condition, it is likely that the number of second hash is around 5 or 10, the splat operation approach is better :smile:
[6/11/2017, 2:56:15 PM] [ko luong thien]: #til redux-loop and its elm-architect inspiration
[6/12/2017, 1:31:32 AM] [hieu.huynh]: #til update cipher policy of LB aws
<http://docs.aws.amazon.com/elasticloadbalancing/latest/classic/ssl-config-update.html>
[6/12/2017, 2:12:30 AM] [tay vịn của anh bán chuối - cty A tìm FE]: @thien viết blog đi em
[6/12/2017, 7:57:12 AM] [anpham]: TIL <https://medium.com/@johnnylin/how-to-make-80-000-per-month-on-the-apple-app-store-bdb943862e88>
[6/12/2017, 7:59:56 AM] [Cậu Làm Vườn]: @anpham Tối qua cũng mới đọc, kéo xuống thấy tên tiếng Việt...
[6/12/2017, 8:00:13 AM] [anpham]: :facepalmanim:
[6/12/2017, 6:50:02 PM] [Pi]: tên tiếng Việt thì có vấn đề gì nhỉ ?
[6/12/2017, 7:03:44 PM] [anpham]: Co nghia la nguoi lua dao la nguoi goc Viet Nam.
[6/12/2017, 7:10:36 PM] [Pi]: ở nước nào chẳng có người lừa đảo :smile:
[6/12/2017, 7:31:59 PM] [anpham]: Nước khác lừa đảo thì chuyện của người ta. Mình chỉ quan tâm người lừa đảo ở đây là người Việt Nam. :facepalmanim:
[6/12/2017, 7:36:15 PM] [Pi]: chắc Trung Quốc đánh Lào hay ThaiLand chắc cũng chuyện của người ta =))
[6/12/2017, 7:37:02 PM] [Pi]: Triều Tiên đánh Hàn cũng kệ người ta
[6/12/2017, 7:37:28 PM] [Pi]: đồng ý với bạn là ng Việt lừa đảo thì ảnh hưởng uy tín của ng Việt
[6/12/2017, 7:39:14 PM] [Pi]: nhưng làm sao mà kiểm soát nổi cái đó, thay vì ngồi care mấy ng lừa đảo đó, lấy thời gian nghiên cứu ra bên ngoài xíu, đừng việc gì cũng kệ ng ta
[6/12/2017, 7:39:34 PM] [Pi]: sau này cái kệ ng ta đó nó sẽ ảnh hưởng đến mình
[6/12/2017, 8:04:39 PM] [anpham]: So sánh lung tung quá. :facepalmanim: Đơn giản là cái xấu thì người kệ người ta. Chuyện gì đúng thì mình làm. Ví dụ:
- Chuyện nước nào cũng có người lừa đảo không có nghĩa là người Việt Nam lừa đảo cũng không sao, không đáng quan tâm -&gt; loind sai ở chỗ này.
- Qua ví dụ Trung Quốc đánh Lào. Trung Quốc đánh Lào không có nghĩa là Việt Nam cũng có quyền đánh Lào. Trung Quốc sai là chuyện của Trung Quốc. Việt Nam phải làm việc đúng là không bắt chước Trung Quốc đánh Lào.
Hy vọng loind dành thời gian suy ngẫm để hiểu thêm.
[6/12/2017, 8:06:29 PM] [Pi]: nói một đằng bạn hiểu một nẻo :cold_sweat:
[6/12/2017, 8:06:41 PM] [Pi]: ```Nước khác lừa đảo thì chuyện của người ta. Mình chỉ quan tâm người lừa đảo ở đây là người Việt Nam.```
[6/12/2017, 8:07:08 PM] [Pi]: thuật lại câu bạn nói nè, người khác lừa đảo thì ko quan tâm
[6/12/2017, 8:07:15 PM] [Pi]: ng VIệt Nam lừa đảo thì quan tâm
[6/12/2017, 8:07:45 PM] [Pi]: mình chỉ muốn nói là cái kệ ng ta đó sau này sẽ ảnh hưởng tới mình :smile:
[6/12/2017, 8:08:49 PM] [Pi]: còn vụ TQ đánh Lào ý mình ko phải là kêu VN bắt chước, mà ý là nó sẽ ảnh hưởng tới mình ^^
[6/12/2017, 8:09:01 PM] [Pi]: tự nhiên ai kêu VN có quyền đánh Lào đâu :smile:
[6/12/2017, 8:09:54 PM] [Pi]: anw, mình sẽ dành thời gian suy nghĩ thêm ý bạn nói :smile:
[6/12/2017, 8:12:16 PM] [Pi]: mà mình cũng thấy mình vô tâm quá, đáng lẻ phải dành thời gian quan tâm những người Việt lừa đảo
[6/12/2017, 8:24:41 PM] [anpham]: :+1: Quan tâm những người này không giải quyết được vấn đề gì. Chỉ cần xem như là một hồi chuông cảnh tỉnh bản thân: Không phải là số tiền mà thực ra là cách kiếm ra tiền mới là điều làm nên giá trị một con người. :beers:
[6/12/2017, 8:54:27 PM] [Pi]: :y:
[6/13/2017, 4:27:48 AM] [hieu.huynh]: #til thêm -T vào để human readable dmesg :doubt:
[6/14/2017, 1:29:33 AM] [ko luong thien]: #today_i_confirmed: webpack 1 resolves loaders relative to the file which contains the require/import. webpack 2 changes this behavior as configurated loaders are resolved relative to the configuration file.
[6/14/2017, 4:58:56 AM] [Cậu Làm Vườn]: No criticism intended...
Btw, good evening guys!
[6/14/2017, 8:19:49 PM] [tucq88]: @thien don't get it :cry:
[6/14/2017, 8:21:53 PM] [ko luong thien]: @tucq88 this is a rare case I supposed.. you must have multiple node_modules (or to be exact: multiple source of loaders) to see this..
[6/14/2017, 8:22:10 PM] [ko luong thien]: for example: authoring multiple apps in one repo
[6/14/2017, 8:22:20 PM] [ko luong thien]: so, let's say we have this structure:
[6/14/2017, 8:23:28 PM] [ko luong thien]: ```
your_library
src
index.js
your_client_app_1
src
index.js
your_client_app_2
src
index.js
```
[6/14/2017, 8:23:57 PM] [tucq88]: oh :neutral_face: that's different story (much complex than normal usecases)
[6/14/2017, 8:24:16 PM] [ko luong thien]: now, you are working at your_client_app_1, so you yarn install, and you have a node_modules inside your_client_app_1. Also let's say you have your webpack config at your_client_app_1
[6/14/2017, 8:24:53 PM] [ko luong thien]: ```
your_library
src
index.js
your_client_app_1
node_modules
babel-loader
babel
src
index.js
config.js
your_client_app_2
src
index.js
```
[6/14/2017, 8:25:40 PM] [ko luong thien]: now, from `your_client_app_1/src/index.js`, you import `your_library/src/index.js`
[6/14/2017, 8:26:18 PM] [ko luong thien]: *by default*, webpack 1 will throw an error: "Babel Loader not found", while in webpack 2 all are good
[6/14/2017, 8:27:19 PM] [ko luong thien]: so why? Because in webpack 1, loaders are resolved relatively with the processing file (in this case, `your_library/src/index.js`), and because there are no node_modules contains babel-loader around it, webpack will throw an error
[6/14/2017, 8:27:35 PM] [tucq88]: I just don't get it, why don't you use `your_library` as another package ?
I mean publish it to npm,
[6/14/2017, 8:27:52 PM] [ko luong thien]: However, in webpack 2, loaders are resolved relative to the config file (in this case, `your_client_app_1/config.js`, so it found the babel loader)
[6/14/2017, 8:28:07 PM] [ko luong thien]: that, my friend, is a whole different question =))
[6/14/2017, 8:28:38 PM] [ko luong thien]: @tucq88 reason why we are using that structure
[6/14/2017, 8:29:14 PM] [ko luong thien]: is because we changed `your_library` a lot while working with both `your_client_app_1` and `your_client_app_2`
[6/14/2017, 8:29:26 PM] [ko luong thien]: but `npm link` or `yarn link` is not stable enough for our case :disappointed:
[6/14/2017, 8:30:19 PM] [tucq88]: haha :smile: that why I always love to stay in development team, to watch many awkward situation lolllllll
[6/14/2017, 8:30:32 PM] [ko luong thien]: there are lots of issue while we judge `your_library` as a npm modules, and then link it to our apps. Especially when we work in multiple os (windows for example is not really stable with npm link)
[6/14/2017, 8:30:42 PM] [tucq88]: hmm
[6/14/2017, 8:30:58 PM] [ko luong thien]: and another reason, is we don't want to transpile/compile `your_library` actually
[6/14/2017, 8:31:26 PM] [ko luong thien]: we want the compilation of `your_library` is a part of the compilation of `your_client_app_1`
[6/14/2017, 8:31:47 PM] [ko luong thien]: but this is a very little reason.. we can setup webpack to apply loader to a specific node_module..
[6/14/2017, 8:32:01 PM] [ko luong thien]: but again, it hardly work in case of using npm link
[6/14/2017, 8:32:29 PM] [ko luong thien]: so *to be honest*, if you have any suggestion to improve this, I'd be love you for a very long time
[6/14/2017, 8:33:22 PM] [ko luong thien]: wait what what do you mean "development" team :)) are you doing marketing or managing or business things?
[6/14/2017, 8:33:27 PM] [ko luong thien]: I always thought you are an engineer..
[6/14/2017, 8:34:50 PM] [tay vịn của anh bán chuối - cty A tìm FE]: @thien how about lerna?
[6/14/2017, 8:34:57 PM] [tay vịn của anh bán chuối - cty A tìm FE]: <https://github.com/lerna/lerna>
[6/14/2017, 8:45:45 PM] [ko luong thien]: hm that seems very nice.. I'll give it a try
[6/14/2017, 8:45:49 PM] [ko luong thien]: thank you @nhducit
[6/14/2017, 8:46:04 PM] [giangnh]: LOL js
[6/14/2017, 8:46:08 PM] [ko luong thien]: I know this because of create-react-app but haven't take a deep look actually :))
[6/14/2017, 8:47:52 PM] [tay vịn của anh bán chuối - cty A tìm FE]: I haven’t have opportunity to use it. Remember to share your exp with lerna :slightly_smiling_face:
[6/14/2017, 8:56:00 PM] [tucq88]: so @thien will love <@U0ZLMH3T8> for long time ?
[6/14/2017, 8:56:11 PM] [tucq88]: lolllll
[6/14/2017, 9:23:43 PM] [alias Trung.Le, as tle]: #til good practices on Rails presenter/view models
```
## Use presenters/view models
Basic rules:
1. Your controller action should ideally expose only one instance variable to your views - the presenter.
2. Back each view or partial with its own presenter.
3. Rendering partials within partials means your presenters can return other presenters for these partials.
4. If your view requires an author and the current user, provide that to your presenter - don't make your presenter navigate through an item to get the author.
5. Write your view first, assuming no knowledge of how our domain is modelled, then write the presenter to drive it.
6. Prefer composition over inheritance.
7. Presenters shouldn't know about CSS class names.
```
[6/14/2017, 9:33:58 PM] [tay vịn của anh bán chuối - cty A tìm FE]: lol
[6/14/2017, 11:48:03 PM] [tucq88]: seems like those could be applied in php as well
[6/15/2017, 11:15:42 PM] [ko luong thien]: #til from ISO country code to emoji flag:
```
// js
String.fromCodePoint(...[...cc].map(c =&gt; c.charCodeAt() + 127397))
// "VN" =&gt; 🇻🇳
```
[6/15/2017, 11:16:13 PM] [ko luong thien]: cc is country code
[6/15/2017, 11:16:29 PM] [ko luong thien]: 127397 is magic (offset)
[6/16/2017, 2:48:51 AM] [halcyonl]: @thien like
[6/16/2017, 8:06:53 AM] []: #til
require có thể để trong lệnh if/esle còn import thì không.
```
// Chạy ngon
if (true) {
var cai_gi_do = require('./o_cho_nao_do');
}
// Lỗi
if (true) {
import cai_gi_do from './o_cho_nao_do';
}
```
[6/16/2017, 9:16:42 AM] [ko luong thien]: @haond theo bạn thì việc này tốt hay xấu :smile:
[6/16/2017, 9:17:01 AM] [ko luong thien]: theo bạn thì việc import/require tuỳ vào điều kiện như vậy là nên hay không?
[6/16/2017, 9:20:29 AM] [ko luong thien]: mình cũng tò mò tại sao require lại có thể sử dụng điều kiện, còn import thì không..
[6/16/2017, 9:20:42 AM] [ko luong thien]: import có phải là chuẩn mới không nhỉ?
[6/16/2017, 9:21:15 AM] [ko luong thien]: hiện tại mình thấy babel + webpack 1 vẫn dịch import thành require..
[6/16/2017, 7:17:18 PM] []: Cá nhân mình thấy require đặt ở trong điều kiện được, linh động hơn import. Và nó giải quyết được vấn đề load file theo option.
[6/16/2017, 7:19:00 PM] []: mình cũng thắc mắc vì sao import ko đặt ở trong điều kiện được
[6/16/2017, 7:31:22 PM] [ko luong thien]: hm.. điều kiện đó là được xử lí ở compile-time đúng k bạn nhỉ?
[6/16/2017, 7:31:34 PM] [ko luong thien]: `if (something) { require(...) }`
[6/16/2017, 7:31:54 PM] [ko luong thien]: thì tính đúng sai của `something` phải được quyết định lúc compile?
[6/16/2017, 7:32:02 PM] [ko luong thien]: vậy nếu require ở run-time thì sẽ thế nào?
[6/16/2017, 7:32:42 PM] [ko luong thien]: ```
function foo() {
var a = require(...);
console.log(a);
}
button.onClick = foo;
```
[6/16/2017, 7:33:30 PM] [ko luong thien]: <https://stackoverflow.com/questions/31354559/using-node-js-require-vs-es6-import-export>
[6/16/2017, 7:33:52 PM] [ko luong thien]: ồ
[6/16/2017, 7:33:56 PM] [ko luong thien]: &gt; There are technical difference between CommonJS and ES6 modules, e.g. CommonJS allows you to load modules dynamically. ES6 doesn't allow this, but there is an API in development for that.
[6/18/2017, 10:34:05 PM] [manhdv]: `&amp;.` for `Ruby &gt;= 2.3.0`
[6/18/2017, 11:10:07 PM] [tay vịn của anh bán chuối - cty A tìm FE]: @thien coi thêm dynamic import nha
[6/18/2017, 11:10:25 PM] [ko luong thien]: cám ơn a :smile:
[6/18/2017, 11:10:40 PM] [tay vịn của anh bán chuối - cty A tìm FE]: có khi em dùng rồi mà không biết đó
[6/18/2017, 11:10:43 PM] [tay vịn của anh bán chuối - cty A tìm FE]: webpack code splitting
[6/18/2017, 11:16:54 PM] [ko luong thien]: nãy e định hỏi.. code splitting với dynamic import nó liên quan nhau hở a? (code splitting là sử dụng dynamic import?)
[6/18/2017, 11:17:09 PM] [ko luong thien]: và cái đó nó xảy ra ở run time hay compile time?
[6/18/2017, 11:17:41 PM] [tay vịn của anh bán chuối - cty A tìm FE]: có liên quan
[6/18/2017, 11:17:46 PM] [tay vịn của anh bán chuối - cty A tìm FE]: code splitting là sử dụng dynamic import?
[6/18/2017, 11:17:47 PM] [tay vịn của anh bán chuối - cty A tìm FE]: uhm
[6/18/2017, 11:17:59 PM] [tay vịn của anh bán chuối - cty A tìm FE]: và cái đó nó xảy ra ở run time hay compile time?
cả hai
[6/18/2017, 11:18:24 PM] [tay vịn của anh bán chuối - cty A tìm FE]: webpack nó build cái module mapping ở compile time
[6/18/2017, 11:19:02 PM] [tay vịn của anh bán chuối - cty A tìm FE]: sau đó ở runtime mới khi nào cần mới download
[6/18/2017, 11:23:02 PM] [ko luong thien]: ừm hưm..
[6/18/2017, 11:23:03 PM] [ko luong thien]: tks a
[6/18/2017, 11:23:16 PM] [ko luong thien]: vậy ở run time nếu xài code của cái module đó thì kiểu như promise hở a?
[6/18/2017, 11:58:24 PM] [tay vịn của anh bán chuối - cty A tìm FE]: uhm, promise
[6/18/2017, 11:58:34 PM] [tay vịn của anh bán chuối - cty A tìm FE]: import(‘abc’).then()
[6/19/2017, 12:22:48 AM] [ko luong thien]: seems very nice :+1:
[6/19/2017, 12:24:16 AM] [tay vịn của anh bán chuối - cty A tìm FE]: mới stage 3 thôi nhé
[6/19/2017, 12:49:42 AM] [tucq88]: @manhdv nói rõ hơn dc koban
[6/19/2017, 12:52:00 AM] [manhdv]: @tucq88 ban doc them o link nay nhe
<http://mitrev.net/ruby/2015/11/13/the-operator-in-ruby/>
[6/19/2017, 4:20:53 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til
<https://stackoverflow.com/questions/18666915/why-are-nested-anchor-tags-illegal>
[6/19/2017, 5:58:13 AM] [dan]: Giống `?` trong kotlin nhỉ. À mà c# cũng có `?`.
[6/20/2017, 7:21:52 AM] [alias Trung.Le, as tle]: TIL composer (PHP)
[6/20/2017, 7:30:53 AM] [alias Trung.Le, as tle]: TIL <http://haxe.org/#the-haxe-toolkit>
[6/20/2017, 9:28:57 PM] [giangnh]: #til: `git log --oneline --graph --all --decorate`
[6/21/2017, 3:16:21 AM] [alias Trung.Le, as tle]: TIL PHP devs are great! I read PHP codes last night and I appreciate things are much greener on the Ruby side
[6/21/2017, 3:21:19 AM] [unrealhoang]: @tle Ruby is dead
[6/21/2017, 3:22:01 AM] [alias Trung.Le, as tle]: Its legacy lives on
[6/21/2017, 3:25:36 AM] [tucq88]: thanks :v we just learn from the best :v
[6/23/2017, 4:09:01 AM] [alias Trung.Le, as tle]: TIL `pv /path/database_backup.sql.gz | gzip -dc | mysql -P 3306 -u root -D my_db`
[6/25/2017, 3:57:58 AM] [hieu.huynh]: #til extension `Betternet VPN` on chrome has adware &amp; pornographic ads/links injection
<https://restoreprivacy.com/betternet-review/>
[6/25/2017, 4:50:38 AM] []: Vpn thì phải tìm ai lớn uy tính, ko dùng bừa đc đâu
[6/25/2017, 5:44:45 PM] [unrealhoang]: *uy tín
[6/25/2017, 6:44:55 PM] []: :crying:, auto complete đó
[6/25/2017, 7:57:45 PM] [hieu.huynh]: #til trong `~/.vimrc` mình có thể thêm config này để nó highlight cái dòng mà cursor đang đứng
mục đích: xem nhanh cursor đang ở đâu, ko cần phải căng mắt ra coi cái cursor nhỏ xíu nháy nháy nữa
```
set cursorline
```
[6/25/2017, 11:36:47 PM] [alias Trung.Le, as tle]: #til Có nhiều bạn có thói quen chia sẻ TIL :+1:
[6/26/2017, 5:38:07 AM] [huynh.cam]: #til RSpec is so cool until you read their code
[6/26/2017, 5:49:33 AM] [anpham]: well, at least we know their code is being “tested” constantly :troll:
[6/26/2017, 8:19:01 AM] []: #til
Router trong react không render lại trang khi thay đổi params. Và không tự động scroll top khi chuyển trang.
`/page/:id` =&gt; Không render khi id = 1,2,3,...
`<https://stackoverflow.com/questions/40037072/react-router-not-reloading-component-when-changing-url-params>`
[6/26/2017, 9:16:48 AM] []: #til: Đặt giá trị mặc định props
Cách 1:
```
class Example extends Component {
render(){
if ( this.props.isTrue ) {
return &lt;h1&gt;True&lt;/h1&gt;
}
return &lt;h1&gt;False&lt;/h1&gt;
}
}
Example.defaultProps = {
isTrue: true
};
```
Cách 2:
```class Example extends Component {
render(){
if ( !this.props.isTrue ) {
return &lt;h1&gt;False&lt;/h1&gt;
}
return &lt;h1&gt;True&lt;/h1&gt;
}
}
```
[6/27/2017, 5:29:35 AM] [hieu.huynh]: #til Samba SMB has vulnerability - RCE Remote Code Execution
<https://nakedsecurity.sophos.com/2017/05/26/samba-exploit-not-quite-wannacry-for-linux-but-patch-anyway/>
[6/27/2017, 8:10:44 PM] [giangnh]: #til `rustc -Z help`
[6/27/2017, 8:22:33 PM] [huy]: #til `(+ new Date())`
[6/27/2017, 10:05:53 PM] [huynh.cam]: #til &lt;ruby&gt;
[6/28/2017, 6:47:54 AM] []: #til "npm run &lt;command&gt; params"
[6/28/2017, 8:46:22 PM] [hieu.huynh]: ----
#til default metric trên từng con instance mà cloudwatch aws nó bắt đc, ko có data về memory usage
nếu muốn có, thì manual install :doubt:
&gt; <https://aws.amazon.com/blogs/aws/cloudwatch-monitoring-scripts-updated/>
&gt; <https://aws.amazon.com/code/8720044071969977>
&gt; <http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/mon-scripts.html>
[6/29/2017, 5:54:55 AM] [anpham]: uhm cung hop ly vi AWS chi co’ data o hypervisor level thoi, cai’ nay la instance level nen minh` phai tu set up.
[6/29/2017, 6:06:44 AM] [huynh.cam]: #til Amazon 1-Click Ordering does not ask for password #FTIW (from today I will) always log out after browsing
[6/29/2017, 4:54:29 PM] []: #til ```
[1,2].concat(undefined).join('') // "12"
[1,2].concat([3,4]).join('') // "1234"```
[6/29/2017, 9:50:32 PM] []: #til
<https://redis.io/topics/memory-optimization#memory-allocation>
```
Redis will not always free up (return) memory to the OS when keys are removed. This is not something special about Redis, but it is how most malloc() implementations work. For example if you fill an instance with 5GB worth of data, and then remove the equivalent of 2GB of data, the Resident Set Size (also known as the RSS, which is the number of memory pages consumed by the process) will probably still be around 5GB, even if Redis will claim that the user memory is around 3GB. This happens because the underlying allocator can't easily release the memory. For example often most of the removed keys were allocated in the same pages as the other keys that still exist.
```
[6/29/2017, 10:24:58 PM] [huy]: @triet ko biet redis dung memory allocator gi nhi
[6/29/2017, 10:25:20 PM] [huy]: co 1 vu kha dau dau` a tung gap la khi e insert rat nhieu key + expire rat nhieu key
[6/29/2017, 10:25:26 PM] [huy]: no se gay ra memory fragmentation
[6/29/2017, 10:25:31 PM] [huy]: tuc la memory usage cu tang thoi, k giam?
[6/29/2017, 10:33:43 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: mình có thể set chặn trên để nó khỏi vượt ngưỡng đc mà nhỉ
[6/29/2017, 10:44:24 PM] [huy]: y e la sao @xluffy
[6/29/2017, 10:47:55 PM] []: Em cũng không rõ nữa anh, em đang bị như anh nói nè :omg:
<http://jmp.sh/SZ3fArj>
[6/29/2017, 10:48:54 PM] []: Còn set chặn như anh @xluffy nói chắc là đặt cái peak, mức ngưỡng mà redis consume memory thôi, tới ngưỡng thì nó la làng, không cho insert thêm nữa
[6/29/2017, 10:49:07 PM] [huy]: redis co tinh nang do a
[6/29/2017, 10:49:18 PM] [huy]: thuc ra cai experience ve fragment a gap o aerospike
[6/29/2017, 10:49:24 PM] [huy]: mem tang vo han luon
[6/29/2017, 10:49:42 PM] []: Cái link trên đó anh
[6/29/2017, 10:49:46 PM] []: cái dấu * thứ 2
[6/29/2017, 10:49:56 PM] []: ```
The previous point means that you need to provision memory based on your peak memory usage. If your workload from time to time requires 10GB, even if most of the times 5GB could do, you need to provision for 10GB.
```
[6/29/2017, 10:51:04 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: redis tới ngưỡng vẫn cho set mà
[6/29/2017, 10:51:22 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: chỉ có cái là evict key cũ ra thôi
[6/29/2017, 10:51:52 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: ý em là set chặn trên để tránh bị cái zụ mem tăng vô hạn á
[6/29/2017, 10:52:23 PM] [huy]: uah a k biet redis the nao
[6/29/2017, 10:52:28 PM] [huy]: co ma neu no dung allocator deu?
[6/29/2017, 10:52:33 PM] [huy]: thi ngay ca khi e evict
[6/29/2017, 10:52:44 PM] [huy]: thi no van bi day` mem do bi fragment a'
[6/29/2017, 10:53:03 PM] []: @xluffy VD redis của em đang chiếm 10GB, giờ em set `maxmemory` về 5GB được không nhỉ?
[6/29/2017, 10:53:37 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: thi no van bi day` mem do bi fragment a' -&gt; em ko rõ chỗ này, nếu em đã set maxmemory thì nó có vượt đc ngưỡng đó ko khi bị fragment?
[6/29/2017, 10:53:54 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: như ở em thì chưa bao giờ em thấy nó vượt cái ngưỡng em set cả
[6/29/2017, 10:55:22 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: @triet em set bao nhiêu chẳng đc, qtrọng là em chứa cái gì trong đó, nếu từ 10GB -&gt; 5GB thì nếu xài hết 5GB các key cũ sẽ bị evict ra cho key mới có chỗ (LRU)
[6/29/2017, 10:55:48 PM] [unrealhoang]: hình như redis dùng jemalloc nhỉ
[6/29/2017, 10:55:50 PM] [unrealhoang]: :think:
[6/29/2017, 10:55:54 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: đúng rồi
[6/29/2017, 10:56:26 PM] [unrealhoang]: uh, jemalloc
[6/29/2017, 10:56:48 PM] [unrealhoang]: <http://oldblog.antirez.com/post/everything-about-redis-24.html>
[6/29/2017, 10:59:07 PM] [huy]: @xluffy fragment tuc la kieu redis tuong? la no dung 5gb, thuc ra no dung 10gb
[6/29/2017, 11:08:39 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: okie anh, hiểu sai về cái vụ maxmemory rồi, nó ko phải là kiểu chặn
[6/29/2017, 11:09:22 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: maxmemory nó chỉ giới hạn 1 con số để biết khi nào key bị evict, nhưng như link của @triet thì key dù bị remove vẫn ko trả lại memory cho OS
[6/29/2017, 11:15:29 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: nhưng như trong link thì nó cũng nói memory allocators đủ thông minh để key mới đc add vào sẽ tái sử dụng vùng memory mà key cũ đã bị remove :think:
[6/29/2017, 11:15:45 PM] [huy]: uh chac redis thong minh do'
[6/29/2017, 11:15:48 PM] [huy]: aerospike bi. ngu
[6/29/2017, 11:15:49 PM] [huy]: :think:
[6/29/2017, 11:16:02 PM] [unrealhoang]: jemalloc thông minh
[6/29/2017, 11:16:04 PM] [unrealhoang]: :think:
[6/29/2017, 11:22:50 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: nhưng như cái hình monitor của @triet thì fải làm gì đó rồi, như cái tool thì nó bảo phải restart
[6/29/2017, 11:22:56 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: <https://www.datadoghq.com/pdf/Understanding-the-Top-5-Redis-Performance-Metrics.pdf>
[6/29/2017, 11:23:45 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: &gt; Using the fragmentation ratio to predict performance issues
xem thêm mục này
[6/29/2017, 11:24:25 PM] []: Do em mới xóa 15M keys
[6/29/2017, 11:24:34 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: cơ mà tks triet, đọc lại tài liệu mới thấy hiểu sai :-s
[6/29/2017, 11:24:34 PM] []: nên nó thế
[6/29/2017, 11:24:55 PM] []: Search thì thấy giải phải duy nhất là restart redis
[6/29/2017, 11:24:56 PM] []: :omg:
[6/29/2017, 11:25:23 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: ko thì em set mớ key giả vào đi, để tỉ lệ nó đúng :omg:
[6/29/2017, 11:25:33 PM] []: =))
[6/29/2017, 11:25:44 PM] []: Chi anh, em xóa là muốn giảm memory mà
[6/29/2017, 11:26:01 PM] []: còn cái fragment ratio kia đâu có gây ảnh hưởng gì đâu ta
[6/29/2017, 11:26:39 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: uh, như trường hợp của e thì em biết tsao nó vậy rồi
[6/30/2017, 12:15:11 AM] [sondnm]: #til <http://andrzejonsoftware.blogspot.com/2011/02/dci-and-rails.html>
[6/30/2017, 12:27:17 AM] [unrealhoang]: DCI is a myth
[6/30/2017, 1:59:47 AM] [giangnh]: #til rust macro parser: <https://github.com/rust-lang/rust/blob/1.0.0/src/libsyntax/ext/tt/macro_parser.rs#L511-L557>
[6/30/2017, 2:00:02 AM] [giangnh]: rust macro rules: <https://github.com/rust-lang/rust/blob/1.0.0/src/libsyntax/ext/tt/macro_rules.rs#L430-L476>
[6/30/2017, 11:53:38 AM] [ko luong thien]: #til
Use flex's `justify-content` and `align-items` might cause scrolling issue.
<https://stackoverflow.com/questions/33454533/cant-scroll-to-top-of-flex-item-that-is-overflowing-container>
Alternative is still use flex on parent but margin-auto on child
[6/30/2017, 5:14:16 PM] []: #til :
```
module.exports = {
devtool: 'source-map' // Bỏ dòng này nếu ko muốn sinh ra file bundle.js.map
}
```
[7/2/2017, 6:11:17 PM] [alias Trung.Le, as tle]: TIL <https://www.safaribooksonline.com/library/view/amazon-web-services/9780134702186/>
[7/2/2017, 7:16:16 PM] [huy]: #til <https://ride.guru>
[7/2/2017, 11:45:17 PM] [Cậu Làm Vườn]: #til return a more meaningful response from Service Object with OpenStruct (Tenet #3)
<https://hackernoon.com/the-3-tenets-of-service-objects-c936b891b3c2>
[7/4/2017, 2:27:13 AM] [minh.nguyen]: #til <http://blog.arkency.com/2013/06/are-we-abusing-at-exit/>
[7/5/2017, 12:09:49 AM] [alias Trung.Le, as tle]: TIL in JS `NaN` is a type of Number, it represents NotANumber obj. And I still don't understand why `NaN &gt; 0` returns false...
[7/5/2017, 12:10:29 AM] [unrealhoang]: @tle you should ask Float type
[7/5/2017, 12:10:48 AM] [alias Trung.Le, as tle]: i am listening..
[7/5/2017, 12:11:34 AM] [unrealhoang]: NaN belongs to the specification of IEEE float/double type
[7/5/2017, 12:12:02 AM] [unrealhoang]: and those values are not comparable
[7/5/2017, 12:13:02 AM] [alias Trung.Le, as tle]: à.. vậy `NaN &gt; 0` nên raise exception đúng không e
[7/5/2017, 12:14:03 AM] [unrealhoang]: đúng anh
[7/5/2017, 12:14:30 AM] [unrealhoang]: nhưng ở mấy chỗ không có exception như C
[7/5/2017, 12:14:36 AM] [unrealhoang]: thì nó trả ra error flag
[7/5/2017, 12:14:43 AM] [unrealhoang]: errno
[7/5/2017, 12:14:47 AM] [unrealhoang]: :omg:
[7/5/2017, 12:17:01 AM] [alias Trung.Le, as tle]: uhm
[7/5/2017, 12:17:25 AM] [alias Trung.Le, as tle]: anh nghĩ cái này còn liên quan đến cách JS engine compare obj em ơi
[7/5/2017, 12:17:27 AM] [alias Trung.Le, as tle]: anh đang mò tiếp
[7/5/2017, 12:17:28 AM] [alias Trung.Le, as tle]: vd nhé
[7/5/2017, 12:17:32 AM] [alias Trung.Le, as tle]: nếu em chạy code sao trong node
[7/5/2017, 12:17:45 AM] [alias Trung.Le, as tle]: `"me" &gt; 4 //false`
[7/5/2017, 12:17:45 AM] [unrealhoang]: I learnt about `NaN` in Rust :wink:
[7/5/2017, 12:18:00 AM] [alias Trung.Le, as tle]: cái trên không liên quan đến `NaN` nữa
[7/5/2017, 12:18:09 AM] [alias Trung.Le, as tle]: có lẽ toán tử `&gt;` trong JS có gì đặc biệt
[7/5/2017, 12:18:34 AM] [unrealhoang]: cái đó là nature weakly typed của js rồi anh
[7/5/2017, 12:18:52 AM] [alias Trung.Le, as tle]: em giải thích thêm đc không
[7/5/2017, 12:21:26 AM] [unrealhoang]: <https://stackoverflow.com/questions/964910/is-javascript-an-untyped-language>
[7/5/2017, 4:20:34 AM] [karmiphuc]: <http://heydonworks.com/practical_aria_examples/#input-tooltip>
[7/5/2017, 6:24:21 PM] [manhdv]: <https://github.com/GoogleChrome/lighthouse>
[7/5/2017, 9:43:20 PM] []: <http://veithen.github.io/2014/11/16/sigterm-propagation.html>
[7/5/2017, 10:47:11 PM] [huynh.cam]: #til Rspec `hash_including` :100:
[7/6/2017, 8:47:46 AM] []: #til: Gọi componentWillUnmount khi người dùng back về trang trước.
[7/6/2017, 9:17:16 AM] [tay vịn của anh bán chuối - cty A tìm FE]: @haond mình chưa hiểu, bạn có giải thích giúp mình được không
[7/6/2017, 9:17:56 AM] [tay vịn của anh bán chuối - cty A tìm FE]: gọi componentWillUnmount rồi implement những gì trong khi willUnmount
[7/6/2017, 9:25:24 AM] []: À. Bên mình gặp một case do gọi cùng 1 API với option khác nhau ở 2 trang kế tiếp nhau, dữ liệu lưu vào this.props.list. Với yêu cầu trang đầu load 2 phần tử, trang sau load all. Do đó đứng ở trang sau back về trang trước. Sẽ hiện this.props,list với đầy đủ các phần tử. Nên mình vào method life cycle khi component chuẩn bị hủy ( componentWillUnmount) . Tại đây mình gọi action clear this.props.list.
[7/6/2017, 9:27:09 AM] []: ```componentWillUnmount () {
this.props.clearList();
}```
[7/8/2017, 9:48:14 PM] []: #til: <https://direnv.net/>
```direnv is an environment switcher for the shell. It knows how to hook into bash, zsh, tcsh and fish shell to load or unload environment variables depending on the current directory. This allows project-specific environment variables without cluttering the "~/.profile" file.
Before each prompt, direnv checks for the existence of a ".envrc" file in the current and parent directories. If the file exists (and is authorized), it is loaded into a bash sub-shell and all exported variables are then captured by direnv and then made available to the current shell.
Because direnv is compiled into a single static executable, it is fast enough to be unnoticeable on each prompt. It is also language-agnostic and can be used to build solutions similar to rbenv, pyenv and phpenv.```
[7/9/2017, 6:19:49 PM] [tay vịn của anh bán chuối - cty A tìm FE]: @haond thanks
[7/10/2017, 7:28:24 AM] [hieu.huynh]: #til Định nghĩa về core, thread, logical/physical CPU - Mình nhầm lẫn cái này hoài :think:
<https://github.com/hieuhtr/Blog/issues/55>
[7/10/2017, 7:31:24 AM] [huy]: @hieu.huynh e k note mối liên hệ giữa hyper thread và pthread (của OS) thì sẽ không thấy bức trnah toàn thể
[7/10/2017, 7:31:57 AM] [hieu.huynh]: dạ để em tìm hiểu thêm cái này, cám ơn anh :muscle:
[7/10/2017, 6:08:15 PM] [huy]: sao ko viết bài đăng lên kipalog?
[7/10/2017, 6:22:10 PM] [hieu.huynh]: bài này còn sơ sài quá anh ơi, cái note nhỏ xíu của em thôi hà
[7/13/2017, 11:04:03 PM] [sondnm]: #til universal link in iOS to implement deep linking <https://developer.apple.com/library/content/documentation/General/Conceptual/AppSearch/UniversalLinks.html>
[7/14/2017, 4:39:01 AM] [huynh.cam]: #til singular form của criteria là criterion :neutral_face:
[7/14/2017, 5:38:23 AM] [unrealhoang]: mục đích của kipalog là note lại mà :think:
[7/14/2017, 6:58:21 AM] [Cậu Làm Vườn]: my whole life is a lie...
[7/14/2017, 9:26:14 AM] []: #til :
Parse string to number
```
+ "1" =&gt; 1
```
Parse number to array
```
const number = 123;
number.toString().split('') =&gt; ["1", "2", "3"]
```
[7/14/2017, 6:19:16 PM] []: `Number("1") =&gt; 1`
[7/15/2017, 2:15:49 AM] [unrealhoang]: #til <http://docopt.org/>
[7/15/2017, 2:16:41 AM] [unrealhoang]: `"1"|0 =&gt; 1`
[7/15/2017, 8:37:55 AM] []: Operator bit | dùng thích ghê :smile: Thank @unrealhoang
[7/15/2017, 8:56:04 AM] []: #til:
Bit Operator | (OR)
```
---------------------------------
null | null =&gt; 0
undefined | undefined =&gt; 0
NaN | NaN =&gt; 0
1/0 | 1/0 =&gt; 0
--------------------------------
0 | null =&gt; 0
0 | undefined =&gt; 0
0 | NaN =&gt; 0
0 | 1/0 =&gt; 0
0 | 0 =&gt; 0
0 | 1 =&gt; 1
--------------------------------
1 | null =&gt; 1
1 | undefined =&gt; 1
1 | NaN =&gt; 1
1 | 1/0 =&gt; 1
1 | 0 =&gt; 1
1 | 1 =&gt; 1
-------------------------------
"1" | 0 =&gt; 1
"null" | 0 =&gt; 0
"NaN" | 0 =&gt; 0
"undefined" | 0 =&gt; 0
"1/0" | 0 =&gt; 0
------------------------------
```
[7/16/2017, 9:15:34 AM] []: #til: <https://book.cakephp.org/3.0/_downloads/en/CakePHPCookbook.pdf>
[7/16/2017, 8:29:12 PM] [meowwwwwwwwwwwwwwww]: #til How to test (Mailer + Sidekiq) w/ RSpec
<https://gist.github.com/maxivak/690e6c353f65a86a4af9>
[7/17/2017, 9:11:06 PM] []: #til :
```
const HASH={0: this.functionA, 1: this.functionB};
(HASH[value] || this.defaultFunction)();
```
[7/17/2017, 9:19:17 PM] []: #til `less -r`
[7/18/2017, 5:09:03 PM] [huy]: -r hay ko -r khác gì nhau đâu nhỉ
[7/18/2017, 5:09:07 PM] [huy]: repaint đâu thấy gì
[7/18/2017, 5:28:14 PM] []: Nó sẽ hiện được màu, emoji,...
<http://jmp.sh/nEYuH9V>
[7/18/2017, 5:28:46 PM] []: <http://jmp.sh/zvAs8W7>
[7/18/2017, 5:28:59 PM] [huy]: :think:
[7/18/2017, 5:30:52 PM] []: <http://jmp.sh/HYwa5nB>
[7/18/2017, 5:31:07 PM] []: <http://jmp.sh/r4Kd1IO>
[7/18/2017, 5:35:01 PM] [huy]: <https://i.imgur.com/DGUU3nb.png>
[7/18/2017, 5:48:20 PM] []: tùy file anh ơi
[7/18/2017, 5:48:36 PM] []: với cat mà
[7/18/2017, 5:48:41 PM] []: cat thì nó ra phải rồi
[7/18/2017, 5:48:44 PM] []: less kìa
[7/18/2017, 5:54:49 PM] [huy]: <https://asciinema.org/a/jCZlmOVuhPdqvev847iBpeooe>
[7/18/2017, 5:54:50 PM] [huy]: :think:
[7/18/2017, 5:59:47 PM] []: who know ¯\_(ツ)_/¯
[7/18/2017, 5:59:57 PM] []: với đâu chỉ mỗi emoji
[7/18/2017, 6:00:44 PM] []: cái kia file log trên server, lười down về quá :think:
[7/18/2017, 6:00:49 PM] []: thôi bỏ đi
[7/18/2017, 6:02:55 PM] [huy]: đơn giản mà
[7/18/2017, 6:02:55 PM] [huy]: <https://i.imgur.com/8Emdgst.png>
[7/18/2017, 6:04:16 PM] []: GGWP
[7/19/2017, 8:23:13 AM] []: #til : <https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Array/splice>
[7/20/2017, 5:59:38 PM] [alias Trung.Le, as tle]: #til `char_filter` of Elasticsearch can be used to map special character, such as mapping emoji
[7/21/2017, 8:14:34 AM] [hieu.huynh]: #til Chrome on ubuntu, turn back/forward by using ALT + left/right shortcuts :doubt:
[7/21/2017, 8:15:24 AM] [anpham]: Most platform let you do that :wink:
[7/21/2017, 6:38:17 PM] []: #til `perl -e 'for(&lt;*&gt;){((stat)[9]&lt;(unlink))}'` xóa file nhanh hơn, mạnh mẽ hơn
[7/21/2017, 6:38:50 PM] []: ref: <https://unix.stackexchange.com/questions/37329/efficiently-delete-large-directory-containing-thousands-of-files>
[7/21/2017, 10:37:56 PM] []: #til:
Conver number to binary:
```
(16).toString(2); =&gt; "10000"
16..toString(2); =&gt; "10000"
Number("16").toString(2); =&gt; "10000"
"16"|0..toString(2); =&gt; "10000"
```
[7/22/2017, 9:22:27 AM] [hieu.huynh]: #til Anh em dành xíu thời gian ngủ trưa nhá
```
How long should you nap?
According to experts, 10 to 20 minutes is quite enough to refresh your mind and increase your energy and alertness. The sleep isn’t as deep as longer naps and you’re able to get right back at your day immediately after waking up. If you nap for 30 minutes you may deal with a 30-minute grogginess period because you wake up just as your body started entering a deeper stage of sleep. The same can be said if you sleep for an hour, but on the other hand, these 60-minute naps provide an excellent memory boost. The longest naps— lasting about 90 minutes—are recommended for those people who just don’t get enough sleep at night. Since it’s a complete sleep cycle, it can improve emotional memory and creativity.
```
Source: <https://www.healthspiritbody.com/nap-benefits/>
[7/22/2017, 9:41:01 AM] [unrealhoang]: @hieu.huynh mình thường nap khoảng 1h
[7/22/2017, 9:42:58 AM] [hieu.huynh]: :+1:
[7/23/2017, 3:23:18 AM] [hieu.huynh]: #til Maximum battery life on linux
<https://github.com/hieuhtr/Blog/issues/58>
Case study: x240 9cells - ubuntu 16.04
- Before: from 100% to 5% - ~ `3.5hours`
- After installing TLP: ~ `5hours` :troll:
[7/23/2017, 5:32:55 AM] []: @hieu.huynh dùng thêm powertop nữa
[7/24/2017, 2:55:32 PM] [halcyonl]: #til tác giả của `Laragon` là người Việt? `Laragon` bestter than `xampp` <https://laracasts.com/discuss/channels/general-discussion/laragon-is-the-best-option-for-windows-users-out-there-than-homestead?page=0>
[7/25/2017, 4:42:14 AM] [huynh.cam]: #til lý do không thể dùng `a:visited:after` trong CSS <https://hacks.mozilla.org/2010/03/privacy-related-changes-coming-to-css-vistited/>
[7/25/2017, 9:28:54 PM] [giangnh]: #til <https://kipalog.com/posts/Chuyen-tu-Brunch-sang-Webpack-project-Phoenix>
[7/26/2017, 1:26:19 AM] [tucq88]: wpack ftw
[7/26/2017, 7:22:06 PM] [phugodness]: @unrealhoang truong hop hon 11 so trong chuoi ```"12312312323" | 0 ``` se ra ket qua sai nen dung + van tot hon nhi
[7/26/2017, 7:22:41 PM] [unrealhoang]: :+1:
[7/26/2017, 7:23:15 PM] [unrealhoang]: thật ra trò `|` là trong spec của asm.js
[7/26/2017, 7:23:37 PM] [unrealhoang]: để force 1 biến thuộc type int
[7/26/2017, 7:24:11 PM] [unrealhoang]: nên chính xác thì sẽ là &gt; 2^31-1
[7/26/2017, 7:24:18 PM] [unrealhoang]: sẽ không ra đúng
[7/26/2017, 11:29:32 PM] []: #til Có cái Krita thì ko phải lấn cấn khi dùng Ubuntu mà nhớ nhung Adobe Photoshop. Biết thêm Qt framework (C++) để code cross-platform embedded và desktop app nữa.
<https://krita.org/en/>
<https://www.qt.io/>
[7/27/2017, 4:47:43 AM] [Cậu Làm Vườn]: Nice. Seems like something that is more on the artistic side of the design spectrum. I can't draw even if my life depends on it though. :neutral_face:
I use Figma, which is more like a cross-platform alternative for web wireframe and mockup. Kinda doubtful at first, but hey it's better than nothing.
[7/27/2017, 5:01:14 AM] []: @harrisnguyen I feel you bro. But when all we have are PSD files from designer. Then we have to open them to extract icons, get correct number of distance or size of elements.
[7/27/2017, 5:13:15 AM] [Cậu Làm Vườn]: @thaod Oh, so THAT'S the point. Cool, definitely going to check it out. Figma has trouble supporting psd. Thanks.
[7/27/2017, 5:20:43 AM] []: I checked the Figma and find it interesting. Thank you too.
[7/28/2017, 1:57:10 AM] [tanlinhnd]: #til
```
p := new(chan int) // p has type: *chan int
c := make(chan int) // c has type: chan int
```
[7/28/2017, 2:01:10 AM] [hasagi]: ngoài channel ra còn có map/slice cũng hoạt động cơ chế tương tự
[7/28/2017, 2:03:56 AM] [hasagi]: thật ra thì new sẽ không được sử dụng cho những DS như map/slice/channel
[7/28/2017, 2:04:06 AM] [hasagi]: vì mấy thằng đó ko được initialized thì sẽ ko xài đc
[7/29/2017, 2:23:22 PM] [halcyonl]: #til <https://stackoverflow.com/questions/32461229/why-use-redux-over-facebook-flux>
[7/30/2017, 6:10:57 AM] []: #til:
Range long long : –9,223,372,036,854,775,808 to 9,223,372,036,854,775,807
[8/1/2017, 2:12:57 PM] [halcyonl]: #til chơi khủng long ngay cả khi có mạng: <chrome://dino/>
[8/1/2017, 8:40:19 PM] [huy]: #til Trên Linux, để font render mượt như trên Mac, thì ngoài ba cái font antialiasing ra, nên config thêm sub-pixel rendering, khi đã bật subpixel thì phải bật thêm lcdfiltering <https://wiki.archlinux.org/index.php/font_configuration#Subpixel_rendering>
[8/1/2017, 9:06:06 PM] []: too complicated :troll:
[8/1/2017, 9:07:04 PM] [huy]: :arggg:
[8/1/2017, 10:49:49 PM] []: Ngon
[8/1/2017, 10:49:52 PM] []: Tối em thử
[8/1/2017, 11:04:17 PM] [unrealhoang]: tối thử
[8/1/2017, 11:04:18 PM] [unrealhoang]: Ngon
[8/1/2017, 11:06:34 PM] [hieu.huynh]: ngon đó anh @snacky :+1: tối về thử :think:
[8/3/2017, 1:21:31 AM] [tucq88]: @snacky Buy a Mac. Problem solved.
[8/3/2017, 1:31:07 AM] []: Lol, hoang đường
[8/3/2017, 1:31:28 AM] []: @tucq88 đây là team có mac mà bỏ nha anh
[8/3/2017, 1:31:38 AM] [tucq88]: :"&gt;
[8/3/2017, 1:31:51 AM] [tucq88]: nem da hoi nghi :"&gt;
[8/3/2017, 1:31:57 AM] [unrealhoang]: x220 vì 1 thế giới tươi đẹp hơn
[8/3/2017, 1:32:01 AM] [tucq88]: ...
[8/3/2017, 1:32:14 AM] [tucq88]: X1 Carbon di :v
[8/3/2017, 1:36:09 AM] [giangnh]: vào đây
[8/3/2017, 1:36:16 AM] [giangnh]: ai không dùng vim là bị ném đó hội nghị
[8/3/2017, 1:38:08 AM] []: @giangnh đá*
[8/3/2017, 1:39:11 AM] [giangnh]: @ldhnam :okay:
[8/3/2017, 8:06:01 AM] []: #til: Tiết kiệm 10G máy ảo trên máy windows cài vagrant. Khi ổ C quá nhiều, cần di chuyển qua ổ khác.
Sửa file
C:\Users\{user name}\.VirtualBox\VirtualBox.xml và VirtualBox.xml-prev. Thay đường dẫn trỏ vào file ở ổ C thành D. Copy file qua ổ D.
```
&lt;MachineRegistry&gt;
&lt;MachineEntry uuid="{353e2f87-c081-4333-80ec-f1d43b4555b8}" src="D:\VirtualBox VMs\vagrant_1501327572850_23472\vagrant_1501327572850_23472.vbox"/&gt;
&lt;MachineEntry uuid="{c29b97de-6baf-4fce-8906-900b05f2f14f}" src="D:\Genymobile\Genymotion\deployed\Custom Phone - 4.1.1 - API 16 - 768x1280\Custom Phone - 4.1.1 - API 16 - 768x1280.vbox"/&gt;
&lt;/MachineRegistry&gt;
.
.
.
&lt;SystemProperties defaultMachineFolder="D:\VirtualBox VMs" defaultHardDiskFormat="VDI" VRDEAuthLibrary="VBoxAuth" webServiceAuthLibrary="VBoxAuth" LogHistoryCount="3" exclusiveHwVirt="false"/&gt;
```
[8/4/2017, 1:44:28 AM] [hasagi]: #til Khi lỡ xóa .zshrc hay .bashrc thì nhớ `printenv` ra để gỡ gạc
[8/4/2017, 2:00:44 AM] [unrealhoang]: sao không add mấy cái đó vô repo
[8/4/2017, 2:00:46 AM] [unrealhoang]: :think:
[8/4/2017, 9:21:20 AM] []: #til: Đăng ký license cho máy ảo andoird.
<https://stackoverflow.com/questions/40392345/ionic-build-error-you-have-not-accepted-the-license-agreements-of-the-followin>
```
mkdir "%ANDROID_HOME%\licenses"
echo |set /p="8933bad161af4178b1185d1a37fbf41ea5269c55" &gt; "%ANDROID_HOME%\licenses\android-sdk-license"
```
[8/5/2017, 10:10:12 AM] []: #til: Cách học đúng ở đại học.
<http://science-technology.vn/?p=5477>
[8/7/2017, 1:10:33 AM] [meowwwwwwwwwwwwwwww]: #til
<https://swagger.io/>
[8/7/2017, 2:15:31 AM] [phat]: #til
<https://stackoverflow.com/a/13965459>
`git log master..branch-X`
`git log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr)%Creset' --abbrev-commit --date=relative master..branch-X`
[8/7/2017, 2:24:39 AM] [hieu.huynh]: #til design infra, familiar with git
<http://asciiflow.com|asciiflow.com>
[8/7/2017, 1:45:14 PM] [halcyonl]: #til `console.table([{a:1, b:2},{a:3, b:4}]);`
[8/9/2017, 6:36:39 PM] []: #til, right way to debug is to write unit tests for your hypotheses.
[8/10/2017, 4:22:25 AM] []: #til : View log Emulator Android :
`adb logcat *:S ReactNative:V ReactNativeJS:V &gt; log.txt`
[8/10/2017, 4:07:20 PM] [huy]: #til Switching between integrated terminal and code in VSCode
```
[
{ "key": "ctrl+`", "command": "workbench.action.terminal.focus"},
{ "key": "ctrl+`", "command": "workbench.action.focusActiveEditorGroup", "when": "terminalFocus"}
]
```
[8/10/2017, 8:51:08 PM] [cangtt]: sao chuyển qua dùng VSCode rồi :smile:
[8/10/2017, 8:52:54 PM] [huy]: =))) dunùng thử ít ngày xem cảm giác thế nào a
[8/10/2017, 8:53:38 PM] [cangtt]: haha, anh thì thấy linter UI tốt với hỗ trợ debug cũng tốt
[8/10/2017, 8:53:55 PM] [huy]: e chưa dùng cái debug của nó
[8/10/2017, 8:54:00 PM] [huy]: cơ mà cảm giác type khá sướng
[8/10/2017, 8:56:55 PM] [cangtt]: à nếu em có dùng cái integrated terminal thì cẩn thận mấy cái system variables (có thể em sẽ ko bị), vì anh đang gặp 1 cái issue <https://github.com/Microsoft/vscode/issues/32213>
[8/10/2017, 8:58:21 PM] [huy]: a lưu biến môi trường như thế nào
[8/10/2017, 8:59:12 PM] [cangtt]: anh dùng gem `dotenv-rails` nên anh lưu trong file `.env` ở project root
[8/10/2017, 9:05:32 PM] [huy]: à
[8/10/2017, 9:05:39 PM] [huy]: e toàn quản lý env var ở .bash_profile
[8/16/2017, 6:01:42 AM] []: #til `ArrayBuffer`, `FileReader `
[8/16/2017, 8:23:44 PM] [huy]: #til "⌘Command + ⇧Shift + I" to sync command in iterm2
[8/21/2017, 12:49:16 AM] [hieu.huynh]: #til Gõ `u` để undo trong vim khi lỡ xoá cái gì đó :pray:
[8/21/2017, 12:51:19 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: `Ctrl + R` để redo :troll:
[8/21/2017, 12:52:00 AM] [huynh.cam]: `Cmd+Q` để restart
[8/21/2017, 1:07:58 AM] [unrealhoang]: không xúi dại nhé
[8/21/2017, 1:12:44 AM] [hieu.huynh]: :ie: :okay:
[8/21/2017, 1:14:25 AM] [hieu.huynh]: :pray:
[8/21/2017, 1:34:37 AM] []: :omg:
[8/21/2017, 1:34:51 AM] []: gõ `:Tutor` rồi học đang hoàng đi nào
[8/21/2017, 2:28:18 AM] [tay vịn của anh bán chuối - cty A tìm FE]: qua #general đi bạn ơi
[8/21/2017, 2:32:16 AM] []: Mình chuyển qua rồi :smile:
[8/21/2017, 2:47:03 AM] [hieu.huynh]: #til `docker.for.mac.localhost` :sexy:
[8/21/2017, 2:47:07 AM] [hieu.huynh]: :dogejump:
[8/21/2017, 6:06:42 AM] [huynh.cam]: #til `%`: nhảy tới dấu ngoặc `{}` `{}` `[]` gần nhất trong VIM
[8/21/2017, 6:58:50 AM] []: #til: `vim ~` hoặc `:e .` để coi các file , folder với Vim
[8/21/2017, 7:06:07 AM] []: #til: Chạy file .bat, .exe trong window với Git Bash. `./run.bat` , `./run.exe`
[8/21/2017, 9:47:31 AM] [huuson235]: #til np: numpy.argmax vs axis=x nó sẽ đâm thủng mảng theo trục x để tìm max
[8/21/2017, 7:06:35 PM] [anh bán chuối]: `đâm thủng mảng` là sao bạn @huuson235 :smile:
[8/23/2017, 9:07:27 PM] []: #til Using `rabbitmq` to send and receive message between system components.
[8/25/2017, 5:09:58 AM] [hasagi]: #til `docker system prune -a -f`
[8/25/2017, 5:52:40 AM] []: Hoặc là click nút reset nha
[8/25/2017, 7:21:41 AM] [hasagi]: :v
[8/25/2017, 7:21:51 AM] [hasagi]: tren gitlab runner ma reset kieu gi gio
[8/25/2017, 11:56:51 AM] []: :omg:
[8/28/2017, 3:06:28 AM] [hieu.huynh]: #til trong VPN, có kĩ thuật `Split tunneling` nữa, một phát hiện thú vị :raised_hands:
*TL;DR*: mình có thể flexible cái request nào qua tunnel, cái nào đi trực tiếp
*Example*:
- mình cần 1 cái VPN có đầu ra ở us, để xài dịch vụ spotify, và mình chỉ muốn tunnel cái đó thôi, còn request khác như vào youtube thì ko qua.
- Default là tất cả sẽ cho qua tunnel, như thế chỗ request dô youtube sẽ chậm
`Split tunneling` là giải pháp cho vấn đề :omg: :fastparrot: :sexy: :all-the-things:
[8/28/2017, 3:27:57 AM] []: :omg:
[8/28/2017, 7:39:50 AM] [hieu.huynh]: Note lại cái, ko sau này lại quên :doubt:
<https://github.com/hieuhtr/Blog/issues/68>
[8/28/2017, 9:46:04 PM] [huy]: #til Use NYTimes mobile site for better readability <https://mobile.nytimes.com/>
[8/29/2017, 12:51:45 AM] [SFzxc]: #til jquery and style `display: none`, the story of pain :grin:
[8/29/2017, 12:52:24 AM] [SFzxc]: <https://gabrieleromanato.name/jquery-css-display-none-problems-solutions-overview>
[8/30/2017, 8:04:17 PM] [huy]: #til use mobile wikipedia for clean view <https://en.m.wikipedia.org/wiki/Moving_average#>
[8/30/2017, 11:28:30 PM] [phat]: <https://www.reddit.com/r/youtube/comments/2ve5gz/shortcut_for_2x_speed/>
[8/30/2017, 11:43:43 PM] [manhdv]: #til `git fetch --prune origin`
for pruning deleted remote branches.
[8/31/2017, 12:12:46 AM] [hieu.huynh]: #til `df -h --total` :doubt: :ie: :okay:
```
Filesystem Size Used Avail Use% Mounted on
udev 992M 0 992M 0% /dev
tmpfs 200M 14M 187M 7% /run
/dev/xvda1 20G 11G 8.9G 55% /
tmpfs 1000M 1.6M 998M 1% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 1000M 0 1000M 0% /sys/fs/cgroup
tmpfs 200M 0 200M 0% /run/user/1000
total 23G 11G 13G 47% -
```
[8/31/2017, 4:15:10 AM] [hieu.huynh]: #til Jenkins nó automatic create user :pray:
nó base trên SCM, nó detect account nào có commit, nó tự lấy email của git user đó, tạo bên jenkins 1 cái account y vậy
nhưng ko login dc, dị vkl
[8/31/2017, 4:16:02 AM] [hieu.huynh]: làm cứ tưởng thằng nào hack mịa vô con jenkins của mình (vì chỉ mình biết auth), đâu lòi ra cả đống user quen thuộc
[8/31/2017, 4:24:35 AM] [hieu.huynh]: Từ hồi jenkins dính vulnerability cho remote execute, cài cắm đào coin, giờ thấy cái gì lạ lạ như này cũng run tim vãi ==”
[8/31/2017, 9:51:09 PM] [alias Trung.Le, as tle]: #til `git add -u` to add only modified files to stage
[8/31/2017, 9:52:48 PM] [alias Trung.Le, as tle]: #til setting state `setState()` in `componentDidMount()` would trigger re-rendering in ReactJS
[9/4/2017, 7:13:57 AM] []: #til: <https://github.com/reactjs/react-rails>
[9/6/2017, 8:39:41 PM] [hieu.huynh]: #til `sudo lsof -i :port` coi port này được process nào lắng nghe, cần quyền root
```
ubuntu@CI:~$ sudo lsof -i :8080
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
java 1343 jenkins 152u IPv6 131732 0t0 TCP *:http-alt (LISTEN)
```
[9/6/2017, 8:40:10 PM] [hieu.huynh]: Cho nhiều info hơn `netstat`
[9/7/2017, 7:22:50 PM] []: #til:
npm-check-updates is a utility that automatically adjusts a package.json with the latest version of all dependencies
```
$ npm install -g npm-check-updates
$ npm-check-updates -u
$ npm install
```
[9/7/2017, 7:51:41 PM] [dan]: #til facebook notes
[9/9/2017, 3:01:19 AM] []: #til:
Xóa 1 phần tử trong heap
- dùng heap tạm tốn: O(LogN)
- dùng array tạm tốn: O(N)
[9/9/2017, 10:02:45 PM] []: #til: To do Proxy with Apache
```
&lt;VirtualHost *:80&gt;
ProxyPreserveHost On
ProxyRequests Off
ServerName gotour.local
ProxyPass / <http://127.0.0.1:3999/>
ProxyPassReverse / <http://127.0.0.1:3999/>
&lt;/VirtualHost&gt;
```
[9/10/2017, 10:35:17 PM] [huy]: #til Do not skip any section when you read technical articles
[9/11/2017, 1:11:09 AM] [hasagi]: #til bash regex xài `0-9` thay cho `\d`
[9/11/2017, 4:43:45 AM] [unrealhoang]: #til Ruby’s `binding` object
[9/11/2017, 9:55:52 AM] [tanlinhnd]: #til Golang use Capitals for exported fields/methods
[9/12/2017, 9:10:44 PM] [hieu.huynh]: #til *`AWS RDS`*
```
The following are some limitations to stopping and starting a DB instance:
You can't stop a DB instance that has a Read Replica, or that is a Read Replica.
You can't stop a DB instance that is in a Multi-AZ deployment.
You can't stop a DB instance that uses Microsoft SQL Server Mirroring.
You can't modify a stopped DB instance.
You can't delete an option group that is associated with a stopped DB instance.
You can't delete a DB parameter group that is associated with a stopped DB instance.
```
[9/12/2017, 9:24:28 PM] [hieu.huynh]: #til *`AWS RDS`*
```
You have not checked the 'Apply Immediately' option. As such, some of the modifications you are making may only take effect during your next maintenance window.
```
[9/12/2017, 9:26:18 PM] [hieu.huynh]: mindset hay quá, phục mấy bác engineer aws quá
[9/14/2017, 12:43:11 AM] [handcode]: <https://stackoverflow.com/questions/20423521/process-perminantly-stuck-on-d-state>
[9/14/2017, 2:23:24 AM] []: #til shaker sort and xorshift
[9/14/2017, 6:47:51 PM] [phugodness]: #til `transpose` ruby method
[9/14/2017, 9:02:35 PM] []: &gt;Don't be fooled by those advising that when using `*` in COUNT, it fetches entire row from your table, saying that `*` is slow. The `*` on SELECT COUNT(`*`) and SELECT `*` has no bearing to each other, they are entirely different thing, they just share a common token, i.e. `*`.
<https://stackoverflow.com/questions/2710621/count-vs-count1-vs-countpk-which-is-better>
[9/14/2017, 9:12:50 PM] [huy]: A typical day on StackOverflow <https://i.imgur.com/hPimraf.png>
[9/14/2017, 9:13:53 PM] [huy]: #goodjobme
[9/14/2017, 9:16:24 PM] []: lol, and FYI
&gt; `count(*)` is slightly faster `count(pk)`
<https://dba.stackexchange.com/questions/41090/postgres-count-vs-countid>
[9/14/2017, 9:17:10 PM] [huy]: thế cái nào nhanh nhất?
[9/14/2017, 9:17:12 PM] [huy]: count(1) ?
[9/14/2017, 9:17:45 PM] []: &gt;Bottom Line
&gt;Use either COUNT(field) or COUNT(`*`), and stick with it consistently, and if your database allows COUNT(tableHere) or COUNT(tableHere.`*`), use that.
&gt;In short, don't use COUNT(1) for anything. It's a one-trick pony, which rarely does what you want, and in those rare cases is equivalent to count(*)
[9/14/2017, 9:18:25 PM] [huy]: kết quả là vẫn như vậy
[9/14/2017, 9:18:27 PM] [huy]: :think:
[9/14/2017, 9:18:40 PM] []: cơ bản thì nó same same
[9/14/2017, 9:18:49 PM] []: vì có mấy bài giải thích
[9/14/2017, 9:19:00 PM] []: là count(*) nó cũng parse ra column
[9/14/2017, 9:19:11 PM] [huy]: thì a nghĩ
[9/14/2017, 9:19:13 PM] [huy]: khi data trả về
[9/14/2017, 9:19:17 PM] [huy]: nó trả full column
[9/14/2017, 9:19:22 PM] [huy]: e chỉ định 1 column bất kì
[9/14/2017, 9:19:26 PM] [huy]: nó phải find trong đó
[9/14/2017, 9:20:01 PM] []: <https://www.citusdata.com/blog/2016/10/12/count-performance/>
[9/14/2017, 9:20:08 PM] []: ```A note about count(1) vs count(*). One might think that count(1) would be faster because count(*) appears to consult the data for a whole row. However the opposite is true. The star symbol is meaningless here, unlike its use in SELECT *. PostgreSQL parses The expression count(*) as a special case taking no arguments. (Historically the expression ought to have been defined as count().) On the other hand count(1) takes an argument and PostgreSQL has to check at every row to see that ts argument, 1, is indeed still not NULL.```
[9/14/2017, 9:21:17 PM] [huy]: đù
[9/14/2017, 9:21:20 PM] [huy]: đoán như thần
[9/14/2017, 9:21:23 PM] [huy]: đoán đâu trúng đó
[9/14/2017, 9:21:25 PM] [huy]: mình nể mình quá
[9/14/2017, 9:21:30 PM] [huy]: :trung:
[9/14/2017, 9:23:48 PM] []: anh đoán sai mà, `count(*)` nhanh hơn `count(1)`
[9/14/2017, 9:23:51 PM] []: :think:
[9/14/2017, 9:24:11 PM] []: &gt; However the opposite is true.
[9/14/2017, 9:24:20 PM] [huy]: anh đoán count(*) so với count(key) mà :think:
[9/14/2017, 9:26:48 PM] []: key là `primary key` à? Nếu vậy `count(*)` cũng nhanh hơn luôn. Còn nếu là `key` là column thì nó ra 2 kết quả khác nhau
[9/14/2017, 9:27:05 PM] []: COUNT(*) counts all rows
COUNT(column) counts non-NULLs only
[9/14/2017, 9:28:47 PM] [huy]: :think: any column thi fđúng hơn
[9/14/2017, 9:28:55 PM] [huy]: cơ mà a vẫn tự nhận là a đoán đúng
[9/14/2017, 9:29:02 PM] [huy]: sống đơn giản vậy cho khỏe :duncare:
[9/14/2017, 9:29:07 PM] [huy]: :roflrofl:
[9/14/2017, 9:29:26 PM] []: :simple_smile:
[9/14/2017, 9:29:37 PM] []: :nail_care:
[9/15/2017, 12:14:06 AM] [hasagi]: mình toàn COUNT *
[9/15/2017, 12:14:08 AM] [hasagi]: :think:
[9/15/2017, 12:14:54 AM] [hasagi]: thật ra là do GORM internally nó count *
[9/15/2017, 12:14:55 AM] [hasagi]: :kappa:
[9/15/2017, 7:14:58 PM] [dan]: #til Android ADB Input Event <https://stackoverflow.com/questions/7789826/adb-shell-input-events>
[9/19/2017, 12:21:18 AM] [hieu.huynh]: #til *Bài học nhớ đời*:
Vô jenkins chỉnh chọt credential, permission các thứ … mà quên set full quyền cho account admin
Chừng apply 1 phát, bị đá ra ngoài hết vô được luôn, khóc tiếng mán :sosad:
May nhờ thò ssh vô, chọc cái file `/var/lib/jenkins/config.xml` disable security đi, restart lại, cứu vãn dc, ko tèo rầu
[9/19/2017, 2:37:31 AM] [hasagi]: #til use COPY over ADD dockerfile
[9/19/2017, 5:09:24 AM] []: Tại sao :troll:
[9/19/2017, 6:21:45 AM] [hasagi]: ADD nó có khá nhiều magic behind
[9/19/2017, 6:22:11 AM] [hasagi]: cho phép down từ remote url, hay decompress functionality
[9/19/2017, 6:22:29 AM] [hasagi]: mà do là hôm qua viết cái dockerfile để ADD chạy ko đc chuyển COPY thì đc
[9/19/2017, 6:22:31 AM] [hasagi]: :roflrofl:
[9/19/2017, 8:24:03 AM] []: #til: Rails deploy khó hơn PHP
[9/19/2017, 8:24:42 AM] [noob]: có vậy à :neutral_face:
[9/19/2017, 8:45:07 AM] []: dạ :smile:
[9/20/2017, 7:56:09 PM] [tucq88]: #til Lọ mọ `sed` 101
<https://gist.github.com/tucq88/a653e7147ca3cfffea4ae908f9309d75>
Block your wasting time websites =&gt; de-procrastinate :v
[9/21/2017, 11:13:14 PM] [meowwwwwwwwwwwwwwww]: #til Model.human_attribute_name
[9/22/2017, 12:03:37 AM] [anh bán chuối]: =)) why. PHP dễ nhất quả đất rồi mà
[9/22/2017, 12:06:38 AM] [phat]: #til <https://www.websequencediagrams.com/>
[9/22/2017, 12:47:35 AM] [hieu.huynh]: #til dùng aws cli, chọc vô RDS mới export ra dc parameter group (nhớ option `--source user` ko thì ngập mặt)
chứ vô aws console thì thua, ko thể export ra dc
[9/22/2017, 12:48:35 AM] [hieu.huynh]: bắt đầu yêu RDS :beauty:
[9/22/2017, 1:43:24 AM] [manhdv]: aws cli sieu ba dao, lam duoc nhung viec ma aws console ko the lam duoc, du cung` 1 user.
[9/22/2017, 1:52:27 AM] [hasagi]: Ví dụ xem a :thinking_face:
[9/22/2017, 1:52:35 AM] [hasagi]: à nhớ rồi
[9/22/2017, 1:52:43 AM] [hasagi]: ví dụ delete IAM
[9/22/2017, 1:52:59 AM] [hasagi]: nhớ có lần phải dùng cli để delete vì console ko làm đc
[9/22/2017, 2:06:31 AM] [manhdv]: delete s3 Bucket nua chang han. Co lan minh ko delete duoc bang console, ma phai dung cli :neutral_face:
[9/22/2017, 2:07:05 AM] [hasagi]: :confused:
[9/22/2017, 2:07:18 AM] [hasagi]: weird
[9/22/2017, 2:07:25 AM] [SFzxc]: lúc trước migrate data (sync )từ s3 acc này qua s3 account khác bằng cli hok biết console có làm đc hok :think:
[9/22/2017, 2:07:46 AM] [hasagi]: đc
[9/22/2017, 2:07:55 AM] [hasagi]: copy đc :think:
[9/22/2017, 2:08:23 AM] [SFzxc]: account khác nhau nha chế
[9/22/2017, 2:08:27 AM] [SFzxc]: :think:
[9/22/2017, 2:09:57 AM] [hieu.huynh]: thì cái TIL của em đó, aws cli làm dc, mà console ko làm dc
[9/22/2017, 2:09:58 AM] [hieu.huynh]: ezzz
[9/22/2017, 2:10:02 AM] [hieu.huynh]: same account
[9/28/2017, 9:39:59 PM] [meowwwwwwwwwwwwwwww]: #til <https://robots.thoughtbot.com/using-hashes-to-bring-back-the-dinosaurs>
[10/2/2017, 12:17:26 AM] [hieu.huynh]: #til fall in love with SQS aws :beauty:
[10/2/2017, 12:18:34 AM] [hieu.huynh]: 1tr msg có 0.4$ (+ data transfer)
[10/3/2017, 8:03:59 PM] [hieu.huynh]: #til curator es dạo này đẻ ra thêm thằng singleton-cli nữa, ko xài dc mấy script cũ viết trên fucntion của curator, viết lại cực khổ phếch :expressionless: bù lại thì đã bỏ dc mấy option lằng nhằng như --older-than newer than…. --&gt; thành prefix khá ngon lành
[10/3/2017, 8:04:08 PM] [hieu.huynh]: <https://www.elastic.co/guide/en/elasticsearch/client/curator/current/singleton-cli.html>
[10/8/2017, 10:06:11 AM] [alias Trung.Le, as tle]: #til <https://groups.google.com/forum/#!topic/elixir-lang-talk/6kn7J2XnFg8>
[10/10/2017, 4:40:43 AM] [huynh.cam]: #til `rails runner /path/to/ruby/file` :see_no_evil: :ie:
[10/12/2017, 8:32:59 PM] [minh.nguyen]: #til XHTML <https://www.w3schools.com/html/html_xhtml.asp> :monkey_face:
[10/13/2017, 9:35:01 PM] [minh.nguyen]: #til <http://www.rubydoc.info/stdlib/core/Array:pack>
[10/16/2017, 7:18:21 PM] [alias Trung.Le, as tle]: mấy thím mấy bác có khi nào bị đám Tây nó nhầm cái tên đệm không? Vd Nguyễn Văn A, nó ghi thành Văn A NGUYEN, có thằng thì lại ghi A Văn Nguyễn, theo kn cá nhân thì nên nói đám nó dùng giao ước nào? :trollface:
[10/16/2017, 8:26:16 PM] []: Em cũng có cùng thắc mắc nhức nhối như anh.
Em có hai người bạn làm luật thấy họ ghi tên của họ là nối cả tên đệm vào tên chính luôn:
Van-A NGUYEN
[10/16/2017, 11:31:55 PM] [alias Trung.Le, as tle]: #til the
``` -S killsig
Specify the number of the signal to be sent to the
process killtime seconds after warntime has expired.
Defaults to 9 (SIGKILL).
-s warnsig
Specify the number of the signal to be sent to the
process warntime seconds after it has been started.
Defaults to 15 (SIGTERM).
```
of `curl`, which is useful for scripting hitting an endpoint to check if the host is alive, for eg `curl -sS localhost/are_you_up`, if the server does not respond, the signal would be send to the process to kill itself
[10/16/2017, 11:46:35 PM] [alias Trung.Le, as tle]: khổ nỗi là trên hộ chiếu VN có hẳn field middle name ...
[10/16/2017, 11:46:35 PM] [alias Trung.Le, as tle]: hic
[10/16/2017, 11:46:52 PM] [alias Trung.Le, as tle]: thế nên đám nó bưng luôn cái khái niệm middle name áp vào kiểu tên tiếng Anh
[10/16/2017, 11:47:13 PM] [alias Trung.Le, as tle]: thế nên có nhiều trường hợp nếu ghi tên nối Van-A thì đám nó không công nhận
[10/16/2017, 11:47:39 PM] [alias Trung.Le, as tle]: phải là A Văn, theo qui tắc tên Anh &lt;firstName&gt; &lt;middleName&gt; &lt;lastName&gt;
[10/16/2017, 11:47:41 PM] [alias Trung.Le, as tle]: khổ thế
[10/16/2017, 11:47:41 PM] [alias Trung.Le, as tle]: hic
[10/17/2017, 1:12:09 AM] [Anh Xe Ôm]: #til `golang` even built-in type, some data struct ain’t zero cost abstraction, be careful when you use `=` and `:=`
[10/18/2017, 7:05:14 PM] [manhdv]: #til Ruby `Array#pack`
<https://apidock.com/ruby/Array/pack>
`["n"].pack("A5") == "n".ljust(5, " ")`
[10/19/2017, 2:15:39 AM] [hieu.huynh]: #til really big big big TIL ever
```
sudo su -l www-data -s /bin/bash
```
<https://askubuntu.com/a/948488/668849>
[10/19/2017, 10:06:36 AM] []: #til:
```
constructor() {
super();
this.state = {
list: [1, 2, 3, 4, 5]
}
}
handleClick = (e) =&gt; {
let list = this.state.list;
list.push(this.state.value);
this.setState();
}
```
Ko cần truyền params vào this.setState(); :notbad:
[10/19/2017, 10:47:23 AM] [huy]: Trong trường hợp này thì theo bác nghĩ chuyện gì sẽ xảy ra và vì sao vẫn setState được? point nằm ơ chỗ này
[10/19/2017, 1:13:31 PM] [noob]: ko nên dùng thế này
[10/19/2017, 1:15:21 PM] [huy]: để bác haond trả lời vì sao như thế này vẫn chạy đc đã a :))
[10/19/2017, 1:15:25 PM] [huy]: mà vì sao ko nên
[10/19/2017, 6:44:25 PM] [manhdv]: `this.setState() == Object.assign(state, undefined) == state` =&gt; work
[10/19/2017, 7:26:38 PM] [alias Trung.Le, as tle]: #til Today I learn:
boobies, tits, Diks, crappie, shag, slippery dick, ass, bitch, cockchafer
How much I love science
[10/19/2017, 8:43:44 PM] [huy]: #til Wikipedia + Send to Kindle = smarter everyday
[10/19/2017, 9:11:38 PM] [Anh Xe Ôm]: #til store IP address as an int32 is very effective for hash, indexing and searching
```
/*
string: 192.168.1.1
binary: 11000000 . 10101000 . 00000001 . 00000001
integer: 3232235777
*/
type IPv4 int32
/* GetIPv4Integer return an integer, which present for ip address
@ipstr ip as a string, eg 192.168.1.1
*/
func GetIpByAddress(ipstr string) IPv4
```
[10/19/2017, 9:49:59 PM] [tanlinhnd]: vụ store as int32 em cũng từng dùng 1 lần, để detect xem thằng IP này nằm trong range nào
[10/19/2017, 9:54:58 PM] [alias Trung.Le, as tle]: @mquy? sao lại có emoji đó
[10/19/2017, 9:55:06 PM] [alias Trung.Le, as tle]: mấy từ trên đâu có gì đen tối đâu
[10/20/2017, 12:08:36 AM] [alias Trung.Le, as tle]: @mquy có lẽ em nghĩ bậy rồi :wink:
[10/20/2017, 12:08:38 AM] [alias Trung.Le, as tle]: nè vd
[10/20/2017, 12:08:43 AM] [alias Trung.Le, as tle]: <https://en.wikipedia.org/wiki/Booby>
[10/20/2017, 12:08:55 AM] [alias Trung.Le, as tle]: <https://en.wikipedia.org/wiki/Tit_(bird)>
[10/20/2017, 12:09:33 AM] [alias Trung.Le, as tle]: <https://en.wikipedia.org/wiki/Dik-dik>
[10/20/2017, 12:09:59 AM] [alias Trung.Le, as tle]: <https://en.wikipedia.org/wiki/European_shag>
[10/20/2017, 12:10:22 AM] [alias Trung.Le, as tle]: <https://en.wikipedia.org/wiki/African_wild_ass>
[10/20/2017, 12:57:15 AM] [huynh.cam]: #til cờ vua không có con pháo :troll:
[10/20/2017, 1:14:15 AM] [noob]: :sexy:
[10/21/2017, 1:51:02 AM] [handcode]: <https://devdocs.io>
[10/21/2017, 1:20:54 PM] [huynh.cam]: #til how to stop Apple from nagging you to upgrade new OS everyday? `Upgrade Tonight` -&gt; `Disagree` the term of use.
[10/22/2017, 3:52:54 AM] []: @snacky: Ở đây e đang dùng list reference đến object của this.state.list. Khi thay đổi list thì this.state.list cũng thay đổi theo. Và this.setState tạo action đưa vào queue.
Nó work thì như trên bác manhdv đã đề cập.
:smile:.
[10/24/2017, 12:25:01 AM] [Anh Xe Ôm]: #til con gà mái nó không biết gáy
[10/25/2017, 9:50:15 PM] [huy]: #til V8 uses hidden class to speed up Object's properties modification/lookup
[10/26/2017, 12:09:18 AM] [hieu.huynh]: #til ssh compression :beauty:
[10/26/2017, 3:18:40 AM] [tay vịn của anh bán chuối - cty A tìm FE]: coi optimise thì tiện coi luôn deoptimise đi thím
[10/26/2017, 3:18:44 AM] [tay vịn của anh bán chuối - cty A tìm FE]: @snacky
[10/26/2017, 3:39:23 AM] []: #til: hello world AWK
```
awk '{
print $1
}'
hello =&gt; hello
world =&gt; world
```
---- begin file helloworld ----
```{
print $1
}
```
----end file ----
`mawk -f hellowork`
[10/26/2017, 4:52:25 AM] [alias Trung.Le, as tle]: ?
[10/26/2017, 6:19:38 AM] [hieu.huynh]: by defaut: service ssh trên linux phía server sẽ enable sẵn compression, nhưng phần lớn ở phía client (như mac, linux client,…) sẽ ko bật cái này
[10/26/2017, 6:21:01 AM] [hieu.huynh]: khi ở client, anh chạy ssh, có `-vvv` nó sẽ ra cái dòng log
```
debug1: kex: server-&gt;client cipher: <mailto:chacha20-poly1305@openssh.com|chacha20-poly1305@openssh.com> MAC: &lt;implicit&gt; compression: none
debug1: kex: client-&gt;server cipher: <mailto:chacha20-poly1305@openssh.com|chacha20-poly1305@openssh.com> MAC: &lt;implicit&gt; compression: none
```
[10/26/2017, 6:22:13 AM] [hieu.huynh]: trong trường hợp mạng siêu chậm, anh cần speed up ssh, thì anh có thể thêm `-C` vào, nó sẽ bật tính năng compression phía client lên, tự pair với trên server, tốc độ load các file log bằng vim nhanh đáng kể, nuột lắm :smile:
[10/26/2017, 6:23:18 AM] [hieu.huynh]: ```
ssh -C user@host -vvv
debug1: kex: server-&gt;client cipher: <mailto:chacha20-poly1305@openssh.com|chacha20-poly1305@openssh.com> MAC: &lt;implicit&gt; compression: <mailto:zlib@openssh.com|zlib@openssh.com>
debug1: kex: client-&gt;server cipher: <mailto:chacha20-poly1305@openssh.com|chacha20-poly1305@openssh.com> MAC: &lt;implicit&gt; compression: <mailto:zlib@openssh.com|zlib@openssh.com>
```
[10/26/2017, 6:24:16 AM] [hieu.huynh]: có thể cấu hình fix cứng là *`Compression yes`* ở `~/.ssh/config` or /etc/ssh/ssh_config
[10/26/2017, 6:47:22 AM] [hieu.huynh]: kết hợp với vim -X nữa thì tuyệt vời :beauty:
[10/26/2017, 8:35:41 AM] [huy]: Ô kê
[10/26/2017, 7:18:47 PM] [manhdv]: Flow for ruby
<https://github.com/egonSchiele/contracts.ruby>
[10/26/2017, 8:43:45 PM] []: phải có tradeoff đâu đó chứ hat
[10/27/2017, 6:07:25 PM] [huy]: <http://xyproblem.info/> #til
[10/27/2017, 7:17:59 PM] []: TIL: Always buy insurance if it’s cheap.
[10/27/2017, 7:21:27 PM] [huy]: Life is uncertain
[10/28/2017, 12:43:19 AM] [anh bán chuối]: never ever bought any insurance in my life :think:
[10/28/2017, 2:44:28 AM] []: @longkt90: em vua phai huy chuyen bay lan thu 2 trong 1 thang day anh, mat 5 chai chi vi tiet kiem 88k cho bao hiem :disappointed:
[10/28/2017, 4:05:16 AM] [anh bán chuối]: :neutral_face: hic, nhưng bảo hiểm nó ko cho gì nhiều đâu. điều kiện claim cũng khó
[10/28/2017, 4:05:38 AM] [anh bán chuối]: khi nào book under company anh mới mua bảo hiểm
[10/28/2017, 4:06:22 AM] [anh bán chuối]: haha, tưởng em nói bảo hiểm sức khoẻ / người
[10/28/2017, 5:20:31 AM] []: hoặc đi hãng to bự
[10/28/2017, 11:33:58 AM] [huynh.cam]: #til <http://tldr.sh/>
[10/28/2017, 5:53:00 PM] [hasagi]: @hieuk09 là sao anh
[10/28/2017, 5:53:09 PM] [hasagi]: hủy chuyến bay thì bảo hiểm nó trả hả
[10/28/2017, 5:55:03 PM] [huy]: order vé máy bay thì có thêm cái tùy chọn có muốn mua gói bảo hiểm không, để khi cần hủy thì hủy được, hoặc cần đổi giờ thì đổi được mà không bị mất tiền vé đó mà
[10/28/2017, 5:55:19 PM] [hasagi]: hóa ra là cái này @@
[10/28/2017, 5:55:24 PM] [hasagi]: til
[10/28/2017, 5:55:51 PM] [hasagi]: ty
[10/28/2017, 5:56:21 PM] [huy]: ko có chi
[10/28/2017, 5:56:29 PM] [huy]: fck you :kiss:
[10/28/2017, 6:04:24 PM] [hasagi]: trước cứ tưởng bảo hiểm là rớt máy bay
[10/28/2017, 6:04:26 PM] [hasagi]: thì nó đền
[10/28/2017, 6:04:35 PM] [hasagi]: nhưng giờ nghĩ lại
[10/28/2017, 6:04:43 PM] [hasagi]: có điền thông tin gì đâu mà nó đền
[10/28/2017, 6:04:46 PM] [hasagi]: :omg:
[10/28/2017, 6:16:50 PM] [huy]: có số CMND hoặc passport là đủ rồi
[10/29/2017, 11:14:26 PM] [huy]: #til AtomicInteger trong java khi gia tri &gt;= MAX ma increment thi no se quay lai MIN
[10/29/2017, 11:15:03 PM] [huy]: :neutral_face: unsafe, unrealiable, dangerous
[10/29/2017, 11:51:30 PM] [unrealhoang]: ủa wrapping arithmetic em tưởng lúc nào java cũng vậy
[10/29/2017, 11:51:33 PM] [unrealhoang]: :think:
[10/29/2017, 11:51:46 PM] [unrealhoang]: ý là int cũng thế?
[10/29/2017, 11:51:55 PM] [unrealhoang]: @huydx
[10/29/2017, 11:52:15 PM] [huy]: uh :think:
[10/29/2017, 11:52:16 PM] [huy]: int cung the
[10/29/2017, 11:52:23 PM] [huy]: tai o cty co doan code
[10/29/2017, 11:52:37 PM] [huy]: return x = Math.abs(y.incrementAndSet % z)
[10/29/2017, 11:52:45 PM] [huy]: nen ban khoan la k biet y overflow thi gi xay ra
[10/29/2017, 11:54:05 PM] [unrealhoang]: uhm, btw, trong Rust thì ở debug build overflow = panic, ở release build thì overflow = wrapping @snacky
[10/29/2017, 11:55:14 PM] [huy]: đấy
[10/29/2017, 11:55:18 PM] [huy]: cái e muốn nói là
[10/29/2017, 11:55:31 PM] [huy]: roll over sẽ tạo ra unexpected behavior
[10/29/2017, 11:55:44 PM] [huy]: và những undocumented behavior
[10/29/2017, 11:55:49 PM] [huy]: cách tốt nhất là panic
[10/30/2017, 12:19:38 AM] [Anh Xe Ôm]: Theo em hiểu thì nó gọi là Atomic Operator, nên giá trị int trong nó khi vượt qua range thì sẽ quay lại giá trị ban đầu theo giá trị nguyên bản của uint32, kiểu như 2^32 cộng thêm 1 thì trở về 0.
[10/30/2017, 12:45:33 AM] [unrealhoang]: @duythinht nó gọi là wrapping arithmetic cưng ơi
[10/30/2017, 12:46:10 AM] [Anh Xe Ôm]: Thì bên dưới nó xài Atomic Operator mà :troll:
[10/30/2017, 12:46:40 AM] [unrealhoang]: atomic là tại vì nó là atomic
[10/30/2017, 12:46:41 AM] [unrealhoang]: :))
[10/30/2017, 12:47:00 AM] [Anh Xe Ôm]: :omg:
[10/30/2017, 12:47:37 AM] [unrealhoang]: atomic có vài kiểu guarantee nữa
[10/30/2017, 12:47:55 AM] [unrealhoang]: acquire, release với sequential consistency
[10/30/2017, 12:54:48 AM] [huy]: cai nay thuc ra k lien quan den atomic hay k :omg:
[10/30/2017, 12:54:55 AM] [huy]: ghi vao vi no la case lan nay gap thoi
[10/30/2017, 12:56:41 AM] [unrealhoang]: ý của @duythinht chắc là vì underlying atomic operation là wrapping
[10/30/2017, 12:57:22 AM] [unrealhoang]: chứ C/C++ overflow là UB thì phải
[10/30/2017, 12:57:36 AM] [unrealhoang]: đúng không @duythinht
[10/30/2017, 12:58:10 AM] [Anh Xe Ôm]: yep
[10/30/2017, 12:59:05 AM] [huy]: klq co ma golang la gi ta
[10/30/2017, 12:59:11 AM] [huy]: cung wrap a
[10/30/2017, 12:59:38 AM] [unrealhoang]: panic
[10/30/2017, 12:59:43 AM] [unrealhoang]: <https://github.com/golang/go/issues/19624>
[10/30/2017, 12:59:43 AM] [Anh Xe Ôm]: @huydx coi thử cách go chơi bời với atomic nè, do go không có magic abstract, nên sẽ nhìn thấy sự rõ ràng cách go chơi atomic một cách cục súc :troll:
<https://golang.org/pkg/sync/atomic/>
[10/30/2017, 12:59:47 AM] [unrealhoang]: Go 2
[10/30/2017, 1:00:39 AM] [huy]: atomic minh cung hay dung
[10/30/2017, 1:00:43 AM] [huy]: ten bien no dai ra ti voi golang thoi
[10/30/2017, 1:00:45 AM] [huy]: :omg:
[10/30/2017, 1:05:08 AM] [unrealhoang]: @huydx
[10/30/2017, 1:05:16 AM] [unrealhoang]: anh xài atomic trong go làm gì thế
[10/30/2017, 1:05:39 AM] [huy]: counter
[10/30/2017, 4:47:16 PM] [alias Trung.Le, as tle]: #til `position: sticky` #css
[10/30/2017, 5:55:19 PM] [huy]: #til `window.performance` and `window.performance.getEntitiesByType('resource')`
[10/31/2017, 4:03:38 AM] [tucq88]: `man` cmd that I was always searching for :v
[10/31/2017, 4:08:26 AM] [huynh.cam]: yeah it's so awesome!
[10/31/2017, 8:46:23 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :smile: mysql theo anh nhớ là ko phân quyền trên column đc, tối thiểu là table, ko em có thể chuyển qua postgres :troll:
[10/31/2017, 8:47:15 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: à ko, đc <https://dev.mysql.com/doc/refman/5.7/en/grant.html#grant-column-privileges>
[10/31/2017, 8:48:46 PM] [hieu.huynh]: <https://mariadb.com/kb/en/library/grant/#column-privileges>
[10/31/2017, 8:48:52 PM] [hieu.huynh]: ủa kì vại ta
[10/31/2017, 8:49:14 PM] [hieu.huynh]: cái Q&amp;A percona thì báo hông dc, document of mysql &amp; mariadb làm dc
[10/31/2017, 8:49:22 PM] [hieu.huynh]: em làm trên mariadb ko dc :neutral_face:
[10/31/2017, 9:00:17 PM] [hieu.huynh]: hây dà
[10/31/2017, 9:00:44 PM] [hieu.huynh]: nó chỉ cho grant select all column, hoặc grant select each column
[10/31/2017, 9:00:58 PM] [hieu.huynh]: nhưng ko cho revoke từng colume
[10/31/2017, 9:01:00 PM] [hieu.huynh]: :disappointed:
[10/31/2017, 9:03:32 PM] [hieu.huynh]: có thể hiểu GRANT là whitelist, còn REVOKE là remove cái whitelist, chứ ko phải blacklist
[11/1/2017, 5:20:29 AM] [alias Trung.Le, as tle]: #til docker volume
[11/1/2017, 6:11:56 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: là sao ko hiểu, ý là chỉ revoke cái đã grant?
[11/1/2017, 6:14:08 AM] [hieu.huynh]: dạ, revoke cái có trong bảng `show grants`
[11/1/2017, 6:58:17 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :think: rõ ràng, ko revoker hết rồi cấp lại sau
[11/1/2017, 7:06:34 AM] [hieu.huynh]: :troll:
[11/1/2017, 7:06:42 AM] [hieu.huynh]: vậy thì em đâu có la làng
[11/1/2017, 7:09:54 AM] [hieu.huynh]: hơi sida, em thử case này:
- grant all trên table A cho user dev
- revoke mỗi select trên tableA, cột x từ user dev
kết quả là hông dc, vì bảng grants nó chỉ hiểu là all privileges thôi :joy:
[11/1/2017, 7:11:02 AM] [hieu.huynh]: nói cách đơn giản nhất là như trên :point_up:
```
có thể hiểu GRANT là whitelist, còn REVOKE là remove cái gì trong cái whitelist đó, chứ ko phải làm blacklist
```
[11/1/2017, 7:11:46 AM] [hieu.huynh]: default ko grant gì, thì là *`blacklist 100%`* :roflrofl:
[11/1/2017, 9:55:04 PM] [hieu.huynh]: #til `~/.bash_profile` :beauty:
```
export PROMPT_COMMAND="history -a; history -c; history -r; $PROMPT_COMMAND"
```
[11/2/2017, 8:44:16 AM] [SFzxc]: #til docker FROM scratch
[11/2/2017, 9:26:07 PM] []: #til Hot coffee tastes way better than iced one
[11/2/2017, 9:26:27 PM] []: :think:
[11/2/2017, 9:28:14 PM] [huy]: một thanh niên có khả năng mới bước ra từ starbucks
[11/2/2017, 9:28:49 PM] []: đúng là ở starbucks thì phải uống nóng, còn lại ở đâu uống lạnh cũng ngon hơn
[11/2/2017, 9:29:14 PM] [huy]: sing ngoài starbucks ra có tiệm nào khác hả cưng
[11/2/2017, 9:30:06 PM] []: :neutral_face: Thực ra là một cô gái vừa pha cafe việt nam nóng uống vì đang đau họng :flag-vn: :coffee:
[11/2/2017, 9:30:45 PM] [huy]: :think:
[11/2/2017, 9:30:50 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: nóng thường mùi thơm hơn :smile:
[11/2/2017, 9:31:11 PM] [SFzxc]: mấu chốt là *cô gái
[11/2/2017, 9:31:12 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: còn lạnh nhiều đá như chè thì kiểu SG :smile:
[11/2/2017, 9:31:21 PM] []: cà phê sữa đá là ngon nhất
[11/2/2017, 9:31:46 PM] []: ở thái cà phê sữa đá cũng ngon
[11/2/2017, 9:32:22 PM] []: Cafe đá cũng ngon nhưng mà kiểu vừa làm việc vừa nhâm nhi thì có khi quên nó lại loãng hết. Cafe đá công viên vỉa hè cho ngày nóng bức là số dách.
[11/2/2017, 9:32:48 PM] [huy]: công thức pha cà phê của mình: 8oz cà phê vn hoặc dark roast + 3 muỗng sữa đặc + 2 muỗng Nescafe Clasico dark roast + 2 muỗng coffee matte
[11/2/2017, 9:33:07 PM] []: cà phê nóng mà làm nó cũng bị nguội còn gì :omg:
[11/2/2017, 9:33:27 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: chuẩn, uống đá bị cái là đá nhanh tan, làm 1 hồi quay qua thì nó nhạt vị roài
[11/2/2017, 9:33:58 PM] [huy]: hint: muốn đá lâu tan thì xay nhuyễn ra thành đá bào
[11/2/2017, 9:34:14 PM] [hieu.huynh]: còn tan ác dữ nữa
[11/2/2017, 9:34:18 PM] [hieu.huynh]: :think:
[11/2/2017, 9:34:40 PM] []: Cafe sữa: Một chấm sữa đặc + 2 lóng tay út cafe đen đặc + đá nhiều.
[11/2/2017, 9:35:01 PM] [hieu.huynh]: đá xay nhuyễn ra, diện tích tiếp xúc lớn, quăng vào chắc 5p là thành nước ốc ngay
[11/2/2017, 9:36:51 PM] [huy]: :oh: @thaod bạn cho tay vào để đo à :oh:
[11/2/2017, 9:36:57 PM] [huy]: =))0
[11/2/2017, 9:36:59 PM] []: Cafe đá SG là cho cafe đậm đặc thật ít, thường là 2 lóng tay thôi, rồi bỏ đá nhiều quậy lên. Sau đá tan ra một ít là vừa uống
[11/2/2017, 9:38:45 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: klq, xin giới thiệu Amarin Coffee, 80% Robustar, 20% Arabica, loại mình đang dùng 200k/kg :troll:
[11/2/2017, 9:39:05 PM] []: @snacky Rót riết thì quen chứ đâu có đo, vừa nãy giơ lên ước lượng để ghi vô cho mọi người biết là nhiu thôi :grin:
[11/2/2017, 9:39:14 PM] [hieu.huynh]: cho em sin cái địa chỉ mua nào anh @xluffy
[11/2/2017, 9:39:16 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: Robustar from Buôn Hồ, DakLak, Arabica from Lam Dong
[11/2/2017, 9:39:37 PM] [huy]: :think:
[11/2/2017, 9:39:43 PM] [huy]: ae nào ship cf sang đây cho mình đi
[11/2/2017, 9:39:50 PM] [huy]: tiền nong tính sau
[11/2/2017, 9:40:04 PM] [hieu.huynh]: <http://www.amarincoffee.com/>
[11/2/2017, 9:40:09 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: <http://www.amarincoffee.com/ban-hang/>
[11/2/2017, 9:40:09 PM] [hieu.huynh]: này hả anh Quăng?
[11/2/2017, 9:40:12 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: uh
[11/2/2017, 9:40:19 PM] [hieu.huynh]: nhìn ngon choét :beauty:
[11/2/2017, 9:41:35 PM] []: Đó giờ chỉ uống cafe bắp và đậu nành :troll: . Bữa đi Tà Nung uống được cafe mít (Cherry/Liberica) ghiền quá mà quên mua về :okay:
[11/2/2017, 9:42:46 PM] [SFzxc]: ae ra Huế em mời cafe muối nha
[11/2/2017, 9:42:49 PM] [SFzxc]: :beauty:
[11/2/2017, 9:44:23 PM] [huy]: cf muối là cf gì :neutral_face:
[11/2/2017, 9:44:26 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: hồi ra Huế, có cái cf gì mà có cái đèn cầy ở dưới, đốt cái ly
[11/2/2017, 9:44:27 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: =))
[11/2/2017, 9:44:34 PM] []: Quảng cáo giùm, bạn mình cũng có bán cafe, mời các bạn xem qua, khi mua đọc pass _bạn anh Triết_ sẽ được tăng thêm 5% giá :think:
<https://store.revocoffee.vn/>
[11/2/2017, 9:44:50 PM] [huy]: thôi giải tán
[11/2/2017, 9:45:13 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: Revo này quảng cáo miết nè, có mấy cái phin cf màu mè vàng xanh đủ kiểu
[11/2/2017, 9:45:25 PM] [SFzxc]: quà phê muối ngon lắm anh
[11/2/2017, 9:45:31 PM] [SFzxc]: uống một lần là nghiện
[11/2/2017, 10:30:19 PM] [unrealhoang]: Mình không uống được cafe, đi ra
[11/2/2017, 10:31:26 PM] [Cậu Làm Vườn]: @xluffy Revo uống được nghen, uống ké thanh niên chung nhà miết nên em biết
[11/2/2017, 10:35:41 PM] [Cậu Làm Vườn]: Thanh niên đó trước giờ toàn mua cà phê hạt đem xay, dạng hardcore, uống đâu cũng chê, nhưng mua Revo thì chịu.
[11/2/2017, 10:38:53 PM] [Cậu Làm Vườn]: Nói xong mới thấy mình giống seeder của Revo...
[11/2/2017, 10:40:40 PM] []: revo có gì đặc biệt á, lần đầu em nghe
[11/2/2017, 10:46:46 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: …
[11/2/2017, 10:47:25 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: revo thấy quảng cáo nhiều trên <http://www.ghiencaphe.com|www.ghiencaphe.com>, chắc chung à
[11/2/2017, 10:47:50 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: nó có mấy cái phin cf màu mè nhìn hay hay, cơ mà ko thích bị spam quảng cáo nên giờ vẫn uống cái Amarin
[11/2/2017, 10:51:16 PM] [Cậu Làm Vườn]: Revo là Ghiencaphe đó ạ. Bạn em mua từ thời còn là Ghiencaphe, lúc đó chưa có bao bì, thương hiệu.
[11/2/2017, 10:52:27 PM] [Cậu Làm Vườn]: Lúc bạn em bắt đầu mua là vì nó uống Arabica 100%, mà những chỗ khác nó tìm đa số là có pha Robusta
[11/2/2017, 10:53:24 PM] [huy]: @unrealhoang ko uống đc cf à
[11/2/2017, 10:53:25 PM] [huy]: vì sao
[11/2/2017, 11:06:53 PM] []: Em cũng không uống được cf, uống vào là nó nhợn nhợn khó chịu
[11/2/2017, 11:06:59 PM] []: :crying:
[11/2/2017, 11:07:14 PM] [unrealhoang]: Đúng roài
[11/2/2017, 11:07:20 PM] [unrealhoang]: :crying:
[11/2/2017, 11:14:23 PM] [huy]: Hai thanh niên kém cỏi
[11/3/2017, 2:07:00 AM] [hasagi]: mình mới uống cafe trưa nay
[11/3/2017, 2:07:06 AM] [hasagi]: giờ giống viêm họng quá
[11/3/2017, 2:09:12 AM] []: matcha ftw
[11/3/2017, 2:09:15 AM] []: :beauty:
[11/3/2017, 7:15:38 PM] []: @runi_mage M uống trúng cafe đậu nành cmnr, for sure
<@U0XMX52AE> <@U0GCK0JTW> Bị say cafe đấy. Hãy thử expresso, ít cafein hơn, thử 1 shot với đá sẽ nhẹ hơn. Cafe pha phin nặng hơn nhiều lắm.
[11/3/2017, 7:18:59 PM] []: @triet thôi em cứ matcha, trà đào :))
[11/3/2017, 7:20:09 PM] []: Thỉnh thoảng đổi gu lấy cảm hứng
[11/3/2017, 7:20:17 PM] []: easy to get high :omg:
[11/7/2017, 5:43:33 PM] [huy]: #til `xxd` command
[11/7/2017, 6:10:01 PM] []: NAME
xxd - make a hexdump or do the reverse.
[11/7/2017, 6:10:05 PM] []: :think:
[11/7/2017, 6:19:14 PM] [tucq88]: # TIL FOUC : If you're using a web font, you're bound to see a flash of unstyled text (or FOUC) , between the initial render of your websafe font and the webfont that you've chosen.
<https://meowni.ca/font-style-matcher/>
[11/7/2017, 6:58:22 PM] [huy]: Nó đó
[11/9/2017, 2:43:30 AM] [tucq88]: #til Interesting wiki <http://wiki.c2.com/?CategoryCategory>
[11/9/2017, 4:58:42 AM] [alias Trung.Le, as tle]: #til lots of filter plugins of fluentd
[11/9/2017, 4:59:10 AM] [alias Trung.Le, as tle]: and docker does support forwarding to fluentd! how nice!
[11/9/2017, 11:32:45 PM] [tucq88]: #til Only Use `tail -f` for multi files, for single - use `less`
<http://www.brianstorti.com/stop-using-tail/>
[11/10/2017, 1:30:41 AM] [dan]: #til ActiveRecord will not excute SQL to update attributes if it thinks that the update will not change anything. Workaround: reload model before update
[11/12/2017, 9:43:37 PM] [話せる森林]: #til Một câu thần thánh thường được viết trong docs cho các mục mà không biết phải viết gì.
`頻繁に行う簡単な操作はこれで可能` nghĩa là `Một thao tác đơn giản mà làm nhiều thì sẽ trở nên thuần thục`
[11/12/2017, 9:57:11 PM] [huy]: nể mấy bạn nhật
[11/12/2017, 10:02:17 PM] [話せる森林]: Phỏng theo tài liệu hướng dẫn Git của một tập đoàn rất to... :smile:
[11/12/2017, 10:03:55 PM] [huy]: muscle memory
[11/14/2017, 12:01:35 AM] [hieu.huynh]: nhỏ gọn, đẹp, có share view, coi nhiều chỗ cùng lúc
[11/14/2017, 12:02:19 AM] [hieu.huynh]: rất thuận tiện để tính toán `window time` (prepare for backup, upgrade, …. )
[11/17/2017, 1:57:43 AM] [Cậu Làm Vườn]: #til dùng `slice!(*keys)` với ActionController Paramater sẽ trả về modified instance *chứa* `keys`, thay vì trả về `removed keys` như khi dùng với `Hash`
[11/19/2017, 10:20:23 PM] [huy]: #til <https://unsplash.com/> for free photo
[11/21/2017, 3:01:26 AM] [hasagi]: #til 4 common formats phone numbers
``` E164
INTERNATIONAL
NATIONAL
RFC3966
```
[11/21/2017, 8:33:43 PM] [anh bán chuối]: #til how to make background job run slow with this setup :omg:
```
Sidekiq.configure_client do |config|
config.redis = {
url: ENV.fetch('REDIS_URL'),
size: 5
}
end
```
```
Sidekiq.configure_server do |config|
config.error_handlers &lt;&lt; proc { |ex, ctx_hash| ErrorService.error(ex, ctx_hash) }
config.options[:concurrency] = Integer(ENV.fetch('SIDEKIQ_CONCURRENCY', 40))
config.redis = {
url: ENV.fetch('REDIS_URL'),
size: Integer(ENV.fetch('SIDEKIQ_CONCURRENCY', 40)) + 5, # As default
timeout: Integer(ENV.fetch('SIDEKIQ_REDIS_TIMEOUT', 10)) # default is 10
}
config.on(:shutdown) do
puts 'Sidekiq is shutting down!!!'
end
config.on(:startup) do
ActiveRecord::Base.establish_connection
puts 'Sidekiq is ready!!!'
end
config.on(:quiet) do
puts 'Sidekiq is not accepting any more jobs!!!'
end
```
[11/21/2017, 8:38:04 PM] [anh bán chuối]: mọi người thử nhìn xem có gì đó sai sai :smile:
[11/21/2017, 8:38:57 PM] [anh bán chuối]: cc @anhduy <@U0GCK0JTW> :v
[11/21/2017, 8:39:32 PM] []: redis co 5 connection
[11/21/2017, 8:39:39 PM] []: ma co 40 cai job queue
[11/21/2017, 8:39:42 PM] []: :pac:
[11/21/2017, 8:40:56 PM] [anh bán chuối]: ` size: Integer(ENV.fetch('SIDEKIQ_CONCURRENCY', 40)) + 5, # As default` mà, nói rõ hơn coi @hieuk09 :omg:
[11/21/2017, 9:18:12 PM] [話せる森林]: Do config như trên nên nó xử lí cùng một lúc hết 40 requests xong mới tiếp tục lấy tiếp 40 requests mới vào xử lý.
[11/21/2017, 9:19:14 PM] [話せる森林]: Quên đáng ra nên tạo thread.
Dẫn đến là case có thời gian mà 1 request rất lâu còn 39 request nhanh thì nó sẽ chỉ xử lí 1 request duy nhất mà không kéo tiếp 39 request khác vào xử lý.
[11/21/2017, 9:19:17 PM] [話せる森林]: #til Github có cái git book này có khá nhiều bài viết hay ho mỗi tội là phải lọc.
<https://www.gitbook.com/explore/topic/programming>
[11/21/2017, 9:19:46 PM] [話せる森林]: Do config như trên nên nó xử lí cùng một lúc hết 40 requests xong mới tiếp tục lấy tiếp 40 requests mới vào xử lý. Dẫn đến là case có thời gian mà 1 request rất lâu còn 39 request nhanh thì nó sẽ chỉ xử lí 1 request duy nhất mà không kéo tiếp 39 request khác vào xử lý.
[11/21/2017, 9:20:59 PM] [anh bán chuối]: ko, cái nó xử lí dc 40 request cùng lúc mà :3 khá nhanh đó, chỉ có edge case mới lâu :smile:
[11/21/2017, 9:22:00 PM] [話せる森林]: Thế là lí do tại sao anh Long nhỉ?
[11/21/2017, 9:30:41 PM] [minh.nguyen]: tùy đặc tính của cái work nữa. Nếu là toàn work nặng về CPU, mà kéo 40 threads xử lý cùng lúc thì không ổn
[11/21/2017, 9:31:22 PM] [anh bán chuối]: uhm, có thấy config này sai chỗ nào ko @nguyenquangminh
[11/21/2017, 9:31:40 PM] [anh bán chuối]: work thực ra ít CPU ko ah, toàn nặng về IO/Network
[11/21/2017, 9:31:42 PM] [minh.nguyen]: mỗi thread nó giữ 1 connection, polling liên tục tới Redis :think:
[11/21/2017, 9:31:52 PM] [minh.nguyen]: thì có vẻ hơi nhiều thì phải
[11/21/2017, 9:34:53 PM] [anh bán chuối]: uhm, nhưng config đó vẫn đúng, vì maximum a có 40 thread đang chạy, mỗi thread xài 1 connection để get job và xử lý, share nhau 1 pool 45 connections
[11/21/2017, 9:35:36 PM] [anh bán chuối]: @rikimaru lát nói luôn, =))
[11/21/2017, 9:36:53 PM] [minh.nguyen]: Hỏi ngu. Web server anh xài puma phei hông
[11/21/2017, 9:37:00 PM] [minh.nguyen]: Chỗ client đẩy job
[11/21/2017, 9:38:15 PM] [anh bán chuối]: Uh a xai puma. Nhung chi co 4 threads thoi
[11/21/2017, 9:38:31 PM] [minh.nguyen]: Èo vậy không phải :face_with_rolling_eyes:
[11/21/2017, 9:43:54 PM] [manhdv]: mình nhìn sắp lé cả mắt rồi cũng ko thấy gì bất ổn cả :v
hay mắt mình lé thật rồi :)))
[11/21/2017, 9:47:32 PM] [anh bán chuối]: max-concurrency: 40
sidekiq-client: 5 connections
sidekiq-server: 45 connections
sidekiq-client: push jobs to redis
sidekiq-server: pull job from redis, and process it
=&gt; problem ở chỗ nếu mà gặp job đi enqueue job khác =&gt; acting like a redis-client.
=&gt; 40 redis-clients share a pool of 5 connections =&gt; :omg:
e.g:
```
class MyWoker
def perform
1..100.each {|i| AnotherWoker.perform_async(i) }
end
end
```
[11/21/2017, 9:50:06 PM] [manhdv]: nghĩa là `khi sk-server process job, mà trong job đó lại enqueue một job khác` à @longkt90?
[11/21/2017, 9:51:19 PM] [anh bán chuối]: uhm
[11/21/2017, 9:53:43 PM] [anh bán chuối]: đâu có, vd như muốn send mail cho followers của 1 topic đi, thì phải enqueue 1 cái để send cho topic đó, và vì muốn mọi người nhận được gần như là cùng lúc với nhau, thay vì send tuần tự thì thằng đó nó enque vd 1000 cái job khác để send cho từng người
[11/21/2017, 9:53:57 PM] [anh bán chuối]: (vd 1000 ng follow cái topic đó)
[11/21/2017, 10:00:22 PM] [manhdv]: bên mình cũng có chức năng send hàng loạt email cho nhiều users, cấu hình hơi khác một chút đó là mỗi một lệnh send email coi như là một job luôn rồi.
Có case nào khác mà cần gọi job trong job ko longkt?
[11/21/2017, 10:00:54 PM] [Cậu Làm Vườn]: Vậy hướng giải quyết là tăng connection pool của client lên ạ?
[11/21/2017, 10:13:13 PM] [anh bán chuối]: uhm vì nó là 1 pool và mỗi connection trong đó chỉ được tạo khi có nhu cầu, nên set cho bằng với concurrency + 1 cũng được :3
[11/21/2017, 10:15:34 PM] [anh bán chuối]: @manhdv cung tương tự như vd trên của mình
```
class SendAnalyticWorker
include Sidekiq::Worker
sidekiq_options retry: false
def perform(action, *args)
Analytics.call(action, *args)
end
end
```
Analytics.call nó sẽ gửi cho 1 đám service, như là GA, Kissmetric, Hubspot và Salesforce
mỗi cái đó sẽ là 1 worker riêng
[11/21/2017, 10:26:33 PM] [Cậu Làm Vườn]: #til ^
[11/21/2017, 10:53:17 PM] [minh.nguyen]: à đúng là có vụ này. Nhưng mà off topic, em nghĩ nên hạn chế tạo job mới trong khi excecute một job :thinkhard:
[11/21/2017, 10:53:50 PM] [anh bán chuối]: :thinkhard:
[11/21/2017, 10:55:16 PM] [anh bán chuối]: còn giải pháp nào khác ko ta :thinkhard:
[11/21/2017, 10:55:50 PM] [minh.nguyen]: Với lại sao phải enqueue một job khác nhỉ? Chạy trực tiếp trong job đó không được hả anh?
[11/21/2017, 10:56:22 PM] [minh.nguyen]: Còn nếu mà xử lý theo dạng data pipeline thì xài siekiq có vẻ hơi gượng ép một tí
[11/21/2017, 10:56:43 PM] [anh bán chuối]: vd mà 1000 followers đó em, gửi xong hết 1000 emails thì thằng cuối nhận hơi chậm
[11/21/2017, 11:18:18 PM] [話せる森林]: Em không làm back-end, vụ này khó hiểu quá. Tối em phải chơi con gì support súng để lấy thời gian hỏi thêm mới được.
[11/21/2017, 11:19:10 PM] []: @nguyenquangminh tai sao lai ko nen? Cai do la pattern binh thuong ma. Tham chi con co khuyen cao la moi email sender nen co worker rieng, vay nen trong job send batch email, hau nhu luon tao ra job moi de send tung email.
[11/21/2017, 11:54:50 PM] [Cậu Làm Vườn]: Note: Đã xóa câu hỏi. Sorry, em/mình hiểu sai một chút về `sidekiq` và `redis` client timemout. Mới đi đọc dạo về, đã thông.
[11/22/2017, 12:01:53 AM] [anh bán chuối]: viet 1 cai #til coi @harrisnguyen, có khi mọi ng cũng hiểu sai
[11/22/2017, 12:46:37 AM] [話せる森林]: #til Lỗi khi kết hợp pyenv và autoenv là khi vào các subfolder cũng bị load lại environment khá khó chịu là gây ra lỗi config path.
Mô tả lỗi tại: <https://github.com/kennethreitz/autoenv/issues/63>
Ngôn ngữ sử dụng python.
Môi trường phát sinh lỗi Mac OS X.
Cách fix:
1. Dùng pyenv-virtualenv
2. Config lại file `.env` như sau:
&gt; **Before**:
```
source /Users/rikimaru/.pyenv/versions/anaconda3-2.2.0/envs/project/bin/activate project_name
```
&gt; **After**:
```
# Setting place
pyenv=env_name
activatecmd=/Users/rikimaru/.pyenv/versions/anaconda3-2.2.0/envs/project/bin/activate
# Prepare current environment code
currentvenv=""
if [[ $CONDA_PREFIX != "" ]] then
# Strip out the path and just leave the env name
currentvenv="${CONDA_PREFIX##*/}"
fi
# Check activate environment
if [[ "$currentvenv" != "$pyenv" ]] then
echo "Switching to environment '$pyenv'"
source $activatecmd $pyenv
else
echo "Still in Conda environment '$pyenv'"
fi
```
[11/22/2017, 1:06:30 AM] [anh bán chuối]: #til call 3rd API mà ko có timeout là 1 tội ác, f**k the dev, f**k hubspot :neutral_face: 10% API call qua hubspot nhận dc return sau hơn 10 phút.
[11/22/2017, 2:39:09 AM] [hasagi]: :lol:
[11/23/2017, 4:41:04 PM] [話せる森林]: #til Đừng bao giờ đặt tên bảng là `CO₂` hoặc kiểu kiểu như vậy...
[11/23/2017, 5:42:19 PM] []: Viết số `2` ở trên như nào vậy anh :face_with_rolling_eyes:
[11/23/2017, 5:50:47 PM] [話せる森林]: Nó là kí tự unicode ấy. `U+2082` Còn tại sao lại viết thế là do copy paste từ docs ra... Typing thế nào anh cũng không rõ là cái bác làm db bác ấy viết ntn nữa.
[11/25/2017, 3:24:05 AM] [huy]: #til This is a valid C syntax
```
int sum(a, b) int a; int b; {
return a + b;
}
```
[11/25/2017, 4:15:45 AM] [Stephen]: #til Bỏ Disqus dùng cái này nà <https://posativ.org/isso/>
[11/26/2017, 4:22:41 AM] [dan]: #til <https://seashells.io>
[11/27/2017, 11:06:20 PM] [Anh Xe Ôm]: #til build từ libc lâu tụt quần :disappointed:
[11/27/2017, 11:06:53 PM] [huy]: :thinkhard:
[11/27/2017, 11:06:58 PM] [huy]: abuildlibcà
[11/27/2017, 11:07:04 PM] [tanlinhnd]: nếu vậy ko dùng libc nựa :trollface:
[11/27/2017, 11:07:14 PM] [huy]: thựcralibcnóviếtcủchuốibmra
[11/27/2017, 11:07:47 PM] [Anh Xe Ôm]: build sáng chờ, chém gió khắp nơi mà vẫn chưa xong :disappointed:
[11/27/2017, 11:08:52 PM] [huy]: chắclàdoỏcửngthôi
[11/27/2017, 11:11:48 PM] [SFzxc]: muốn kải kác tiếq việt à a @snacky
[11/27/2017, 11:14:22 PM] [huy]: :)))
[11/27/2017, 11:14:26 PM] [huy]: do gõ space
[11/27/2017, 11:14:29 PM] [huy]: nó sẽ chậm
[11/27/2017, 11:18:12 PM] [Anh Xe Ôm]: vkl logic :omg:
[11/27/2017, 11:18:46 PM] [SFzxc]: đề xuất này thật sáng tạo, nên apply cho nền giáo dục nước nhà :adore:
[11/27/2017, 11:19:03 PM] [tanlinhnd]: lý do :trollface:
[11/27/2017, 11:19:34 PM] [huy]: vềcơbảnthìaevẫnđọcđượcđúngko?
[11/27/2017, 11:19:42 PM] [huy]: chỉlàđọcchậmhơnbìnhthườngmộttí
[11/27/2017, 11:19:47 PM] [huy]: nhưngviếtnhanhhơnnhiều
[11/27/2017, 11:19:52 PM] [huy]: cólợichongwờiviếtlàđược
[11/28/2017, 12:01:51 AM] []: :facepalmanim:
[11/28/2017, 12:02:11 AM] []: ddúng tư tưởng dân js, viết tiện alf được, còn user xài tốn resource kệ
[11/28/2017, 12:03:09 AM] [tanlinhnd]: Tư bản giãy chết :troll:
[11/28/2017, 12:10:58 AM] [huy]: :monday:
[12/3/2017, 6:45:33 AM] [hieu.huynh]: #til speed test đến 3 con servers ở nước nào đó
- Change `Germany` thành `Singapore`…
- Change `head -n 3` thành `head -n 5` nếu muốn check đến 5 servers (recommend 3 là đủ, đỡ tốn băng thông)
```
❯❯ speedtest-cli --list | grep "Germany" | awk '{print $1}' | sed 's/.$//' | head -n 3 | while read i; do printf "\n\n" &amp;&amp; speedtest-cli --bytes --server $i; done
Retrieving <http://speedtest.net|speedtest.net> configuration...
Testing from CMC Telecom Infrastructure Company (203.205.26.231)...
Retrieving <http://speedtest.net|speedtest.net> server list...
Selecting best server based on ping...
Hosted by KABEL-TV-BINZ (Binz) [9227.08 km]: 388.804 ms
Testing download speed................................................................................
Download: 1.76 Mbyte/s
Testing upload speed................................................................................................
Upload: 1.32 Mbyte/s
Retrieving <http://speedtest.net|speedtest.net> configuration...
Testing from CMC Telecom Infrastructure Company (203.205.26.231)...
Retrieving <http://speedtest.net|speedtest.net> server list...
Selecting best server based on ping...
Hosted by Stadtwerke Finsterwalde (Finsterwalde) [9267.00 km]: 460.668 ms
Testing download speed................................................................................
Download: 1.38 Mbyte/s
Testing upload speed................................................................................................
Upload: 1.41 Mbyte/s
Retrieving <http://speedtest.net|speedtest.net> configuration...
Testing from CMC Telecom Infrastructure Company (203.205.26.231)...
Retrieving <http://speedtest.net|speedtest.net> server list...
Selecting best server based on ping...
Hosted by IPB (Berlin) [9271.88 km]: 440.142 ms
Testing download speed................................................................................
Download: 0.51 Mbyte/s
Testing upload speed................................................................................................
Upload: 1.32 Mbyte/s
```
[12/3/2017, 6:10:53 PM] [anh bán chuối]: @hieu.huynh nó chạy tuần tự mà :think: liên quan gì đến tốn băng thông :3
[12/3/2017, 6:13:34 PM] [hieu.huynh]: check 3 cái là đủ để coi average, check chi nhiều tốn băng thông &amp; thời gian
[12/3/2017, 6:21:40 PM] [anh bán chuối]: ah ok :okay:
[12/3/2017, 6:45:39 PM] [hieu.huynh]: :omg:
[12/4/2017, 3:05:03 AM] [話せる森林]: #til Muốn tìm một thư viện ngon thì search từ khóa `&lt;language name&gt; awesome`, nếu muốn học một ngôn ngữ mới thì search từ khóa `&lt;language name&gt; koans`, nếu muốn luyện để đi phỏng vấn thì có thể tìm từ khóa `&lt;language name&gt; road path` hoặc `&lt;language name&gt; bét pratice`
[12/4/2017, 3:07:39 AM] []: Bét practice
[12/4/2017, 3:09:33 AM] [話せる森林]: best chính là Unikey... T^T
[12/5/2017, 6:38:48 PM] [alias Trung.Le, as tle]: #til <http://xip.io/>
[12/5/2017, 6:38:49 PM] [alias Trung.Le, as tle]: :smile:
[12/5/2017, 10:41:28 PM] [話せる森林]: Cái này dùng ra sao hả anh? Trong trang chủ em không thấy có hướng dẫn.
[12/6/2017, 5:53:23 AM] [alias Trung.Le, as tle]: ^ nếu em test mấy cái OAuth2 trên môi trường máy local, thì nếu em không dùng các dịch vụ wildcard DNS cho cái redirect URL thì cái OAuth flow nó sẽ từ chối redirect
[12/6/2017, 5:53:53 AM] [alias Trung.Le, as tle]: nói chung anh chỉ dùng với mực đích test OAuth 2 tại thời điểm này, còn có các usecase khác, ai biết thì chime in nhé
[12/6/2017, 11:16:41 AM] []: #til Suy đoán: NodeJS - Express: API gửi response bằng cách stream data
*Dữ kiện:*
- Express `res` có thể gửi stream data bằng `res.write`.
- Mongodb native driver có support stream để xử lý, làm việc với từng queried document chứ ko cần phải chờ cả list được lấy về hết mới xử lý.
*Đoán:* Có thể code cho API sao mà quy trình query db -&gt; xử lý data -&gt; gửi response chỉ apply cho từng queried document.
*Tự hỏi:*
- API server stream response data như vậy có làm tăng nhanh hơn việc client nhận được data hay ko?
- Client làm việc với API như vậy có khó và phức tạp hơn ko?
- Code API như vậy có khó maintain và debug ko?
- Các ưu nhược điểm khác?
[12/6/2017, 4:08:10 PM] [話せる森林]: Thank anh
[12/6/2017, 6:45:01 PM] [huy]: Về bản chất, thì qúa trình response bắt đầu từ lúc `res.write` cho đến lúc `res.close`, người ta thường dùng `res.response` hoặc `res.json`, thực chất mấy hàm đó cũng là sự kết hợp của `res.header`, `res.write` và `res.close`
[12/6/2017, 6:45:46 PM] [huy]: Việc streaming chỉ nên dùng khi lượng dữ liệu cần response về lớn, hoặc chưa biết đc tại thời điểm bắt đầu response, vì một streaming response sẽ hold cái connection đó lại, khiến cho xử lý từ phía server lẫn client đều phải đợi cho đến lúc close
[12/6/2017, 6:46:50 PM] [huy]: Ví dụ đơn giản nhất là nếu làm server download file, và client cố nhận 1 file 2GB, server ko cần đọc hết 2GB data vào bộ nhớ rồi mới response + close 1 lần mà có thể streaming dần dần, đó là cái lợi từ phía server
[12/6/2017, 6:47:17 PM] [huy]: Client cungx có thể update UI khi đang nhận stream như thế để tránh bắt người dùng đợi nó truyền đc hết 2GB data từ server về client rồi mới update
[12/6/2017, 6:47:45 PM] [huy]: tóm lại nãy giờ mình nói cái gì ấy nhỉ :thinkhard:
[12/7/2017, 12:14:41 AM] [話せる森林]: #til Unicode Character 'ZERO WIDTH NO-BREAK SPACE' (U+FEFF)
Hãy cẩn thận khi build file csv từ trong excel.
[12/7/2017, 1:05:09 AM] []: ```
vì một streaming response sẽ hold cái connection đó lại, khiến cho xử lý từ phía server lẫn client đều phải đợi cho đến lúc close
```
Đoạn này đối lập với hai đoạn sau của anh viết nên em thấy rối một chút. Em nghĩ streaming dùng để response tới client nhanh hơn ngay khi bắt đầu có data trả về.
Khi đó client có thể bắt đầu thay đổi/hiển thị bằng những data vừa có được từ phía server.
Còn ở phía server thì em đồng ý là ở use case dung lượng data lớn thì dùng streaming. Và đây cũng là use case mà đa số những bài viết dùng đến.
Ý em nghĩ ra là ở những trường hợp bình thường (GET 50 items, GET item details là một object với nhiều fields), có giúp cho việc client bắt đầu nhận được dữ liệu nhanh hơn không? Như vậy thì client sẽ bắt đầu render và show kết quả nhanh hơn cho người dùng xem.
Hôm qua mới đọc thêm chút thì thấy là response streaming với json data thì sẽ là stream json string và client có vẻ là phải chờ hết string để parse và check được nó là một valid json string.
Code cũng sẽ phức tạp và hơi khó hiểu, lạ hơn so với cách làm đại trà như giờ. Cả ở backend lẫn frontend.
[12/7/2017, 1:07:08 AM] []: Cái này phải cần code thử mới biết và hiểu thêm được nên giờ em chỉ mới đọc và đoán thôi. Chưa nói được gì nhiều.
Rất cảm ơn anh đã thảo luận chung. :adore:
[12/7/2017, 9:09:43 PM] [tay vịn của anh bán chuối - cty A tìm FE]: @thaod xài cách stream được nhé, công ty cũ mình có làm
[12/7/2017, 9:09:54 PM] [tay vịn của anh bán chuối - cty A tìm FE]: server thì res.write
[12/7/2017, 9:10:06 PM] [tay vịn của anh bán chuối - cty A tìm FE]: còn client thì dùng oboe.js để lấy data hiển thị
[12/7/2017, 9:11:26 PM] [tay vịn của anh bán chuối - cty A tìm FE]: dùng stream nhanh có nhanh hơn hay không thì mình không biết, nhưng stream giúp cho client hiển thì data progressive hơn
[12/7/2017, 9:11:52 PM] [tay vịn của anh bán chuối - cty A tìm FE]: xem thêm mấy cái animation để biết rõ hơn <http://oboejs.com/>
[12/7/2017, 11:37:53 PM] []: Cảm ơn bạn
[12/9/2017, 10:32:22 PM] [giangnh]: #til ngày hôm qua mới biết là Thảo Điền Mall nó khác với Vincom Mega Mall :rofl:
[12/9/2017, 11:33:12 PM] [handcode]: `In other words: The HTML DOM is a standard for how to get, change, add, or delete HTML elements.`
[12/11/2017, 5:23:39 PM] [話せる森林]: #til Sử dụng Chrome [headless][Headless] cùng với selenium để test các chức năng của trang web. Gần giống như phương cách sử dụng AutoIt trên windows.
[Headless][<https://chromium.googlesource.com/chromium/src/+/lkgr/headless/README.md>]
[12/11/2017, 6:21:39 PM] [giangnh]: ^ ```[Headless](<https://chromium.googlesource.com/chromium/src/+/lkgr/headless/README.md>)```
[12/11/2017, 6:22:43 PM] [話せる森林]: #til Sử dụng Chrome [headless][Headless] cùng với selenium để test các chức năng của trang web. Gần giống như phương cách sử dụng AutoIt trên windows.
[Headless](<https://chromium.googlesource.com/chromium/src/+/lkgr/headless/README.md>)
[12/11/2017, 6:23:29 PM] [huy]: #til Slack is not fully markdown-supported
[12/11/2017, 6:31:00 PM] [hasagi]: example
[12/11/2017, 6:31:04 PM] [hasagi]: - giờ mới biết à
[12/11/2017, 6:31:08 PM] [hasagi]: :thinkhard:
[12/11/2017, 6:34:56 PM] [giangnh]: =))
[12/11/2017, 6:35:13 PM] [giangnh]: giowf moi biet
[12/11/2017, 6:37:56 PM] [話せる森林]: Truoc gio chung ta deu nghi sai =))
[12/12/2017, 3:19:22 AM] [manhdv]: #til `git blame /path/to/file`
[12/12/2017, 7:44:55 AM] [tay vịn của anh bán chuối - cty A tìm FE]: dùng git annotate/git blame plugin cho editor cho dễ nhìn hơn anh
[12/12/2017, 8:35:57 AM] [話せる森林]: anh @tobiwon trong #til em biết là đùa cơ mà anh để những icon kiểu :ie: thì sau các bạn không biết làm sao mà dám public <#C16AY670U|til> ?
[12/23/2017, 3:54:46 PM] [huy]: #til CSS `:target` <https://developer.mozilla.org/en-US/docs/Web/CSS/:target>
[12/26/2017, 2:10:38 AM] []: #til squiggly heredoc: <https://infinum.co/the-capsized-eight/multiline-strings-ruby-2-3-0-the-squiggly-heredoc>
[12/26/2017, 3:22:18 AM] [話せる森林]: #til dung add bua bai user vao groups `adm` hoac `root`
[1/1/2018, 7:45:00 PM] [alias Trung.Le, as tle]: giờ mới biết nó gọi là squiggly
[1/1/2018, 7:45:13 PM] [alias Trung.Le, as tle]: hồi trc cứ quên là phải tìm lại từ khoá multi-line
[1/4/2018, 5:32:21 AM] [unrealhoang]: #til `$ git config --global merge.conflictstyle diff3`
[1/4/2018, 11:22:40 PM] []: cho screenshot đi
[1/4/2018, 11:54:58 PM] [unrealhoang]: <http://psung.blogspot.jp/2011/02/reducing-merge-headaches-git-meets.html>
[1/9/2018, 12:53:25 AM] [giangnh]: bin đăng ký google cloud trial `547604` (brazil)
[1/9/2018, 12:53:56 AM] [ko luong thien]: em hỏi ngu, bin là viết tắt của từ gì vậy anh?
[1/9/2018, 12:54:31 AM] [giangnh]: <https://en.wikipedia.org/wiki/Payment_card_number> cái này nè em
[1/9/2018, 12:55:17 AM] [ko luong thien]: cám ơn a :heart:
[1/11/2018, 2:04:39 AM] [R]: tạo homepage của blog vs appengine :v
[1/11/2018, 5:39:56 PM] [R]: Theo e được biết thì vs với nghĩa đối kháng như anh nói nó cũng là slang language, chứ ko phải từ chính thống.
'vs' với nghĩa 'với' mà e nói tới nó cũng là slang.
Tùy hoàn cảnh mà có ý nghĩa khác nhau.
Vậy nên hi vọng anh ko áp đặt suy nghĩ của anh cho em.
[1/11/2018, 5:47:03 PM] [話せる森林]: Theo mình thấy thì ai cũng hiểu `vs` có tính chất so sánh. Khi bạn vào cộng đồng và sử dụng những `slang` do tự bạn định nghĩa chẳng ai hiểu thì có lẽ là nên tìm cộng đồng hiểu `slang` đó để dùng.
<https://www.google.co.jp/search?ei=uBJYWv61Fcqi8QXYyaCABg&amp;q=make+blog%27+homepage+%22vs%22+appengine&amp;oq=make+blog%27+homepage+%22vs%22+appengine&amp;gs_l=psy-ab.3..35i39k1.28394.29465.0.29686.2.2.0.0.0.0.88.157.2.2.0....0...1c.1j4.64.psy-ab..0.1.88....0.tLOFZPvkwb8>
[1/11/2018, 5:47:34 PM] [話せる森林]: Dù sao thì anh @manhdv khó tính dữ. =))
[1/11/2018, 5:54:24 PM] [R]: sao anh lại search 1 câu tiếng anh thế :trollface:
<https://goo.gl/rnuKuP>
[1/11/2018, 5:58:59 PM] [話せる森林]: Short link có dẫn đến facebook không thế. Đang ở công ty mà proxy nó hú lên thì chết không dám bấm. Cơ mà bạn dùng từ tiếng Anh thì mình phải search tiếng Anh chứ.
Thực ra cũng chỉ muốn nêu quan điểm về cách bạn phản pháo thôi chứ vừa mới vô room đã bị anh em sửa lưng vậy mình cũng hiểu cảm giác của bạn.
[1/11/2018, 8:16:48 PM] [話せる森林]: #til Làm cuộc đời đẹp hơn với Git log.
```
$ git config --global alias.l "log --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) %C(reset)%s%C(reset)' --all"
$ git config --global alias.lg "log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) %C(bold magenta)%aD (%ar)%C(reset)%C(bold yellow)%d%C(reset)%n''%C(bold red)%an%C(reset) %s%C(reset)%n' --all"
$ git config --global alias.lgs "log -p --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n''%C(bold magenta)&lt;%an&gt;%C(reset) - %C(white)%s%C(reset)%n' --all"
```
[1/15/2018, 7:21:27 PM] [ko luong thien]: #til `insertAdjacentHTML`
&gt; `insertAdjacentHTML()` parses the specified text as HTML or XML and inserts the resulting nodes into the DOM tree at a specified position.
&gt; - <https://developer.mozilla.org/en-US/docs/Web/API/Element/insertAdjacentHTML>
a little bit better than insert via `innerHTML`
[1/16/2018, 5:29:34 PM] [話せる森林]: Mình mới chuyển qua tự học Back-end nên anh em đừng cho emo :ie:
#til Tải trung bình của máy chủ cũng như phương thức kiểm tra tải này trên này. Ví dụ như máy chủ của mình hiện tại đang là 4 nhân vật lý và 8 nhân logic. Theo dõi hoạt động hàng ngày thì trung bình server có 3 core hoạt động liên tục. Worker hiện tại của Nginx là 1 thì mình có thể cấu hình lại là 6. Lí thuyết là thế nhưng chưa có kinh nghiệm (chính xác là chưa biết) cách nào để đánh giá hiệu quả của thay đổi này.
$ top
$ mpstat -P ALL
[1/16/2018, 5:58:15 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: bt để đạt hiệu suất tốt thì trong nginx ngta hay cấu hình worker bằng số core vật lý luôn em. genaral là hầu hết các trường hợp đều như vậy, nếu có thấp hơn chỉ trong th server em xài chung nhiều thứ. Với lại nginx nó có cái worker auto á, tự điều chỉnh
[1/16/2018, 6:02:39 PM] [話せる森林]: Dạ em cám ơn. Cái chỉ số này thì có cách nào để test không anh nhỉ? Em dùng benmarch thì không thâý có thay đổi gì mấy nhưng khá nhiều bài viết đều hướng dẫn config như vậy.
[1/16/2018, 6:07:43 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: vậy em bm thử như bt bằng `wrk` hay gì gì đó, trong phần log của nginx thì bật thêm field response time của request vào để so sánh, nginx phục vụ html bt thôi là đc
[1/16/2018, 6:08:04 PM] [話せる森林]: Dạ vâng anh
[1/16/2018, 6:09:41 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: <https://github.com/xluffy/nginx_config_collection/blob/master/etc/nginx/nginx.conf#L25>
[1/16/2018, 6:09:44 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: kiểu vầy
[1/16/2018, 6:18:35 PM] [huy]: de danh gia thi e cu dung nhung thong so co san cua node_exporter cua prometheus
[1/16/2018, 6:18:37 PM] [huy]: la du het
[1/16/2018, 6:18:47 PM] [huy]: cpu idle, cpu usage, load average, network in / out
[1/16/2018, 6:21:56 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: klq nhưng hồi xưa a bảo Line dùng tsdb gì cho long-term nhỉ? OpenTSDB phải ko anh?
[1/16/2018, 6:43:50 PM] [huy]: mysql
[1/16/2018, 6:43:51 PM] [huy]: :omg:
[1/16/2018, 6:43:58 PM] [huy]: gio dang move qua opentsdb ma move mai k xong
[1/16/2018, 6:43:59 PM] [huy]: nhieu van de qua
[1/16/2018, 6:45:11 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: -____- lie vậy mà hồi xưa a bảo OpenTSDB
[1/16/2018, 6:45:31 PM] [huy]: dang move ma
[1/16/2018, 10:01:42 PM] [shjnvo]: #til warning: toplevel constant X referenced by Y
<http://stem.ps/rails/2015/01/25/ruby-gotcha-toplevel-constant-referenced-by.html>
[1/16/2018, 10:14:21 PM] [ko luong thien]: #til <https://lawsofux.com>
[1/17/2018, 3:12:01 AM] []: #til Nullable columns with a UNIQUE constraint can contain multiple NULL values. The short version is that NULL represents missing information and comparing a field with missing information with another makes no sense. Just like comparing two pictures to see if they one the copy of the other without them existing in the first place.
<https://matjaz.it/tutorial-unique-constraint-on-null-values-in-postgresql/>
[1/17/2018, 7:12:22 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: <http://www.slideshare.net/QAware/chronix-as-longterm-storage-for-prometheus>
a có thử cái nghiên cứu cái này ko a Huy ơi?
[1/17/2018, 7:13:07 PM] [huy]: a chua nghe bao h, de a thu xem, thanks e
[1/17/2018, 7:29:48 PM] [Anh Xe Ôm]: #til <https://i.imgur.com/ABBvOht.jpg>
[1/17/2018, 8:12:02 PM] [Cậu Làm Vườn]: #til "the `in` operator doesn't distinguish between properties created specifically on an object and properties that the object inherited from the prototype chain"
<http://adripofjavascript.com/blog/drips/the-uses-of-in-vs-hasownproperty.html>
[1/17/2018, 8:15:02 PM] [SFzxc]: sao e ko thấy Bộ Chính Trị ở đâu ta
[1/17/2018, 8:18:36 PM] [unrealhoang]: @tobiwon ngay dưới BCHTWDCSVN kìa
[1/19/2018, 11:15:20 PM] [dan]: #til Partial index in sql
<https://www.postgresql.org/docs/8.0/static/indexes-partial.html>
[1/26/2018, 5:53:10 PM] []: #til <http://sysunconfig.net/aixtips/df_du_diff_out.txt>
[1/29/2018, 6:55:58 PM] [manhdv]: #til: `position: sticky;`
[1/29/2018, 6:57:50 PM] [ko luong thien]: #til <https://www.promisejs.org/implementing/>
[1/30/2018, 9:02:20 PM] [Anh Xe Ôm]: #til appengine charge tiền kinh khủng quá :omg:
[2/2/2018, 8:04:43 AM] [vthang]: #til A monoid is a set of things plus a rule for combining things and that rule obeys some rules
[2/2/2018, 8:25:03 AM] []: :clap:
[2/2/2018, 8:25:18 AM] []: Thiếu rồi
[2/2/2018, 8:25:28 AM] []: Cái đó là semigroup
[2/2/2018, 8:26:12 AM] [vthang]: Semigroup là sao ạ :cry:
[2/2/2018, 8:27:31 AM] []: Là cái ở trên đó
[2/2/2018, 8:27:50 AM] []: Monoid là semigroup mà có thêm mộy ràng buộc nữa
[2/2/2018, 8:27:56 AM] []: Là phải có identity
[2/2/2018, 8:28:30 AM] [vthang]: identity kiểu 0 trong phép + và 1 trong phép nhân [] trong phép ++ ạ?
[2/2/2018, 8:28:39 AM] []: Uh
[2/2/2018, 8:29:01 AM] []: Nếu ko có identity thì là semigroup
[2/2/2018, 8:29:49 AM] [vthang]: E hiểu hiểu rùi :3
[2/2/2018, 8:30:01 AM] [vthang]: E tưởng cái identity thuộc về `obeys some rules`
[2/2/2018, 8:30:16 AM] [vthang]: cái này là cái khái niệm tổng quát e xem được ở đây
[2/2/2018, 8:30:18 AM] [vthang]: <https://www.youtube.com/watch?v=ZhuHCtR3xq8&amp;>
[2/13/2018, 9:53:30 PM] [unrealhoang]: #til Ruby’s module/class name MUST be Capitalized
[2/22/2018, 12:19:16 PM] [mark]: TIL: `Model.none` returns an empty ActiveRecord relation
[2/22/2018, 12:19:26 PM] [mark]: ```
DEVELOPMENT [1] pry(main)&gt; Article.none
=&gt; []
DEVELOPMENT [2] pry(main)&gt; _.class
=&gt; Article::ActiveRecord_Relation
```
[2/22/2018, 12:21:29 PM] [mark]: Also, `parameterize` doesn’t work on non alphanumeric characters (eg slug generation)
[2/22/2018, 12:21:41 PM] [mark]: ```
DEVELOPMENT [3] pry(main)&gt; '$$$'.parameterize
=&gt; ""
```
[2/22/2018, 6:46:11 PM] [tanlinhnd]: TIL: Move files to another directory which are older than a date
`find /sourcedirectory -maxdepth 1 -mtime +365 -type f -exec mv "{}" /destination/directory/ \;`
To be on the safe side, start by just doing a ls -l instead of mv - that way you can check in advance that you’re getting exactly the files you want, before re-running it with mv, like this:
`find /sourcedirectory -maxdepth 1 -mtime +365 -type f -exec ls -l {} \;`
[2/25/2018, 8:09:15 PM] [manhdv]: #til: GmailAlias
[2/25/2018, 9:15:59 PM] [話せる森林]: Thêm thông tin anh ơi ngắn gọn quá
[2/25/2018, 9:45:14 PM] [manhdv]: Ví dụ như bạn có 1 cái mail dạng <mailto:mygmail@gmail.com|mygmail@gmail.com>, thì có thể tùy ý dùng thêm các mail <mailto:mygmail+something@gmail.com|mygmail+something@gmail.com>. Khi đó mọi mail tới <mailto:mygmail+something@gmail.com|mygmail+something@gmail.com> đều sẽ đc forward tới <mailto:mygmail@gmail.com|mygmail@gmail.com> mà ko cần setting gì cả.
<https://fieldguide.gizmodo.com/how-to-use-the-infinite-number-of-email-addresses-gmail-1609458192>
Thực ra là mình đã sai khi gọi nó là alias, mà nó chính xác chỉ là hỗ trợ filter của gmail mà thôi.
Nếu dùng cách này để đăng ký thông tin của dịch vụ nào đó thì tuyệt, vì đỡ phải lập email mới cho account mới.
[2/25/2018, 9:46:16 PM] [話せる森林]: Nếu thế người khác có đăng kí được cái `<mailto:mygmail+something@gmail.com|mygmail+something@gmail.com>` không anh nhỉ|
[2/25/2018, 9:47:14 PM] [manhdv]: cái này mình cũng chưa rõ, nhưng đoán là không, vì cái root vẫn cần là mygmail.
Lát đăng ký thử cái xem sao.
[2/25/2018, 9:47:36 PM] [話せる森林]: Chắc em cũng nghiên cứu vì em đang tập viết một cái mail server
[2/25/2018, 9:48:31 PM] [manhdv]: ko đc nhé, khi submit sẽ báo lỗi: Please use only letters (a-z), numbers, and periods.
[2/25/2018, 9:48:54 PM] [話せる森林]: Àh là phhải có dấu `+` hả anh?
[2/25/2018, 9:50:04 PM] [manhdv]: đúng rồi. Mail gốc là <mailto:abc@gmail.com|abc@gmail.com>, thì có thể dùng các alias có format <mailto:abc+something@gmail.com|abc+something@gmail.com> (dấu + là bắt buộc)
[2/25/2018, 9:50:15 PM] [話せる森林]: Thank anh :smile:
[2/25/2018, 9:50:55 PM] [manhdv]: đây có vẻ ko phải là chuẩn chung của mail, mà chỉ là tiện ích mà gmail cung cấp để hỗ trợ filter thôi.
[2/25/2018, 9:52:53 PM] [話せる森林]: Em đang làm một cái server dạng redirect. Kiểu em có domain <http://www.xxx.com|www.xxx.com> chẳng hạn. Em dựng 1 mail server dạng proxy khi có mail gửi đến <mailto:abc@xxx.com|abc@xxx.com> thì sẽ forward đến mail server Google tương ứng. Và ngược lại từ Google sẽ đẩy đến mail server của em xong server của em sẽ gửi mail tương ứng.
[2/25/2018, 9:56:27 PM] [anh bán chuối]: @manhdv còn 1 cái nữa là:
<mailto:manh.dv@gmail.com|manh.dv@gmail.com> cũng sẽ deliver tới <mailto:manhdv@gmail.com|manhdv@gmail.com>
[2/25/2018, 9:57:48 PM] [manhdv]: a dung roi, link ben tren cung co nhac toi chi tiet do. va khi dang ky gmail thi no cung check dieu kien nay.
[2/26/2018, 1:55:05 AM] [toanha]: có thể dùng dấu `.` cũng tương tự, dđặt dấu `.` ở bất kì vị trí nào trong cái email
[2/26/2018, 1:55:21 AM] [toanha]: nó cũng đều trả về 1 email
[2/26/2018, 11:23:22 PM] [huy]: #til: [Rust] You can replace the dependencies of any dependency with `[replace]` (<https://doc.rust-lang.org/cargo/reference/manifest.html#the-replace-section>)
[3/8/2018, 6:17:12 PM] [話せる森林]: #til
[3/8/2018, 6:17:15 PM] [話せる森林]: <https://docs.python.org/3/howto/index.html>
[3/10/2018, 9:32:21 PM] [phat]: <https://gist.github.com/Kartones/dd3ff5ec5ea238d4c546>
```Query analysis:
EXPLAIN __query__: see the query plan for the given query
EXPLAIN ANALYZE __query__: see and execute the query plan for the given query
ANALYZE [__table__]: collect statistics
```
[3/13/2018, 4:14:27 AM] []: Bình thường khi muốn load file, source code, hay gì gì đó từ server về máy local của mình thì thường có phải ae phải tìm được public folder được setup bởi nginx hoặc apache để bỏ file vào đó, rồi sau đó vào <http://ip-vps/public-folder> để download về đúng không?
Có cách này theo mình thấy ngon hơn và dễ hơn nhiều. Đó là mình upload file lên Google Drive, rồi từ Google Drive load file đó về, cái ngon là chả cần quan tâm có hay không có nginx, apache, mặt khác tốc độ thì nhanh phi thường, vì VPS tốc dộ download/upload cực kì cao, google drive thì có proxy server quanh VN nên cứ phải nói là max speed, hehe
Source:
```<http://olivermarshall.net/how-to-upload-a-file-to-google-drive-from-the-command-line/>
```
[3/13/2018, 4:39:47 AM] [vthang]: #til check package version: `apt-cache policy &lt;package-name&gt;`
install a specific package version: `sudo apt-get install package=version`
[3/14/2018, 5:37:59 AM] [manhdv]: #til bác manhdung ơi đăng đàn trở lại đi
<https://kipalog.com/posts/Tim-hieu-RabbitMQ---Phan-2>
[3/14/2018, 5:38:29 AM] [SFzxc]: bác @manhdv cũng đang tìm hiểu rabbit à
[3/14/2018, 5:38:48 AM] [SFzxc]: e cũng đang tìm hiểu có gì cùng trao đổi
[3/14/2018, 5:39:55 AM] [manhdv]: Không bạn. Bên mình dùng kafka và sqs thôi. Nhưng đọc các bài của bác manhdung này thấy hấp dẫn quá, mà lâu không thấy viết bài :|
[3/14/2018, 5:41:12 AM] [SFzxc]: :smile: thế chắc vài bữa làm xong cố gắng viết vài mới bài rabbitmq mới được :smile:
[3/14/2018, 5:42:19 AM] [manhdv]: Tham khảo rocketMQ nữa xem sao :D
Nếu bạn có thể viết bài so sánh ưu nhược của 3 thằng này thì thật tuyệt :D
[3/14/2018, 5:44:45 AM] [SFzxc]: thấy hardcore nhất chắc là thằng Zeromq đó bác =))
[3/14/2018, 6:42:38 PM] [話せる森林]: #til NOTE: On the JVM, if all of the parameters of the primary constructor have default values, the compiler will generate an
additional parameterless constructor which will use the default values. This makes it easier to use Kotlin with libraries such
as Jackson or JPA that create class instances through parameterless constructors.
[3/14/2018, 11:54:07 PM] [namnn]: @tobiwon sao lại thế =))
[3/15/2018, 12:02:34 AM] [SFzxc]: @namnn là nó chỉ là middleware cho socket API thôi, ko có queue, topic… gì cả, mình phải build từ Zero theo đúng nghĩa đen :v
[3/15/2018, 12:03:09 AM] [namnn]: zeroMq lại ko có queue là sao
[3/15/2018, 12:03:16 AM] [namnn]: ko có topic thì đúng thật
[3/15/2018, 12:07:49 AM] [SFzxc]: thế chắc là mình nhầm, đều nhu cầu của mình chắc ko cần custom sâu đến như thế :byebye:
[3/15/2018, 12:08:24 AM] [SFzxc]: mà @namnn đang chiến zero à, viết vài bài kipalog cho ae học hỏi với :beauty:
[3/15/2018, 12:09:31 AM] [namnn]: cũng chỉ dùng thôi mà =)) thấy cái nào phù hợp thì dùng thôi chứ có gì đâu
[3/15/2018, 3:11:48 AM] [imah]: @rikimaru: can you help to explain what note above means?
does it mean that, if we used Kotlin with libraries such as Jackson, then should always set default value for input parameters?
such as
`class Customer(val customerName: String = "")`
over
`class Customer(val customerName: String)`
?
[3/15/2018, 5:38:27 PM] [話せる森林]: Hi, @nezneika.
The Jackson Project, formerly known as the standard JSON library for Java (or JVM platform in general) using reflection technique for generate class’s instance. Therefore you should define the public non-parameter constructor. (More information here: <https://stackoverflow.com/questions/27571380/jackson-prefers-private-constructor-over-jsoncreator-when-deserializing-a-class>)
So, if you want to use the `model class` at another and have to input some parameters, you have to do something like that.
```
class Customer {
private String customerName = "Default";
public Customer() {}
public Customer(final String customerName) {
this.customerName = customerName;
}
}
```
In Kotlin
```
class Customer(val customerName: String = "") {}
```
[3/16/2018, 2:06:29 AM] [imah]: @rikimaru Thanks for explanation and reference.
At least I understood the `public non-parameter constructor` of Jackson.
:smile:
[3/18/2018, 11:45:55 PM] [alias Trung.Le, as tle]: #til AWS ECS Scheduled Task. now I could replace my custom scheduler :smile:
[3/19/2018, 6:21:38 PM] [manhdv]: #til Blog hay và sâu
<http://engineering.appfolio.com/>
[3/26/2018, 9:36:39 PM] [dan]: #til sql sequences and nextval
[3/27/2018, 7:43:03 PM] [alias Trung.Le, as tle]: #til pyenv and pipenv to get local env up running with Python easily
[3/27/2018, 8:04:03 PM] [話せる森林]: Có một cái đó là nếu đã dùng `pyenv` thì không nên dùng `virtualenv` nữa nha anh. Nó có cái pyenv-virtualenv để dùng pyenv nhưng tận dụng vài cái của `virtualenv` cá nhân em dùng rất chán. Mình thay bằng docker sẽ ổn hơn.
[3/28/2018, 2:30:26 AM] [Anh Xe Ôm]: Mình thì có thói quen xài virtualenvwrapper
```
$ mkvirtualenv abc
$ setvirtualenvproject
$ workon abc
$ lsvirtualenv
...
```
[3/28/2018, 9:17:07 PM] [Anh Xe Ôm]: #til mấy người tên Jay thường học cao, chức khủng :oh:
[3/28/2018, 9:28:23 PM] []: Jay Chou :hopeful:
[3/28/2018, 9:28:59 PM] [hasagi]: @jtuthehien
[3/28/2018, 11:28:30 PM] []: #til Một số threats thường gặp và cách review để nhận biết :thinkhard:
<https://www.owasp.org/index.php/Category:OWASP_Code_Review_Project>
[3/28/2018, 11:58:43 PM] [SFzxc]: #til gpg git-crypt
[3/29/2018, 1:18:39 AM] [hasagi]: usecase của cái này là gì ta
[3/29/2018, 1:18:42 AM] [hasagi]: :think:
[3/29/2018, 1:18:52 AM] [hasagi]: share 1 cái repo và vừa có code public/private à
[3/29/2018, 1:50:23 AM] [SFzxc]: project hiện tại đang thì dùng để mã hoá mấy cái gcloud credentials, với config k8s á @runi_mage, cứ push encrypted data lên github, ai có prkey thì cứ pull về unlock để xem
[4/2/2018, 1:19:20 PM] [mark]: #til `1.1` expands to `1.0.0.1`. useful for `127.1` =&gt; `127.0.0.1`.
```
~ ping 1.1
PING 1.1 (1.0.0.1): 56 data bytes
64 bytes from 1.0.0.1: icmp_seq=0 ttl=56 time=184.591 ms
64 bytes from 1.0.0.1: icmp_seq=1 ttl=56 time=188.755 ms
64 bytes from 1.0.0.1: icmp_seq=2 ttl=56 time=185.938 ms
```
[4/3/2018, 4:40:30 PM] [huy]: #til `String.prototype.padStart` `String.prototype.padEnd` without `leftpad` :roflrofl:
[4/4/2018, 6:45:49 PM] [manhdv]: nếu (nhà nghèo &amp;&amp; phải hàn răng ở Nhật) thì khi đắp răng nên chọn nguyên liệu là kim loại, ko nên chọn sứ, vì răng kim loại đc bảo hiểm chi trả, còn sứ thì ko. Tiền một chiếc răng đc hàn bằng nguyên liệu sứ đủ để mua 1 vé 2 chiều về VN, hàn xong rồi quay lại Nhật :neutral_face:
[4/4/2018, 6:59:45 PM] [話せる森林]: Ô til hay quá em phải up facebook mới được.
[4/5/2018, 3:11:45 AM] [toanha]: #til mới biết trong javascript có hàm `toFixed`
[4/5/2018, 8:11:39 AM] []: #til RealWorld repo
&gt; See how the exact same <http://Medium.com|Medium.com> clone (called Conduit) is built using any of our supported frontends and backends.
<https://github.com/gothinkster/realworld>
[4/5/2018, 10:22:37 PM] [alias Trung.Le, as tle]: #til `foreman` prefix-message format, the regex for that is
<https://gist.github.com/joneslee85/ed2fbe7bb0e7c9b170b9b170665cbe81>
useful for someone who do ops that need to parse this log message
[4/6/2018, 2:05:09 AM] [dan]: ^ ++ đc ưu tiên hơn -- à
[4/6/2018, 2:23:16 AM] []: <https://github.com/elixir-lang/elixir/blob/master/lib/elixir/pages/Operators.md>
Associativity of `++` `--` `..` `&lt;&gt;` is right to left
[4/6/2018, 2:23:26 AM] []: giờ mới biết
[4/6/2018, 4:46:36 AM] [vthang]: Vâng ạ :raising_hand:
[4/6/2018, 8:15:03 AM] [giangnh]: ngôn ngữ có cao siêu đến đâu đi nữa, cách này làm tốt đến mức nào đi nữa, vân vân thì cũng không có gì quan trọng bằng có sức khỏe, có sức khỏe tốt thì làm gì cũng được, có thể chúng ta đã bỏ sự quan tâm của mình với sức khỏe, bởi có sức khỏe thì mới thành công. Hãy giảm thức khuya lại (thức khuya là nguyên nhân chủ yếu dẫn đến các bệnh về dạ dày) có thể sẽ rất khó với một số bạn, những hãy giảm nó, đừng để sau này mình dùng tiền mình kiếm được lại đi trị bênh, hãy giành 1 ngày để đi khám sức khỏe tổng quát để biết mình đang ở đâu, quan trọng hơn là phải thể dục thường xuyên, 1 ngày cứ 20p, 1 tuần là là được 140p đủ tiêu chuẩn của WHO.
[4/6/2018, 8:17:44 AM] [vthang]: Em bị ốm gần tháng nay rồi
[4/6/2018, 5:49:46 PM] []: AFIAK thif nguyên nhân về bệnh dạ dày đâu phải do thức khuya, chủ yếu là do ăn uống không hợp lý, căng thẳng thần kinh, sử dụng nhiều chất kích thích và do vi khuẩn thôi :think:
[4/7/2018, 10:20:35 PM] [Anh Xe Ôm]: #til spotify trên TV không cần premium vẫn chọn bài được???
[4/8/2018, 8:39:15 AM] [話せる森林]: Trên máy tính cũng vậy đó anh. Web nữa.
[4/8/2018, 6:05:34 PM] [話せる森林]: Thức khuya cũng ảnh hưởng dạ dày đó @triet vì theo lí thuyết anh biết thì tầm 2 3 giờ sáng là lúc dạ dày tái tạo lại lớp niêm mạc nên cơ thể khi được ngủ sẽ kièm chế sự phát sinh Axit trong thời điểm này. Thay vào đó nước dãi sẽ tiết ra nhiều hơn để chống lại các phản ứng sinh hoá gì gì đó anh coi tivi lâu qua rồi không nhớ. Thức đêm nhiều sẽ cản trở quá trình này gây đau dạ dày.
[4/8/2018, 6:08:36 PM] []: Không hề có, anh nhớ nhầm rồi, về mấy cái thời điểm phục hồi cơ thể ban đêm nếu anh cần tham khảo
<http://kenh14.vn/chuyen-gia-len-tieng-bao-dong-ve-thoi-quen-thuc-khuya-cua-gioi-tre-viet-nam-20170530174904556.chn>
[4/8/2018, 6:09:30 PM] [話せる森林]: Để anh check lại xem. Đang ở công ty không vào được Kênh 14.
[4/9/2018, 3:05:36 AM] [toanha]: #til cách sử dụng flex <https://medium.freecodecamp.org/understanding-flexbox-everything-you-need-to-know-b4013d4dc9af> :thinkhard:
[4/9/2018, 11:05:55 PM] [SFzxc]: #til Linux #cut command
My note <https://kipalog.com/posts/How-to-become-a-lazy-dev-with-Linux-cut-command>
[4/9/2018, 11:08:57 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: anh lại rất ít khi xài `cut` :))) toàn xài `awk`, tương tự như của em
[4/9/2018, 11:09:19 PM] [SFzxc]: :joy:
[4/9/2018, 11:09:28 PM] [話せる森林]: Dùng cut sẽ nhanh hơn chỉ dùng grep với regex gấp 8 lần.
[4/9/2018, 11:09:57 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: btw, nếu dùng `awk` có thể vừa `cut` và vừa `grep` đc
[4/9/2018, 11:11:40 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: thí dụ `tail xxx.log | grep 'ahihi' | cut -c2` có thể thành `tail xxx.log | awk '/ahihi/ {print $2}`
[4/9/2018, 11:13:12 PM] [SFzxc]: có vẻ ngắn hơn mà em thấy lười khi bấm mấy cái dấu ngoặc, tại ví phải ấn tới 2 phím =]]
[4/9/2018, 11:38:52 PM] [hasagi]: `kubectl logs -f $(kubectl get pods | awk '/identity/ {print $1;exit}')`
[4/9/2018, 11:38:56 PM] [hasagi]: em hay dùng awk như này
[4/9/2018, 11:39:24 PM] [hasagi]: gõ cho nhanh
[4/11/2018, 12:22:00 AM] []: #til Emacs jump to previous position : <http://ergoemacs.org/emacs/emacs_jump_to_previous_position.html>
Move Cursor to Previous Mark in Current Buffer : `Ctrl + u Ctrl + space`
[4/11/2018, 12:25:20 AM] [tanlinhnd]: có đồng râm emacs nè @snacky :adore:
[4/11/2018, 12:26:37 AM] [huy]: @haond chơi cứng quá
[4/11/2018, 12:26:42 AM] [huy]: xài emacs key binding
[4/11/2018, 12:26:45 AM] [huy]: chứ ko xài evil mode à
[4/11/2018, 12:26:56 AM] [tanlinhnd]: hãy xài spacemacs :adore:
[4/11/2018, 12:27:17 AM] [tanlinhnd]: và đọc bài viết này của `bạn` mềnh :adore:
[4/11/2018, 12:27:29 AM] [tanlinhnd]: <https://goo.gl/PQ4wjE>
[4/11/2018, 12:27:30 AM] [huy]: ^
[4/11/2018, 12:27:32 AM] [tanlinhnd]: :adore:
[4/11/2018, 12:29:49 AM] []: :adore:
[4/11/2018, 12:43:38 AM] []: E đã xem bài trên của bác. :smile: trước giờ chưa có dùng evil mode. Tối về có cái để vọc :v
[4/11/2018, 8:44:26 AM] []: Với mode này cảm giác dùng vi trên emacs cũng phê :smile:
[4/11/2018, 5:43:27 PM] [話せる森林]: #til #todayquote
&gt; I think the lack of reusability comes in object-oriented languages, not functional languages. Because the problem with object-oriented languages is they’ve got all this implicit environment that they carry around with them. *You wanted a banana but what you got was a gorilla holding the banana and the entire jungle*.
[4/11/2018, 11:03:03 PM] [dan]: #til `view -`
[4/11/2018, 11:13:54 PM] [unrealhoang]: @tanlinhnd bài hay, duy có 1 chỗ kêu helm là brain của emacs mình hơi khó chịu tí
[4/11/2018, 11:13:55 PM] [unrealhoang]: :))
[4/11/2018, 11:14:51 PM] [tanlinhnd]: ý e làm spacemacs mà a :disappointed:
[4/11/2018, 11:14:57 PM] [tanlinhnd]: emacs thì ko dám :trollface:
[4/17/2018, 6:55:56 PM] [unrealhoang]: #til JavaScript là của Oracle :scream:
[4/17/2018, 7:00:53 PM] [話せる森林]: Thông tin ở đâu thế Hoàng?
[4/17/2018, 7:02:37 PM] [unrealhoang]: <https://softwareengineering.stackexchange.com/questions/135905/legal-ramifications-of-use-of-the-javascript-trademark>
[4/17/2018, 7:03:11 PM] [話せる森林]: :33:
[4/17/2018, 7:14:37 PM] [sondnm]: <http://tsdr.uspto.gov/#caseNumber=75026640&amp;caseType=SERIAL_NO&amp;searchType=statusSearch>
[4/18/2018, 10:07:35 PM] [alias Trung.Le, as tle]: lol
[4/18/2018, 10:07:46 PM] [alias Trung.Le, as tle]: shall we use ECMAScript from now on?
[4/18/2018, 10:07:57 PM] [alias Trung.Le, as tle]: @snacky could you please rename #javascript to #ecmascript?
[4/18/2018, 10:08:58 PM] [alias Trung.Le, as tle]: i am a bit fed up with the number of HR emails that could not tell the differences between JS and Java
[4/18/2018, 10:09:56 PM] [huy]: you got my vote
[4/18/2018, 10:09:57 PM] [huy]: :joy:
[4/20/2018, 12:45:13 AM] [SFzxc]: #til Postgres advisory locks `pg_advisory_lock` <https://www.postgresql.org/docs/9.4/static/explicit-locking.html>
[4/20/2018, 12:45:30 AM] [SFzxc]: <https://github.com/heroku/pg_lock>
[4/30/2018, 1:47:16 AM] [huy]: #til You can "buy" yourself a unicode character <https://unicode.org/consortium/adopt-a-character.html>
[4/30/2018, 1:50:06 AM] [Anh Xe Ôm]: :33:
[5/1/2018, 10:34:35 PM] []: #til `&amp;&amp;` has higher precedence than `||`
[5/2/2018, 1:10:40 AM] [Anh Xe Ôm]: #old #story hãy cẩn thận trước khi dùng bất cứ thứ gì binding từ C/C++, vì nó có thể thiếu một dòng comment thần thánh nào đó:
<https://godoc.org/github.com/ceph/go-ceph/rados#IOContext.SetXattr>
<http://docs.ceph.com/docs/master/rados/api/librados/?highlight=rados_getxattr>
```
Extended attributes are stored as extended attributes on the files representing an object on the OSDs. Thus, they have the same limitations as the underlying filesystem. On ext4, this means that the total data stored in xattrs cannot exceed 4KB.
```
[5/3/2018, 8:55:00 PM] [huy]: Máy cá nhân thì lên rồi. Máy cty sao lên. :yaomin:
[5/3/2018, 9:00:52 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: `pacman -Syu --no-confỉm` :notbad:
[5/3/2018, 9:01:08 PM] [huy]: :notbad:
[5/3/2018, 9:01:23 PM] [huy]: Cronjob luôn
[5/3/2018, 9:01:42 PM] []: :omg:
[5/3/2018, 9:01:47 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: khá cứng đấy :notbad:
[5/3/2018, 9:01:58 PM] []: anh @xluffy dùng aur helper nào anh
[5/3/2018, 9:02:04 PM] []: hay chơi tay luôn
[5/3/2018, 9:02:44 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: bỏ arch lâu rồi =))))))))))
[5/3/2018, 9:02:53 PM] []: :facepalmanim:
[5/3/2018, 9:02:58 PM] []: chứ giờ anh xài gì
[5/3/2018, 9:03:01 PM] [huy]: Giờ xài ubuntu à
[5/3/2018, 9:03:06 PM] []: mà lúc anh còn xài arch thì anh xài cái gì
[5/3/2018, 9:03:08 PM] [huy]: Buồn quá
[5/3/2018, 9:03:20 PM] [huy]: Aur helper là csis gì
[5/3/2018, 9:03:23 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: hồi xưa thì toàn tải PKGBUILD về `makepkg -sci` thì phải
[5/3/2018, 9:03:25 PM] [huy]: Yaourt à
[5/3/2018, 9:03:39 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: yaourt lúc đầu có xài, nhưng sau thì chơi kiểu kia
[5/3/2018, 9:03:45 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: giờ đội macos =)))
[5/3/2018, 9:03:49 PM] [huy]: Why
[5/3/2018, 9:04:40 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: cty cấp
[5/3/2018, 9:06:26 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: nói chứ vẫn ngại vụ chai bin của linux
[5/3/2018, 9:06:44 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: xài cái máy của mình, cài linux đc 2-3 năm bin nó chai, hư cmnl, buồn
[5/3/2018, 9:07:13 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: nếu cty cấp máy dòng khác thì sẽ cài linux, có chai bin cũng ko có tiếc
[5/3/2018, 9:07:18 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: còn máy mình thì ... :v
[5/3/2018, 9:09:41 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: klq là con này đẹp quá <http://thinkpro.vn/danh-gia/dell-latitude-7390-chiec-laptop-13-inch-the-he-moi-cua-dell-nd497860.html>
[5/3/2018, 9:09:50 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: màn hình cũng đẹp, cài linux ngon lun
[5/3/2018, 9:10:15 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: bàn phím nhìn cũng ngon nữa
[5/3/2018, 9:10:43 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: màn hình sát cạnh, nhìn đẹp qá
[5/3/2018, 9:10:51 PM] []: thinkpad cơ
[5/3/2018, 9:11:17 PM] []: mà máy nào 2-3 năm pin ko chai anh
[5/3/2018, 9:12:07 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: del latitude cũng ngon mà, bạn a mới mua con x1
[5/3/2018, 9:12:35 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: vụ bin chai là cảm giác thôi, kiểu xe máy của mình xước vết nhỏ cũng nhìn ra =))) nhưng của người khác thì ko thèm để ý
[5/3/2018, 9:13:28 PM] []: ặc
[5/3/2018, 9:14:12 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: nó mua t450s, xong đổi lại x1 carbon
[5/3/2018, 9:16:51 PM] [huy]: x1 à :thinkhard:
[5/3/2018, 9:22:44 PM] []: giờ chỉ còn t480 là con thinkpad thật sự cuối cùng
[5/3/2018, 9:22:50 PM] []: x480 như s*** rồi
[5/3/2018, 9:56:52 PM] [hieu.huynh]: fanboi mác ô ếch
[5/3/2018, 9:57:02 PM] [hieu.huynh]: đã từ bỏ think bát từ lâu :byeanim:
[5/3/2018, 9:57:10 PM] [hieu.huynh]: mác ô ếch i king
[5/3/2018, 9:58:09 PM] [hieu.huynh]: Latitude 7390 nhìn đẹp, confirm anh @xluffy
[5/3/2018, 9:58:15 PM] [hieu.huynh]: có tiền chắc cũng mua 1 con, cài gentoo
[5/3/2018, 9:58:18 PM] [hieu.huynh]: :troll:
[5/3/2018, 10:08:42 PM] []: Mac thì chuối ko tả đc rồi
[5/3/2018, 10:38:07 PM] [anh bán chuối]: cây viết cũng đẹp :3
[5/3/2018, 11:30:59 PM] [hieu.huynh]: Dell Latitude 7480 i5-7300U RAM 8GB SSD 256GB
22.990.000 ₫
ngang con macbook 13" cấu hình thấp nhất, 2nd
[5/3/2018, 11:31:01 PM] [hieu.huynh]: cũng dc :smile:
[5/4/2018, 12:00:19 AM] [huynh.cam]: phải công nhận là bản update mới này của MacOS là thảm họa
[5/4/2018, 12:04:32 AM] [huy]: công nhận
[5/4/2018, 12:04:35 AM] [huy]: lỗi lên lỗi xuống
[5/4/2018, 12:04:36 AM] [huy]: chán vãi
[5/4/2018, 12:04:44 AM] [huy]: performance nữa chớ
[5/4/2018, 12:06:34 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: ... 1 cái til mà mấy chục cái replies
[5/4/2018, 12:07:13 AM] [huy]: chắc til gây tranh cãi quá
[5/6/2018, 9:55:01 PM] [hieu.huynh]: *TIL*: RDS nó cho mình cấu hình `root account` (khi init RDS instance)
nhưng root này là root hư cấu :troll: for sure, ahihi
[5/8/2018, 2:26:41 AM] [dxhuy87]: TIL: protect password with hash+salt+pepper
<https://lyness.io/salt-pepper-and-rainbows-storing-passwords-properly>
[5/8/2018, 2:27:50 AM] [huynh.cam]: @huydx anh em thất lạc của anh đây à? :troll:
[5/8/2018, 2:28:32 AM] [huy]: anh trai..
[5/8/2018, 2:31:36 AM] [dxhuy87]: em trai :rolling_on_the_floor_laughing:
[5/8/2018, 2:31:45 AM] [dxhuy87]: ...
[5/13/2018, 6:20:38 PM] [Anh Xe Ôm]: #til Tấm thảm để trước cửa nhà tắm ngoài chùi chân còn để chống té. Mới sáng sớm té sml.
[5/13/2018, 6:25:18 PM] [huy]: Thường là té vì nó chớ :think:
[5/13/2018, 6:32:19 PM] []: :))
[5/13/2018, 10:10:40 PM] [huynh.cam]: @snacky vậy là mua sai thảm rồi đó
[5/13/2018, 10:15:12 PM] [huy]: &gt; "Ok, that sounds fair. I totally understand that it's your expertision. But how am I supposed to figure out what is the right thảm to mua?"
[5/13/2018, 10:18:35 PM] [huynh.cam]: <http://ikea.com|ikea.com> is where you should go
[5/13/2018, 10:19:28 PM] [huy]: are you getting paid by doing that?
[5/13/2018, 10:19:40 PM] [huynh.cam]: Có khi nào huy dùng áo thun cũ để làm giẻ dậm chân ko
[5/13/2018, 10:19:48 PM] [huynh.cam]: Vậy thì té sml là đúng ròii
[5/13/2018, 10:20:02 PM] [huy]: :thinkhard:
[5/13/2018, 10:20:16 PM] [huy]: a có lắp camera ơr đâu ko rứa :oh:
[5/13/2018, 10:21:21 PM] [huynh.cam]: Thảm ikea bán có 2 đồng mĩ kim à, mua thảm đê
[5/13/2018, 10:22:14 PM] [huy]: :thinkhard:
[5/15/2018, 3:23:41 AM] [42]: #til Trong `pry`, có thể chạy terminal command bằng cách thêm `.` ở đằng trước. Ví dụ: `.ls`
[5/15/2018, 11:30:42 PM] [minh.nguyen]: #til <https://http2.github.io/http2-spec>
[5/17/2018, 8:44:37 PM] [hasagi]: #til Teardown ports `lsof -i :5003 -i :5001 | awk '{print $2}' | grep -v "PID" | xargs kill -9`
[5/17/2018, 8:48:42 PM] []: ^rất mạnh mẽ, kill thẳng -9 luôn
[5/17/2018, 8:50:25 PM] [hasagi]: :alien:
[5/17/2018, 8:51:22 PM] [hasagi]: mạnh chứ, đúng nghĩa kill mà :troll:
[5/17/2018, 8:54:38 PM] []: Trước khi kill -9 nên double check xem cái gì sắp bị thịt, list name ra trước, kinh nghiệm xương máu :think:
[5/17/2018, 9:01:11 PM] [hasagi]: này tear down để test integration thôi mà
[5/17/2018, 9:01:12 PM] [hasagi]: :think:
[5/17/2018, 9:01:24 PM] [hasagi]: chia sẻ kn xương máu xem @triet
[5/17/2018, 9:04:50 PM] []: thì kill nhầm service thôi chứ có gì đâu
[5/17/2018, 9:04:58 PM] [hasagi]: fine
[5/17/2018, 9:05:17 PM] []: down service, một nùi thằng khác chết theo
[5/17/2018, 9:07:56 PM] [unrealhoang]: sao không có cách khác take down service properly hơn
[5/17/2018, 9:07:58 PM] [unrealhoang]: :think:
[5/17/2018, 9:09:14 PM] [unrealhoang]: i.e. keep services’ pid when started, and don’t have to rely on finding pids through port?
[5/17/2018, 9:10:56 PM] []: Có, nhưng @runi_mage thích mạnh :think:
[5/17/2018, 9:11:12 PM] [unrealhoang]: à vậy à
[5/17/2018, 9:11:17 PM] [hasagi]: :think:
[5/17/2018, 9:11:18 PM] [unrealhoang]: :thinkmid:
[5/17/2018, 9:11:41 PM] [unrealhoang]: thế @triet có mạnh không sao <@U0K9M8WTZ> cũng thích
[5/17/2018, 9:11:44 PM] [unrealhoang]: :kappa:
[5/17/2018, 9:11:56 PM] [hasagi]: e chỉ đang viết 1 flow integration test cần dựng service ở local thôi
[5/17/2018, 9:11:58 PM] [hasagi]: :think:
[5/17/2018, 9:12:21 PM] [unrealhoang]: thì ý là lúc start service
[5/17/2018, 9:12:23 PM] [hasagi]: set up/ tear down part
[5/17/2018, 9:12:24 PM] [unrealhoang]: giữ pid của nó lại
[5/17/2018, 9:12:26 PM] [unrealhoang]: :neutral_face:
[5/17/2018, 9:12:30 PM] [hasagi]: thì ý là cái port đó
[5/17/2018, 9:12:41 PM] [hasagi]: nó random + locally mà
[5/17/2018, 9:12:44 PM] [hasagi]: :pac:
[5/17/2018, 9:12:49 PM] [hasagi]: cũng có chết ai đâu
[5/17/2018, 9:13:06 PM] [hasagi]: anyway
[5/17/2018, 9:13:22 PM] [hasagi]: keeping pid is good
[5/17/2018, 9:13:34 PM] [hasagi]: will xài nó trong future gần
[5/17/2018, 9:15:03 PM] [hasagi]: ủa mà ví dụ, e cho services chạy background hết bằng bash
[5/17/2018, 9:15:06 PM] [hasagi]: :thinking_face:
[5/17/2018, 9:15:33 PM] [hasagi]: thì dùng signal để kill tụi nó trong lần tới được
[5/17/2018, 9:15:50 PM] [hasagi]: vì lần tới sẽ phải chạy 1 instance bash mới
[5/17/2018, 9:16:04 PM] [hasagi]: đâu biết pid lần trước ở đâu đâu :think: , phải scan port
[5/17/2018, 9:16:36 PM] [unrealhoang]: service1&amp; &gt; service1.pid
[5/17/2018, 9:16:37 PM] []: Thì sau khi start xong, nó sẽ trả về cho cái PID (không trả thì đòi nó cho bằng được) rồi save xuống file
[5/17/2018, 9:16:54 PM] [hasagi]: lấy pid thì dễ rồi
[5/17/2018, 9:17:17 PM] [hasagi]: phải lưu pid đó ở đâu đó :pac:
[5/17/2018, 9:17:27 PM] [unrealhoang]: file?
[5/17/2018, 9:17:28 PM] []: ./.pids
[5/17/2018, 9:17:36 PM] [hasagi]: ừa thì lưu ở file đó
[5/17/2018, 9:17:49 PM] [hasagi]: nhưng mà test thì ko cần
[5/17/2018, 9:17:51 PM] [hasagi]: :thinkhard:
[5/17/2018, 9:17:56 PM] [hasagi]: I think so
[5/17/2018, 9:18:10 PM] []: `/tmp/this_is_runi_pids_dont_touch.pid`
[5/17/2018, 9:18:23 PM] [hasagi]: os.TempDir()
[5/17/2018, 9:18:25 PM] [hasagi]: :troll:
[5/17/2018, 9:18:28 PM] []: lúc khóc thì tự khóc thôi :troll:
[5/17/2018, 9:18:46 PM] [unrealhoang]: `/tmp/this_is_runi_pids_dont_touch_please.pid`
[5/17/2018, 9:20:51 PM] [hasagi]: có cách khác
[5/17/2018, 9:20:54 PM] [hasagi]: là export luôn
[5/17/2018, 9:21:11 PM] [hasagi]: export IDENTITY_PID=$!
[5/17/2018, 9:21:26 PM] [hasagi]: chạy 1 cái buffer thôi
[5/17/2018, 9:21:28 PM] [hasagi]: :thinkhard:
[5/17/2018, 9:21:30 PM] [hasagi]: seems good
[5/17/2018, 9:23:29 PM] [phat]: ```2. Be Consistent
A rule of thumb touched on by many is consistency. Because followers and friends will be looking out for your face first, it's important that once you find a photo that works, stick with it.
"Don't change it every few days. Don't even change it every month," said Chris Coyier, web designer and curator of CSS-Tricks. "Make one, do a good job, and leave it alone for a long time. People's attention is split a million different ways these days, and you only get a split second to try and make an impression and forge a connection. Consistency makes that easier."
This may be especially true for Twitter, where networks tend to go beyond personal friends and family.
"Your Twitter profile is your personal brand and with any brand, consistency is key," said web designer and illustrator Brad Colbow. "When you market yourself, your avatar becomes your logo. It will be seen on Twitter, Ning networks, Flickr, and in blog comments, everywhere."```
<https://mashable.com/2010/04/12/profile-picture-tips/#OzF9KCHPFmqa>
[5/18/2018, 4:50:58 AM] []: :face_palm:
[5/18/2018, 4:52:33 AM] []: <https://stackoverflow.com/questions/5173636/must-my-pidfile-be-located-in-var-run>
[5/21/2018, 7:45:32 PM] [SFzxc]: <https://github.com/facebook/osquery>
[5/21/2018, 7:59:35 PM] [anh bán chuối]: ahihi, qua mới coi cái này :smile:
[5/21/2018, 8:08:49 PM] [SFzxc]: e đọc qua báo zing
<https://news.zing.vn/startup-my-gay-sung-sot-vi-tim-ra-cach-sieu-viet-bao-ve-may-tinh-post844669.html>
[5/21/2018, 8:26:16 PM] [anh bán chuối]: lol, qua a đọc bài này ở trang nào đó, giờ bọn zing nó dịch =))
[5/21/2018, 8:40:10 PM] [hasagi]: out date vãi
[5/21/2018, 8:40:29 PM] [hasagi]: :troll:
[5/25/2018, 4:13:47 AM] [huynh.cam]: #til hôm nay là ngày Châu Phi
[5/28/2018, 8:11:49 PM] [話せる森林]: #til Hoa cúc tốt cho gan. Mỗi sáng làm một cốc trà hoa cúc mật ong chanh không cần ăn sáng kết hợp tập thể dục buổi tối thì có thể giảm cân khá tốt. Trong hai tuần có thể từ 96.4 xuống 93.8...
[5/28/2018, 8:12:44 PM] [vunv]: @rikimaru về HP uống trà hoa cúc thôi a
[5/28/2018, 8:13:10 PM] [話せる森林]: Anh cầm 2 cân hoa cúc Hải Phòng qua bên này rồi. Cái 2 tuần kia chính là anh đó.
[5/28/2018, 8:29:29 PM] [lATAl]: Đi tìm mua trà hoa cúc thôi :3
[5/28/2018, 10:07:54 PM] [minh.nguyen]: nghe giống tác dụng của cần nhỉ
[5/28/2018, 10:08:45 PM] [話せる森林]: Đùa chứ anh cũng đang định hút cần mà nhờ con bé Hà Lan mua cho một cân xong nó về nước mất...
[5/29/2018, 1:11:50 AM] []: #til: Remove containers: `delete_ct=ubuntu &amp;&amp; docker rm $(docker ps -a | grep $delete_ct | cut -d" " -f1)`
[5/29/2018, 11:03:24 PM] [dan]: #til: có &gt; 250k người Hmong ở mỹ
[5/30/2018, 12:00:43 AM] [Cậu Làm Vườn]: Mình xem Gran Torino mới biết
[5/30/2018, 12:13:05 AM] [imah]: :open_mouth:
[5/30/2018, 2:25:02 AM] [typescriptpher]: #til compiler intrinsics <https://www.linuxjournal.com/content/introduction-gcc-compiler-intrinsics-vector-processing>
[5/31/2018, 8:10:29 PM] [tay vịn của anh bán chuối - cty A tìm FE]: #til <https://en.wikipedia.org/wiki/Sandbox_(software_development)>
[6/1/2018, 8:00:54 PM] [karmiphuc]: @nhducit - how about 1 more, bro? <https://en.wikipedia.org/wiki/Shift_left_testing>
[6/12/2018, 2:23:39 AM] [42]: #til Vào <https://devdocs.io/> tra doc rất thích :3
[6/13/2018, 5:08:50 AM] [Cậu Làm Vườn]: #til module script in supported browsers is deferred by default
[6/13/2018, 10:22:22 PM] [alias Trung.Le, as tle]: #til wrapping an array of elements under `React.Fragment`
[6/13/2018, 11:33:38 PM] [noob]: Anh bữa nay làm react à :33:
[6/14/2018, 10:07:12 PM] [Anh Xe Ôm]: #til lên youtube mở nhạc x2 speed, nghe lại bằng x1 speed sẽ có cảm giác khác lạ :arggg:
[6/14/2018, 10:07:32 PM] [Anh Xe Ôm]: theo đúng quy trình, cộng đồng js lớn nhất VN
[6/17/2018, 10:10:11 PM] [anh bán chuối]: #til Process.pid == $$ :v
[6/18/2018, 8:13:22 PM] [alias Trung.Le, as tle]: #til we all lacking understanding of fallacy and critical thinking, time to learn <https://yourlogicalfallacyis.com/>
[6/19/2018, 2:44:14 AM] [phat]: <https://www.youtube.com/watch?v=g0dN8Hkh5H8>
Deciding between Compute Engine, Container Engine, App Engine and more (Google Cloud Next ’17)
tldw: 44:00
[6/21/2018, 11:59:01 PM] [話せる森林]: #til Bạn có thể tạo ticket trên redmine để rủ bạn nữ nào đó trong team đi ăn trưa.
[6/22/2018, 10:34:17 AM] [phat]: <http://statcounter.com/insights/seo/seo-training>
[6/25/2018, 9:31:37 AM] [phat]: <https://readthedocs.org/>
&gt;Free docs hosting
&gt;We will host your documentation for free forever. There are no tricks. We help 84,927 open source projects share their docs.
[6/25/2018, 6:43:33 PM] [alias Trung.Le, as tle]: #til TypeScript enum <https://www.typescriptlang.org/docs/handbook/enums.html>
[6/26/2018, 2:01:36 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til git branch | grep -v "master" | xargs git branch -D
[6/26/2018, 6:00:46 PM] [dan]: #til ruby vietnam là cộng đồng ~js~ ruby lớn nhất việt nam.
[6/26/2018, 6:12:56 PM] []: :))
[7/6/2018, 12:29:16 AM] [huy]: #til Chú ý type khi làm việc với SQL queries :doubt:
[7/6/2018, 12:41:58 AM] [manhdv]: #til TracePoint
<https://ruby-doc.org/core-2.0.0/TracePoint.html>
[7/6/2018, 1:40:25 AM] [話せる森林]: #til poll là lấy ra phần tử max rồi xoá nó đi. (thuật ngữ tương đương: pop - lấy phần tử ở vị trí quy định trước rồi xoá nó đi, peek - lấy phần tử ở vị trí quy định trước nhưng không xoá nó đi, push - đưa phần tử vào vị trí quy định trước)
[7/6/2018, 2:43:52 AM] [huy]: #til how to tăng lương: `echo “I quit” | mail -s “bye” ceo@&lt;your-company&gt;.com`
[7/6/2018, 2:46:14 AM] [Anh Xe Ôm]: this email will be put to spam box :troll:
[7/6/2018, 2:47:51 AM] [huy]: :omg:
[7/9/2018, 7:14:14 AM] [Anh Xe Ôm]: #til nhìn một cô gái tập trung đọc sách thật xao xuyến :adore:
[7/9/2018, 5:44:37 PM] [話せる森林]: Anh Thính ở Hà Nội em sẽ dẫn anh đến 1 quán coffee maid... Khách đến đó đúng là chỉ để nhìn 1 em maid đọc sách bên cửa sổ.
[7/9/2018, 5:45:59 PM] [話せる森林]: #til Sự ngu dốt chưa phải trả giá. Một ngày nọ đọc một bài viết dùng tiếng Việt 'sách trắng' để chỉ 'white paper'. Nhưng ngờ đâu Bạch Thư là có thật.
<https://vi.wikipedia.org/wiki/S%C3%A1ch_tr%E1%BA%AFng>
[7/9/2018, 9:05:56 PM] [Anh Xe Ôm]: thoy, tôi lạ gì anh hẹn hò cơ chứ :pikatroll:
[7/9/2018, 10:05:09 PM] [話せる森林]: Đùa! Em về không có 3G không liên lạc được với anh em xin địa chỉ ấy chứ. :disappointed: Phải về nhà mới có mạng để vào.
[7/10/2018, 1:03:11 AM] []: #til <chrome://flags/>
[7/11/2018, 12:23:31 AM] [話せる森林]: #til Trong Python thì dict có thể dùng boolean làm key và key này được chuyển thành số 1 với `True` và số 0 với `False`.
```
&gt;&gt;&gt; {1: '1', True: 'True'}
{1: 'True'}
&gt;&gt;&gt; {2:'1', True:'True'}
{2:'1', True:'True'}
```
[7/12/2018, 2:16:19 AM] [SFzxc]: #til docker-multi-stage builds
[7/13/2018, 3:35:16 AM] [Anh Xe Ôm]: ^ #til
[7/13/2018, 3:35:39 AM] [typescriptpher]: :okay:
[7/13/2018, 3:35:52 AM] [typescriptpher]: no' la 1 cai protocol, sieu cu roai, anh cung chua thay cho na odung luon
[7/13/2018, 3:37:14 AM] [Anh Xe Ôm]: cần biết cái gì cứ hỏi anh -&gt; proxy :troll:
[7/13/2018, 3:44:17 AM] [typescriptpher]: #til ""Night gathers, and now my watch begins. It shall not end until my death. I shall take no wife, hold no lands, father no children. I shall wear no crowns and win no glory. I shall live and die at my post. I am the sword in the darkness. I am the watcher on the walls. I am the shield that guards the realms of men. I pledge my life and honor to the Night's Watch, for this night and all the nights to come."
<http://www.dependencywalker.com/help/html/hidr_module_tree_view.htm>
[7/17/2018, 9:34:33 PM] []: #til: Mới biết link theo từng năm `Archive Yearly Archives: 2018`
<http://www.rubyguides.com/2018/>
[7/17/2018, 11:27:36 PM] [alias Trung.Le, as tle]: #til `codedeploy-agent` (AWS Codedeploy) does have a cron job which periodically update the codedeploy-agent, in order to disable it, simply remove `/etc/cron.d/codedeploy-agent-update`
[7/18/2018, 8:24:27 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: #til Google Lighthouse :open_mouth:
[7/19/2018, 10:45:23 PM] [alias Trung.Le, as tle]: #til `docker attach --sig-proxy=false &lt;container_id&gt;` to attach to container to view all STDOUT output if your container happens to use different logging driver
[7/20/2018, 12:23:38 AM] [toanha]: #til <https://superdry.apphb.com/tools/online-rsa-key-converter>
[7/21/2018, 9:04:46 PM] []: #til <https://en.wikipedia.org/wiki/Dewey_Decimal_Classification>
[7/23/2018, 1:10:00 AM] [minh.nguyen]: #til `xxd file | vim -` to open hex editor in vim
[7/23/2018, 2:14:55 AM] [hieu.huynh]: nice TIL :pray: somehow sẽ cần xxd để show hex của 1 file
để biết chính xác những kí tự mà nhìn bằng mắt thường ko thấy
[7/23/2018, 2:16:28 AM] [minh.nguyen]: #til cái nữa. Mở bằng vim xong `:%!xxd -r` dể save lại :lol:
[7/23/2018, 4:32:20 AM] []: #til hầu hết cá mập ko biết thở, và phải bơi liên tục để nước chạy qua mang -&gt; lấy oxy
[7/23/2018, 6:06:54 AM] []: Hầu hết? Và là có loại thở được?
[7/23/2018, 6:40:29 AM] []: @triet Dạ, có một số loại có cơ hoành đủ khoẻ để ép nước qua ( lemon shark), còn lại thì không. Cũng là lý do cá mập nuôi nhốt thuỷ cung hay bị chết.
[7/23/2018, 11:34:59 AM] [huy]: #til `npm ci`
[7/23/2018, 11:35:06 AM] [huy]: <https://docs.npmjs.com/cli/ci>
[7/23/2018, 7:34:01 PM] [quannt]: nice
[7/23/2018, 7:42:27 PM] [typescriptpher]: #til <http://serveo.net/>
[7/23/2018, 9:06:20 PM] [huy]: Credit thuộc về @nhducit và một anh nữa trc cũng ở trong đây
[7/23/2018, 9:16:02 PM] [tay vịn của anh bán chuối - cty A tìm FE]: Anh ấy là trùm reasonml đó
[7/23/2018, 9:16:54 PM] [tay vịn của anh bán chuối - cty A tìm FE]: Đúng ra ngồi ngẫm lại nếu có caching thì em cũng không cần bundeDependencies nữa
[7/24/2018, 1:32:07 AM] [dan]: #til <https://www.postgresql.org/list/pgsql-performance/>
[7/24/2018, 4:17:34 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til
`.yarnrc`
```
# Remove prefix like '^' or '~' when add new package
save-prefix ""
```
[7/24/2018, 7:59:30 AM] []: #til:
x60 speed khi đổi từ array sang hash.
x20 speed khi dùng string builder với SQL thay vì active record.
[7/24/2018, 11:58:41 PM] [Anh Xe Ôm]: #til <https://www.python.org/dev/peps/pep-0557/>
[7/25/2018, 1:09:11 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til <https://crontab.guru/>
[7/25/2018, 1:18:10 AM] [vunv]: ^ cứ config crontab là vào 1 lần =))
[7/25/2018, 7:06:37 PM] [話せる森林]: Có tool đo không bạn?
[7/25/2018, 7:51:50 PM] [mymai]: #til “user_id:&lt;&gt;id = “user_id:6”
=&gt; id=6
<#C0JD6N86S|elixir> #pattern_matching
[7/25/2018, 7:52:46 PM] [unrealhoang]: id = “6” chứ :think:
[7/25/2018, 8:19:53 PM] [vthang]: #til linuxkit
[7/25/2018, 10:17:40 PM] [mymai]: Yeah, 1 like hehe
[7/26/2018, 1:33:08 AM] [dan]: #til window.devicePixelRatio and window.matchMedia
[7/26/2018, 6:31:48 AM] []: Mình chạy thực trên môi trường production. Và tính toán ra :smile:
[7/26/2018, 6:33:26 AM] []: Áp dụng với 500k records trở lên. Mới thấy rõ khác biệt.
[7/26/2018, 10:24:50 AM] [huy]: #til Google tự sản xuất chip để hoàn toàn kiểm soát mọi thứ, nâng tầm bảo mật <https://cloudplatform.googleblog.com/2017/08/Titan-in-depth-security-in-plaintext.html>
[7/26/2018, 6:32:09 PM] [xentence]: #til How Google built Duplex
[7/26/2018, 6:32:11 PM] [xentence]: <https://ai.googleblog.com/2018/05/duplex-ai-system-for-natural-conversation.html>
[7/28/2018, 3:42:26 AM] [typescriptpher]: #til that “Goodbye” comes from the 16th century, when someone wrote “God b w ye” as a contraction of “God be with ye.”
[7/29/2018, 7:38:04 AM] [quannt]: #til co the dung Beacon API de send fire and forget request tu browser len server thay vi dung ajax nhu thuong le. Rat huu dung trong cac truong hop send log, analytics, etc
[7/30/2018, 9:09:06 PM] [huy]: #til Old but gold, DO NOT remove list item while iterating
[7/30/2018, 9:15:44 PM] [typescriptpher]: #til LLVM passes <http://llvm.org/docs/Passes.html>
[7/31/2018, 12:35:16 AM] [xentence]: #til Lầy lội quá sẽ bị đuổi việc và đơn giản chỉ cần cty vắng client là sml
[7/31/2018, 12:36:06 AM] [unrealhoang]: @snacky you could not even do that in Rust
[7/31/2018, 12:40:54 AM] [huy]: Not until Vec::remove_item() stable
[7/31/2018, 12:42:18 AM] [huy]: Cty có bồi thường gì ko. Thông báo trước theo hợp đồng nữa
[7/31/2018, 12:43:10 AM] [huy]: Bên này dùng kết hợp Google Analytics và Mixpanel
[7/31/2018, 1:21:33 AM] [anh bán chuối]: :thinkold:
[7/31/2018, 2:06:51 AM] [xentence]: nó chỉ đưa lương tháng nay thôi , máy thì giữ . :okay: nhưng lại phải lao đầu đi apply tiếp
[7/31/2018, 2:09:23 AM] [__.__Sectumsempra__.__]: #til _Tần số gáy của dế phụ thuộc vào nhiệt độ của không khí, đếm số lần dế gáy trong vòng 25 giây rồi chia cho ba và cộng bốn là sẽ ra được nhiệt độ bằng độ C_
Khổ nỗi hơn 10 năm nay k còn được nghe tiếng dế gáy nữa để kiểm chứng
[7/31/2018, 2:15:59 AM] [hieu.huynh]: scientist phương nào đây :think:
[7/31/2018, 2:37:34 AM] [話せる森林]: Vkl thế để mình gửi cho. Cả ngày mình bấn loạn với dế. Nhà có mấy cây anh đào trước cửa mùa đông đẹp nao lòng mà mùa hè thì đến bấn loạn.
[7/31/2018, 2:43:20 AM] []: có khi nào nhầm với con ve ko :thinking_face:
[7/31/2018, 2:45:09 AM] [hieu.huynh]: well, ở 1 thế giới nọ, cả tầng tầng lớp lớp scientist, người ta đẻ ra hàng loạt method, hàng loạt cảm biến, để tính toán ước lượng *nhiệt độ* một cách chính xác nhất
[7/31/2018, 2:45:26 AM] [hieu.huynh]: vẫn ko bằng ở đông lào, anh scientist đo nhiệt độ bằng con dế :luon:
[7/31/2018, 12:11:45 PM] [huy]: #til splice
[1] <https://linux.die.net/man/2/splice>
[2] <https://news.ycombinator.com/item?id=15455897>
[7/31/2018, 12:12:33 PM] [huy]: [3] <https://web.archive.org/web/20130305002825/http://kerneltrap.org/node/6505>
[7/31/2018, 8:17:20 PM] [hieu.huynh]: cái post này trên HN cũ lắm rồi
```
452 points by omn1 9 months ago
```
[7/31/2018, 8:17:27 PM] [hieu.huynh]: anh tìm ra nó bằng cách nào?
[7/31/2018, 8:18:17 PM] [hieu.huynh]: hay chính xác là mình có thể tìm lại những bài dc upvote cao (nhưng cũ) ở HN ntn, lâu lâu rảnh em có nhu cầu xem lại, tại em ko có lên HN đều đặn, nên miss
[7/31/2018, 8:24:13 PM] [huy]: E dùng hnangola gì đó để search đi
[7/31/2018, 8:29:46 PM] [hieu.huynh]: hmm, tự làm 1 cái xài :luon:
[7/31/2018, 8:29:51 PM] [hieu.huynh]: HN có api public
[8/1/2018, 12:13:42 AM] [alias Trung.Le, as tle]: #til fluentd-grok plugin
[8/1/2018, 6:27:24 PM] [話せる森林]: #til Không rõ lý do nhưng đo kiểu gì cách thứ nhất vẫn nhanh hơn cách thứ hai.
```
class Solution:
def middleNode(self, head):
"""
:type head: ListNode
:rtype: ListNode
"""
fast, slow = head, head
while fast and fast.next:
fast = fast.next.next
slow = slow.next
return slow
```
```
class Solution:
def middleNode(self, head):
"""
:type head: ListNode
:rtype: ListNode
"""
fast = head
while fast and fast.next:
fast = fast.next.next
head = head.next
return head
```
[8/1/2018, 10:50:50 PM] [話せる森林]: Mà bạn có thể giải thích đoạn ruby trên rõ hơn được không?
[8/1/2018, 11:57:25 PM] [la petite ruby]: @rikimaru chổ này mình mới biết được á bạn, là khi mình truyền argument cho một hàm mà thêm : vào sau argument, như trong code mình để là arg: thì khi mình gọi hàm mình có thể thêm tên của argument này vào, còn ko có : thì mình chỉ có thể truyền giá trị vào thôi. Như vậy có : có thể làm code mình dễ đọc hơn, biết được tham số mình truyền vào là gì khi gọi hàm. btw, ngôn ngữ mình dùng là ruby
[8/1/2018, 11:57:40 PM] [la petite ruby]: hổng biết mình giải thích có dễ hiểu hok @.@
[8/1/2018, 11:58:38 PM] [話せる森林]: Thực ra til là bạn hiểu gì bạn viết đó thôi. Mục đích là để mọi người giúp bạn xem bạn có hiểu đúng không hoặc là giúp người khác hiểu.
[8/1/2018, 11:59:58 PM] [la petite ruby]: uhm ^_^
[8/2/2018, 11:01:07 PM] [Anh Xe Ôm]: #til usb-c phức tạp hơn mình tưởng nhiều
<https://medium.com/@su.no/why-usb-type-c-is-bad-design-ffcd77254c1f>
[8/5/2018, 6:44:58 PM] [話せる森林]: #til Dùng cái này rất là cool. Nhất là khi khoe mẽ với các em tester Tân Binh... :heart:
<https://github.com/jesseduffield/lazygit>
[8/5/2018, 6:52:50 PM] [dan]: magit ngon hơn :dogejump:<https://github.com/magit/magit>
[8/5/2018, 6:59:31 PM] [話せる森林]: Cái này chạy trên Ubuntu có được không? Ở công ty không test được.
[8/5/2018, 7:01:37 PM] [dan]: đc chứ anh chạy trên emacs mà
[8/5/2018, 7:02:32 PM] [dan]: thêm cái magit-pull-request nữa là tạo đc PR từ emacs luôn khỏi cần lên github :v
[8/5/2018, 7:03:02 PM] [話せる森林]: emacs mình chưa dùng nhưng mà mình nghĩ là nó chỉ cho Mac
[8/5/2018, 7:04:13 PM] [dan]: :v emacs dùng hdh nào cũng ok mà
[8/5/2018, 7:04:46 PM] [dan]: Editing MACroS -&gt; emacs
[8/5/2018, 7:05:31 PM] [話せる森林]: :smile:
[8/5/2018, 10:28:35 PM] [hasagi]: #til bikeshedding - Futile investment of time and energy in discussion of marginal technical issues.
[8/5/2018, 11:00:17 PM] [unrealhoang]: usually online, with people you don’t know, just to prove them wrong
[8/5/2018, 11:00:19 PM] [unrealhoang]: :roflrofl:
[8/5/2018, 11:02:44 PM] [hasagi]: =))
[8/5/2018, 11:02:58 PM] [hasagi]: @eyeball vô đăng cái ảnh huyền thoại cái
[8/5/2018, 11:06:35 PM] [dan]: #til `document.links`
[8/5/2018, 11:07:23 PM] [typescriptpher]: cái someone wong on internet á =))
[8/5/2018, 11:07:30 PM] [hasagi]: nó đó
[8/5/2018, 11:07:31 PM] [hasagi]: =))
[8/5/2018, 11:08:50 PM] [hasagi]: =))
[8/6/2018, 12:08:48 AM] []: @eyeball lưu meme ở máy sẵn sàng post à =))
[8/6/2018, 12:25:52 AM] [unrealhoang]: @eyeball is actually an AI
[8/6/2018, 12:25:59 AM] [unrealhoang]: :think:
[8/6/2018, 12:32:29 AM] [typescriptpher]: ask Google sama thoai =))
[8/6/2018, 12:44:18 AM] [typescriptpher]: <https://i.imgur.com/yID9Qj4.jpg> @bach.do.ucl :))
[8/6/2018, 12:47:39 AM] []: anh @eyeball là ghost in the shell rồi :))
[8/7/2018, 9:24:30 PM] [話せる森林]: #til <https://www.interviewcake.com/>
Trang này có vài bài khá hay
[8/8/2018, 11:15:30 PM] [話せる森林]: #til curl doesn't support HTTPS proxy so you get this message to make you aware of that so that you don't think you're actually are using a HTTPS proxy.
&gt; curl: (7) Unsupported proxy scheme for '<https://rikimaru:crystalmaiden@xxx.xxx.xxx.xxx:80>'
Change to `https_proxy=<http://rikimaru:crystalmaiden@xxx.xxx.xxx.xxx:80>`. That works!
[8/8/2018, 11:41:41 PM] [huy]: #til :see_no_evil: :hear_no_evil: :speak_no_evil:
[8/9/2018, 12:03:41 AM] [dan]: thiếu con `do no evil` nữa
[8/9/2018, 8:41:58 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: #til The name Redis means REmote DIctionary Server :thinkhard:
[8/9/2018, 3:23:40 PM] [huy]: #til V8 won't optimize functions with `try-catch` in íts body.
[8/10/2018, 12:27:38 AM] []: #til <https://serveo.net/> - ngrok alternative.
[8/10/2018, 12:53:20 AM] [tay vịn của anh bán chuối - cty A tìm FE]: @snacky có lý do hơm thím
[8/10/2018, 4:09:07 AM] [FULLCLEARONSTAGE]: #til y combinator <https://medium.com/@ayanonagon/the-y-combinator-no-not-that-one-7268d8d9c46>
[8/10/2018, 4:12:43 AM] [noob]: đang đọc chủ đề này lun :omg:
[8/10/2018, 7:31:52 AM] [Stephen]: buồn
&gt; This free version is intended for evaluative and personal use and allows no more than 3 total simultaneous tunnels per instance.
[8/10/2018, 7:39:00 AM] [huy]: Có. Vì nó là low priority. Ko ai màng tới chuyện implement cái đó :))) có thể tương lai sẽ đổi
[8/11/2018, 11:21:47 AM] [Anh Xe Ôm]: #til <https://en.wikipedia.org/wiki/Leap_second>
[8/12/2018, 9:10:28 AM] [話せる森林]: #til sủi cảo có tôm, hoành thánh ko có tôm, há cảo có tôm nhưng thường bột bên ngoài màu trắng (bột gạo), sủi cảo với hoành thánh bột màu vàng (bột mì), sủi cảo hình dẹt, hoành thánh há cảo mập mập tròn tròn. xin hết
[8/12/2018, 12:47:28 PM] [huy]: #til Over 90% of all Hiring Managers used software called ATS (Application Tracking System) to determine if your resume is qualified with his/her job post or not (in the US job market, AFAIK). These fucking software is basically an OCR algorithm that does not work well with fancy designed or PDF based resumes. So, the next time you find a job, write your resume/cover letter in MS Word format, use a simple layout, so that fucking tool won't miss you out. It's a multi-year broken system, you can't do anything but compromise.
Facts:
[1] Tools like LinkedIn, ZipRecruiter, Indeed, Monster also having a recommendation system based on parsed data from resumes, so they're ATS-like as well.
[2] over 98% of Fortune 500 companies using ATS (<https://www.jobscan.co/blog/fortune-500-use-applicant-tracking-systems/>)
[3] 75% of large companies using ATS (<https://www.baruch.cuny.edu/wsas/graduatecareers/documents/Resumes-ApplicantTrackingSystems2.pdf>)
[8/12/2018, 6:13:28 PM] []: &gt; A small company with just eight employees can save $10,000 in wasted time and effort using an ATS. For big companies, the savings are much more. That money motivation means the ATS is only going to become more prominent.
Holy :shit:
[8/12/2018, 7:32:46 PM] []: So, what’s a ATS-Friendly resume?
- <https://www.hloom.com/resumes/ats-resume-templates/>
- <https://resumegenius.com/blog/applicant-tracking-systems-resume-keyword-help>
[8/12/2018, 10:50:35 PM] [anh bán chuối]: #til "All Flash No Cash" -- People who spend money that they do not have.
:v <https://www.urbandictionary.com/define.php?term=All+Flash+No+Cash>
[8/14/2018, 5:02:23 PM] []: #til:
Mất 8Kb để khởi tạo process
Process list được implement bằng double linked list
[8/15/2018, 2:08:20 AM] [huynh.cam]: #til
```
const { name } = person;
# is equivalent to
const name = person.name;
```
[8/15/2018, 2:10:59 AM] []: Lol
[8/15/2018, 2:11:05 AM] []: Muộn nhé
[8/15/2018, 2:19:25 AM] [Anh Xe Ôm]: javascript?
[8/15/2018, 2:21:28 AM] [hasagi]: cái nồi gì thế này
[8/15/2018, 2:29:36 AM] [huynh.cam]: mình sẽ đặt tên cho cái này là pattern matching nửa mùa
[8/15/2018, 2:33:24 AM] [hasagi]: vừa test
[8/15/2018, 2:33:28 AM] [hasagi]: that’s JS
[8/15/2018, 2:33:29 AM] [hasagi]: :kappa:
[8/15/2018, 2:41:46 AM] [dat]: #til locatedb <https://www.freebsd.org/cgi/man.cgi?query=locatedb&amp;manpath=SuSE+Linux/i386+11.3>
[8/15/2018, 2:44:38 AM] [Cậu Làm Vườn]: -&gt; Destructuring
JS ftw! \m/
[8/15/2018, 2:59:50 AM] [Cậu Làm Vườn]: ```
const {name: displayName = "Anonymous", place: city = "HMC City"} = user
```
[8/15/2018, 11:46:55 PM] [hieu.huynh]: #til wrap code in JIRA comment
```
{noformat:nowrap}
This could be a really long line without wraps
{noformat}
```
<https://community.atlassian.com/t5/Jira-questions/word-wrap-in-Jira-comment/qaq-p/250002>
[8/15/2018, 11:48:18 PM] [hieu.huynh]: giá trị vcl trong việc put mấy info vô ticket kiểu `investigating issue`
[8/15/2018, 11:48:41 PM] [hieu.huynh]: cần pass nguyên đọan log dài sọc vô mà vẫn hiển thị tốt
[8/16/2018, 12:04:17 AM] [typescriptpher]: #til disk vs rdisk <https://superuser.com/questions/631592/why-is-dev-rdisk-about-20-times-faster-than-dev-disk-in-mac-os-x>
[8/16/2018, 6:17:17 AM] []: anh @eyeball đang nghịch gì rpi đấy :))
[8/17/2018, 3:42:38 AM] [vthang]: #til Cannot run cassandra with hostname `☭ vthang ☭` :doubt:
[8/17/2018, 2:15:42 PM] [huy]: #til A single page of book worth thousands hours of search
[8/18/2018, 12:25:02 PM] [huy]: #til Tips to convert two columns papers to Kindle (<http://www.willus.com/k2pdfopt/download/>)
`k2pdfopt pdffile.pdf` -&gt; hit enter twice
[8/18/2018, 12:25:13 PM] [huy]: cc @eyeball
[8/18/2018, 12:35:58 PM] [huy]: Demo
[8/19/2018, 11:51:33 AM] []: #til w3 began as one of CERN’s projects :fast-omg:
<https://www.w3.org/History/19921103-hypertext/hypertext/WWW/History.html>
[8/19/2018, 6:40:51 PM] []: Mỗi lần thấy cern tự nhiên lại nghĩ tới stein gate
[8/19/2018, 7:21:22 PM] [typescriptpher]: ngày xưa mềnh toàn làm ngược lại, gộp 2 trang làm 1 để tiết kiêm tiền giấy in = ))
[8/19/2018, 7:21:31 PM] [typescriptpher]: hồi học sinh với sinh viên, in 1 trang đắt lắm :))
[8/19/2018, 8:34:35 PM] [話せる森林]: #til Đừng đặt tên công ty mà có cái dấu `_` hoặc `-`. Nếu không thì ít nhất cũng bỏ hai cái dấu đó ra khỏi domain name của công ty bời vì đến lúc đăng kí thư viện sẽ tốn rất nhiều công sức.
[8/19/2018, 8:38:42 PM] []: <https://imgs.xkcd.com/comics/exploits_of_a_mom.png>
[8/19/2018, 9:16:18 PM] [typescriptpher]: bobby tables :))
[8/19/2018, 9:37:22 PM] [typescriptpher]: #til Ignore the Sun Java Coding Conventions, after all, Sun does
[8/19/2018, 9:45:46 PM] [quannt]: #til Boolean lấy theo tên của George Boole, nhà toán học người Anh
[8/19/2018, 9:51:52 PM] [// english-ignore]: ^ re: con cái của ổng, Ethel Voynich, là tác giả của quyển _Ruồi trâu_
[8/19/2018, 10:29:14 PM] []: Còn mình, người dưng của ổng, chuyên làm chuyện ruồi bu.
[8/21/2018, 9:26:26 PM] [manhdv]: #til: <https://github.com/tekezo/Karabiner-Elements>
Remap international1 to equal_sign key to avoid the pain in Apple JIS keyboard
[8/21/2018, 10:50:19 PM] [Anh Xe Ôm]: #til datetime in javascript, month start as 0
```
&gt; new Date(2018, 1, 1)
Thu Feb 01 2018 00:00:00 GMT+0700 (Indochina Time)
```
[8/21/2018, 10:51:35 PM] [huy]: ^ ko đọc kĩ document chứ #til gì
[8/21/2018, 10:51:37 PM] [huy]: :thinkhard:
[8/21/2018, 10:52:16 PM] [huynh.cam]: ^ :baby_chick:
[8/21/2018, 11:01:55 PM] [話せる森林]: Today I read documents carefully... =))
[8/22/2018, 12:02:33 AM] [hasagi]: #til gamification: game hóa các ứng dụng, bằng việc thêm vào các additional features để người dùng cảm thấy đang chơi game, thăng cấp …
[8/22/2018, 12:35:35 AM] []: #til dau `-&gt;` trong toan co nghia la `|| ^`. Vi du `a -&gt; b` co nghia la `a || ^b`
[8/22/2018, 1:13:42 AM] []: Là sao cưng
[8/22/2018, 1:13:58 AM] []: @hieuk09
[8/22/2018, 1:23:40 AM] [dat]: `a -&gt; b` tuong duong voi `^a || b` chu anh nhi
[8/22/2018, 1:31:20 AM] [manhdv]: `^` la gi vay ban @taurandat
[8/22/2018, 1:31:38 AM] [dat]: à ý em là NOT đó anh
[8/22/2018, 1:31:50 AM] [dat]: a = True thì ^a = False
[8/22/2018, 1:32:05 AM] [manhdv]: va || nghia la Hoac(OR) nhi?
[8/22/2018, 1:32:13 AM] [dat]: :+1:
[8/22/2018, 1:32:19 AM] [manhdv]: nghia la neu viet theo kieu lap trinh thi la !a || b
[8/22/2018, 2:15:28 AM] []: uh, minh nham :smile:
[8/22/2018, 2:22:06 AM] []: Cái này là xét giá trị chân trị đúng ko
[8/22/2018, 4:50:59 AM] []: dung roi @anhduy
[8/22/2018, 4:52:18 AM] []: Ờ
[8/22/2018, 5:47:19 AM] []: #til `ldd` list dependcies :disappointed:
[8/24/2018, 11:42:46 AM] [話せる森林]: #til nếu viết bài trong kipalog và dùng chức năng search thì chỉ có thể search được ở trong bên xem thử chứ không search được ở phần soạn thảo.
[8/24/2018, 5:50:49 PM] [typescriptpher]: #til <https://blog.tartanllama.xyz/spaceship-operator/>
[8/26/2018, 10:38:29 PM] [alias Trung.Le, as tle]: #til blue green deployment of AWS CodeDeploy
[8/26/2018, 11:40:39 PM] [huy]: #til Cái gì muốn đưa vào TODO list thì luôn luôn phải có Definition of Done, nếu không thì không nên đưa vào (để tránh việc goal mập mờ sẽ không bao giờ hoàn thành, mất motivation, mất niềm tin vào bản thân, vào cuộc sống, vào nhân loại)
[8/26/2018, 11:45:56 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: =))) tốt nhất nên có expire time, sau 1 thời gian mà đã ko ngó lại thì chắc cmn chắn là ko cần thiết tốt nhất nên mạnh dạn destroy, giữ lại chỉ tổ nặng đầu
[8/26/2018, 11:46:41 PM] [huy]: Đúng rồi =))) phải có expr time nữa
[8/26/2018, 11:52:45 PM] [__.__Sectumsempra__.__]: Mn dùng gì để lưu TODO list vậy ạ? Thing 3, notes....?
[8/26/2018, 11:53:36 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: =))) lưu làm gì, lưu nhiều xóa nhiều thôi em
[8/26/2018, 11:53:49 PM] [__.__Sectumsempra__.__]: ~~
[8/26/2018, 11:57:42 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: thật đấy, a thấy lưu todo nhiều chỉ tổ mệt não, lần nào nhìn vào cũng cả list dài dằng dặc
[8/26/2018, 11:59:30 PM] [huy]: @nghoapc a dùng giấy và bút, để trước mặt
[8/26/2018, 11:59:37 PM] [huy]: cần thêm gì thì thêm cái rẹt
[8/26/2018, 11:59:42 PM] [huy]: cần bỏ gì thì gạch bỏ cmnl
[8/26/2018, 11:59:52 PM] [huy]: cuối ngày thì xé ra vo lại vứt đi
[8/27/2018, 12:00:05 AM] [huy]: electronic todo list = ko bao giờ e nhìn vào
[8/27/2018, 12:00:41 AM] [huy]: bullet journal = piece of shit của bọn hipster, ngồi hì hục vẽ cái layout ra chụp hình up lên instagram xong vứt mẹ nó luôn cuốn sổ chứ cả năm đếch đụng vào đâu
[8/27/2018, 12:00:48 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :+1: đúng, nói chung a ít xài todo, nếu xài thì ghi giấy, mà xài cũng vài ngày rồi bỏ
[8/27/2018, 12:01:13 AM] [__.__Sectumsempra__.__]: Dạ hồi trước em dùng thing 3 đúng là k bh nhìn vào thật :sosad:
[8/27/2018, 12:01:41 AM] [__.__Sectumsempra__.__]: Nên giờ cũng đang chuyển dần qua viết tay
[8/27/2018, 12:02:09 AM] [huy]: của a nè
[8/27/2018, 12:02:10 AM] [hasagi]: elffin book
[8/27/2018, 12:33:15 AM] [xentence]: #til khi bạn gửi đồ có giá trị lớn mà không bọc khi đi gửi cho VNPOST =&gt; Mất hàng
[8/27/2018, 1:11:45 AM] [dan]: đợt trước có cái áo octoberfest cũng bị chôm :thinkcry:. Công mấy ông chuyển phát nhanh mê code.
[8/27/2018, 2:21:10 AM] [// english-ignore]: Đã mất niềm tin vô bưu điện VN từ lâu
[8/27/2018, 3:49:20 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til spotify desktop app được build bằng web technology: react redux app
[8/27/2018, 6:45:11 AM] [xentence]: cứ tưởng electron
[8/27/2018, 8:00:51 AM] [tay vịn của anh bán chuối - cty A tìm FE]: không phải, thấy mấy bạn ấy có load chrominium embed framework
[8/27/2018, 11:05:06 PM] [Cậu Làm Vườn]: :thinkhard: Em cũng cứ tưởng electron. Interesting...
[8/30/2018, 7:26:16 PM] [話せる森林]: #til Khi bạn buộc phải học một mình một thứ gì đó mà bạn không thích. Bạn có thể lên Youtube tìm dòng chữ `học cùng tôi`. Bạn sẽ có Promodo, nhạc thiền và một người để học cùng. Mỗi lần thấy nản nản muốn bật qua tab Facebook chơi mà ngẩng mặt lên thấy có người đang ngồi tập trung học thì bạn sẽ lại tự nhủ thôi học thêm tí nữa. Sau vài cái tí nữa là hết đêm. Một cách tự kỉ ám thị để có thể tự motivate bản thân.
[8/30/2018, 7:27:53 PM] [typescriptpher]: #til <https://en.wikipedia.org/wiki/Embedded_C%2B%2B>
[8/30/2018, 7:28:09 PM] [typescriptpher]: tl;dr javascript sucks =))
[8/30/2018, 7:28:19 PM] []: :))
[8/30/2018, 7:31:54 PM] [話せる森林]: Ruby on Rails route.rb cũng sucks huhu.
[8/30/2018, 7:33:22 PM] [anh bán chuối]: hoặc bạn có thể rủ bé Nhật đó học chung
[8/30/2018, 7:34:16 PM] [sondnm]: #til in linux, `init` has PID 1
[8/30/2018, 7:34:16 PM] [話せる森林]: Lúc đó thì lại hết đêm làm chuyện khác chứ không học được gì quá anh Long.
[8/30/2018, 7:42:36 PM] [minh.nguyen]: unfollow hết facebook là xong :))
[8/30/2018, 7:44:44 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: a/e khổ quá, xài cái này nè <https://pastebin.com/rHAVkuTV> :v
[8/30/2018, 8:13:18 PM] [anh bán chuối]: khi nào quởn thì vô profile từ người coi :))
[8/30/2018, 8:20:18 PM] []: ^ Ủa em nhớ FB dạo này nó còn có cái suggest posts từ FB nữa mà. Sao anh tắt cái đó được :thinkhard:
[8/30/2018, 8:22:27 PM] [anh bán chuối]: xài này nha Thảo <https://chrome.google.com/webstore/detail/news-feed-eradicator-for/fjcldmjmjhkklehbacihaiopjklihlgg>
[8/30/2018, 8:38:06 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :neutral_face: ghét cái đó vãi hà
[8/30/2018, 9:22:23 PM] [Cậu Làm Vườn]: ý, y chang em :))
[8/30/2018, 9:22:43 PM] [Cậu Làm Vườn]: No newsfeed, no problem
[8/31/2018, 2:48:39 AM] [話せる森林]: #til Với những compiler kiểu thực thi đến đâu bắn lỗi đến đấy như của Ruby thì bạn nếu đã không dùng IDE mà còn indent nhầm ` ` thành ` ` là được debug mỏi mắt luôn.
[8/31/2018, 2:49:40 AM] [話せる森林]: #til số 3 đấy là cái dấu ``` mà chứa toàn dấu space thì sẽ không có được nhận.
[8/31/2018, 3:00:46 AM] []: init là process quan trọng nhất
[8/31/2018, 3:11:26 AM] [long]: đa số ruby mình dùng đâu có cần compiled, nó là interpreted chứ hen
[9/2/2018, 8:26:33 AM] [Cậu Làm Vườn]: #til Web Speech API
<https://developer.mozilla.org/en-US/docs/Web/API/Web_Speech_API>
[9/6/2018, 5:42:27 PM] [huy]: #til `;t` in github
[9/6/2018, 6:24:42 PM] [manhdv]: Y H noi den chuc nang Find ngay tren web cua GH do ha?
neu la chuc nang do thi chi can nhan `t` la duoc ma nhi :thinking_face:
ngoai ra khi xem file thi nhan `y` de tao permanent link cung hay.
[9/6/2018, 6:26:05 PM] [huy]: à ra vậy, thằng bạn e nó chỉ là phải bấm ;t
[9/6/2018, 6:26:06 PM] [huy]: :)))
[9/6/2018, 6:46:47 PM] []: #til ruby co cu phap
```
begin
# do something
rescue
# handle exception
else
# handle other exceptions
end
```
[9/6/2018, 7:02:02 PM] [dan]: ^ thiếu `ensure`
[9/6/2018, 7:03:20 PM] [dan]: và `else` chỉ chạy lúc ko có exception nào chứ :think:
[9/6/2018, 7:09:34 PM] []: uhm, tai `ensure` minh biet roi nen ko viet vo day
[9/6/2018, 7:09:48 PM] []: `else` thi chay luc ko co exception, nhung ma dung de handle nhung cai tuong tu nhu exception
[9/6/2018, 7:12:20 PM] [dan]: e tưởng `else` dùng lúc block trong begin chạy ok chứ a
[9/6/2018, 7:18:05 PM] []: Y la ve mat sematic thi no se la the nay
[9/6/2018, 7:18:13 PM] []: ```
begin
dangerous_operation
rescue
log_error
else
if !check_result_correct
log_error
end
end
```
[9/6/2018, 7:19:29 PM] []: tuc la thay vi tach phan log error thu 2 ra ngoai `begin..rescue` block
[9/6/2018, 7:19:43 PM] []: thi minh gop chung no vao trong block
[9/6/2018, 7:19:51 PM] []: de luc doc code, minh biet la tui no lien quan den nhau
[9/6/2018, 7:20:39 PM] []: mot vi du cho usecase nay o day: <https://github.com/teamcapybara/capybara/pull/2095/files>
[9/6/2018, 7:30:32 PM] [dan]: code trên theo e hiểu là nó tách cái đó xuống else vì để tránh LoadError bị capture chỗ rescue.
[9/6/2018, 7:31:57 PM] [dan]: chứ nếu ko thì bỏ vào begin luôn cũng đc
[9/6/2018, 7:35:33 PM] []: ah, tat nhien la khong bo no vao begin duoc roi
[9/6/2018, 7:35:44 PM] []: y o day la thay vi bo doan unless ra ngoai block
[9/6/2018, 7:35:47 PM] []: thi nhet no vao else
[9/6/2018, 7:35:53 PM] []: de nguoi ta biet duoc la nguyen doan do
[9/6/2018, 7:35:56 PM] []: lien quan den nhau
[9/6/2018, 10:59:07 PM] [anh bán chuối]: #til <chrome://flags/#omnibox-ui-hide-steady-state-url-scheme-and-subdomains>
```
"www" is now considered a "trivial" subdomain, and hiding trivial subdomains can be disabled in flags (will also disable hiding the URL scheme)
```
[9/6/2018, 11:00:17 PM] [anh bán chuối]: <https://bugs.chromium.org/p/chromium/issues/detail?id=881410>
[9/6/2018, 11:00:27 PM] [anh bán chuối]: &gt; This is a dumb change. No part of a domain should be considered "trivial". As an ISP, we often have to go to great lengths to teach users that "<http://www.domain.com|www.domain.com>" and "<http://domain.com|domain.com>" are two different domains, and that they may not necessarily go to the same destination. The marketing world has done a lot of damage convincing people that "www" is both ubiquitous and non-essential, when in fact, for some domains, the use or lack of it can be quite important to getting to the correct location.
[9/6/2018, 11:00:29 PM] [anh bán chuối]: :v
[9/8/2018, 11:20:53 AM] [la petite ruby]: #til `rails c —sandbox` chạy console test mà hông ảnh hưởng đến data thật sau khi exit console.
[9/8/2018, 1:24:36 PM] [huy]: #til Scan toàn bộ table of content và mấy trang index của mấy cuốn sách trong tủ sách. Rồi cho vào OneNote. Từ bây giờ có thể search được kiến thức cần thiết từ mấy cuốn sách đang có, nhờ vào chức năng OCR của OneNote.
[9/9/2018, 5:24:00 PM] [manhdv]: có ông còn viết cái app upload ảnh scan của giấy tờ cá nhân lên, rồi sau đó cho phép search nữa cơ. Kiểu này lưu trữ tiện phết, lỡ bị gián nhấm vẫn có thể in màu đc :joy:
[9/9/2018, 5:26:02 PM] [manhdv]: <https://github.com/danielquinn/paperless>
[9/9/2018, 7:44:41 PM] [huy]: Ồ e mới biết cái này. Hay quá
[9/10/2018, 1:26:55 AM] [phat]: TIL: có rất nhiều chức năng trên redis, ví dụ như tìm khoảng cách giữa các lat, lng và cache
[9/13/2018, 11:40:10 AM] []: <https://youtu.be/1UnIDL-eHOs> #til ok means all correct :fast-omg:
[9/16/2018, 10:47:31 PM] []: #til <https://en.wikipedia.org/wiki/Taxonomic_rank> :fast-omg:
[9/19/2018, 3:08:56 PM] [huy]: <https://we-build-vn.slack.com/archives/C0J7M3P8V/p1537394922000100>
[9/19/2018, 3:08:58 PM] [huy]: :vayvay:
[9/20/2018, 2:08:27 AM] [dan]: #til persona non grata
[9/20/2018, 2:27:56 AM] [// english-ignore]: Thanh :vayvay:
[9/26/2018, 8:24:19 AM] [anh bán chuối]: #til `brew bundle dump` <https://medium.com/@abookyun/clean-install-your-mac-without-hesitation-7d379df8fc87>
[9/26/2018, 9:15:46 AM] [minh.nguyen]: #til Bật option `Settings &gt; Accessibility &gt; Display &gt; Reduce Motion` để giảm các hiệu ứng chuyển tab, chuyển workspace trên Mac. Có cảm giác nhẹ nhàng và mượt hơn
[9/26/2018, 9:30:40 AM] [typescriptpher]: vừa bấm thử cái "use grayscales", thấy cuộc đời toàn màu xám :roflrofl:
[9/26/2018, 9:36:45 AM] []: tl;dr đi anh @longkt90
[9/26/2018, 9:36:48 AM] []: :omg:
[9/26/2018, 9:37:40 AM] [minh.nguyen]: em cũng tính để thử. Mà sợ buông máy ra bị mù màu thì chết :rofl:
[9/26/2018, 10:10:52 AM] [typescriptpher]: thank em nhe, cai tip hay qua, con may doi 2013 cua anh chay muot han :)))))
[9/26/2018, 5:51:09 PM] [anh bán chuối]: đó, `brew bundle dump` :stuck_out_tongue:
[9/26/2018, 6:48:35 PM] [alias Trung.Le, as tle]: #til resque can be graceful shutdow by setting `GRACEFUL_TERM=yes` UNIX env for the worker process, that would wait for a job to finish then shutdown itself. However if you want to impose a timeout, you can set `RESQUE_PRE_SHUTDOWN_TIMEOUT=&lt;second&gt;` which would terminate the processing job after `&lt;second&gt;`
[9/26/2018, 7:30:17 PM] []: Clean your Mac after upgrade MacOS
[9/26/2018, 7:30:20 PM] []: I see :notbad:
[9/27/2018, 12:43:45 AM] [SFzxc]: #til `curl -o /dev/null` Measure response times
[9/27/2018, 1:02:30 AM] [hieu.huynh]: #til
- thể dục thể thao nhiều lên
- ăn uống kĩ càng chút
- *bớt* rượu bia nhậu nhẹt (chứ đừng kiêng :troll:)
- dậy sớm ngủ sớm chớ đừng ngược lại *force/must* :doubt:
một thanh niên mới đi health check cho hay :okay:
[9/27/2018, 1:06:37 AM] [Cậu Làm Vườn]: Ngành này ngồi nhiều quá cũng sợ
[9/27/2018, 1:07:03 AM] [hieu.huynh]: trĩ :doubt: :dogejump:
[9/27/2018, 1:07:37 AM] []: @hieu.huynh thấy ngày nào chả uống bia
[9/27/2018, 1:07:38 AM] []: :troll:
[9/27/2018, 1:07:56 AM] [Cậu Làm Vườn]: Bia bọt thì bỏ được hơn năm rồi
[9/27/2018, 1:08:00 AM] [Cậu Làm Vườn]: đỡ được khoảng đó
[9/27/2018, 1:08:15 AM] [hieu.huynh]: chớ sao :thinkold:
[9/27/2018, 1:08:23 AM] [hieu.huynh]: :why:
[9/27/2018, 1:08:35 AM] [hieu.huynh]: sao lại bỏ bia :arggg: còn gì là cuộc sống nữa người ơi
[9/27/2018, 1:08:44 AM] [__.__Sectumsempra__.__]: Có ai đau cột sống k :sosad: em mỗi lần bẻ hông là nghe rắc rắc mà cứ khoái bẻ lâu lâu bị đau rồi vài bữa lại hết :rip:
[9/27/2018, 1:08:45 AM] [// english-ignore]: chuyển qua uống gụ
[9/27/2018, 1:08:45 AM] [hieu.huynh]: --&gt; #random please
[9/27/2018, 1:08:46 AM] [Cậu Làm Vườn]: :tea:
[9/27/2018, 1:35:21 AM] [話せる森林]: Người yêu cũ của anh cũng thích làm trò này. Vẫn sống.
[9/27/2018, 1:36:13 AM] [話せる森林]: #til trong pip có một package là `request` (<https://pypi.org/project/request/>) và nó khác với package `requests` (<https://pypi.org/project/requests/>)
[9/28/2018, 3:01:49 AM] []: #til rsync :disappointed:
[9/28/2018, 3:28:07 AM] []: trước giờ tôi toàn git commit rồi lên server git pull các đồng chí ạ :disappointed:
[9/28/2018, 3:35:17 AM] []: sao không scp hay ftp :kappa:
[9/28/2018, 3:37:26 AM] []: xin đừng xát muối vào lòng em :disappointed:
[9/28/2018, 4:02:11 AM] []: Nike
[9/28/2018, 4:02:14 AM] []: :kappa:
[9/28/2018, 4:09:50 AM] [// english-ignore]: ^ như trên thì có gì nà sai?
[9/28/2018, 4:12:29 AM] [Cậu Làm Vườn]: same question
[9/28/2018, 4:28:22 AM] [hasagi]: Sai gì đâu
[9/28/2018, 4:28:36 AM] [hasagi]: Chắc kiểu khổ quen rồi sướng k chịu đc
[9/28/2018, 4:28:41 AM] [hasagi]: :))
[9/28/2018, 4:30:08 AM] [// english-ignore]: vậy dùng rsync để deploy như thế nào rựa? ._.
[9/28/2018, 4:36:16 AM] [anh bán chuối]: Php ah :))
[9/28/2018, 4:38:30 AM] [// english-ignore]: không hiểu đó, vì nếu đã dùng version control rồi thì rsync để mần chi :thinkhard:
[9/28/2018, 4:39:15 AM] [hasagi]: Static web?
[9/28/2018, 4:41:54 AM] [// english-ignore]: quick and dirty thì cũng có thể, nhưng nếu static web đó cũng đẩy vô git thì rsync có lợi gì hơn?
[9/28/2018, 4:42:30 AM] [anh bán chuối]: Uh. Cu git thoi.
[9/28/2018, 4:42:44 AM] [anh bán chuối]: Chu rsync nguy hiem :thinking_face:
[9/28/2018, 5:05:24 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: git pull thì cũng phải xài thêm cái gì đó mới pull nhiều node đc :thinkhard:
[9/28/2018, 5:09:37 AM] []: Có 1 node thì git pull là ok phải không anh @xluffy
[9/28/2018, 5:19:39 AM] [minh.nguyen]: nếu mà thời gian build code lâu
[9/28/2018, 5:19:46 AM] [minh.nguyen]: xài git là tự sát
[9/28/2018, 5:20:01 AM] [minh.nguyen]: ví dụ app rails mà cần build assets
[9/28/2018, 5:20:17 AM] [minh.nguyen]: hoặc là có thay đổi gem mà cần bundle lại
[9/28/2018, 5:20:24 AM] [minh.nguyen]: nhất là những gem có C extension
[9/28/2018, 5:20:37 AM] [minh.nguyen]: thì bời gian build có thể mất 5 - 15 phút
[9/28/2018, 5:20:53 AM] [minh.nguyen]: thì sẽ có down time
[9/28/2018, 5:23:14 AM] [// english-ignore]: vậy phải build ở local rồi rsync lên server à? hay có 1 server riêng chỉ để build rồi rsync qua prod servers?
[9/28/2018, 5:25:06 AM] [minh.nguyen]: mình chưa xài rsync :omg:
[9/28/2018, 5:25:19 AM] [minh.nguyen]: nhưng mà nói chung là phải build trước rồi đẩy lên
[9/28/2018, 5:25:48 AM] [// english-ignore]: nghe hơi ghê, tại lỡ máy dev với prod khác version chẳng hạn
[9/28/2018, 5:26:31 AM] [minh.nguyen]: thường bước build mình để ở CI, với config production
[9/28/2018, 5:27:05 AM] [// english-ignore]: à :thinkhard:
[9/28/2018, 5:54:10 AM] []: À context là Em chưa setup dc automation gì, mà đang viết 1 cái ko để local dc :(
[9/28/2018, 6:20:40 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: build ở server rồi sync quá chứ, ai lại build ở dev @kcj.pop.com_rbvn
[9/28/2018, 6:22:00 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: 1 node thì cứ cái nào tiện nhất thì làm, nhưng cũng nên pull, build rồi hãy sync qua
[9/28/2018, 6:22:22 AM] [// english-ignore]: Um thì vậy mới thấy lạ, nếu có một server để build rồi sync thì còn hiểu được
[9/28/2018, 6:23:44 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: cũng ko nhất thiết phải như vậy, nếu chỉ có 1 server thì dùng chính server chạy prod để build, nhưng build chỗ khác (khi mọi thứ đã ready) thì sync qua thôi
[9/28/2018, 6:51:52 AM] [linhnn]: tốt nhất là build trên một con riêng nhỉ, để lỡ con prod mà die thì mệt
[9/28/2018, 7:04:24 AM] [vthang]: Em cũng git pull đều tay :okay:
[9/29/2018, 7:41:38 AM] [minh.nguyen]: #til đặt debugger thì không nên đặt cuối method / proc. Vì sẽ làm thay đổi return value và debug sẽ thành ác mộng
[9/29/2018, 8:50:25 AM] [// english-ignore]: Nếu hàm không tự động return thì cũng không sao nhỉ
[9/29/2018, 9:03:16 AM] [minh.nguyen]: trong ruby là implicit return. Nên nếu ở chỗ gọi không xài thì không sao.
[9/29/2018, 12:12:57 PM] [// english-ignore]: Um làm nhớ y chang CoffeeScript
[9/30/2018, 7:07:01 AM] [quannt]: docker :thinkhard:
[9/30/2018, 8:38:32 PM] []: &gt; CoffeeScript is a programming language that transcompiles to JavaScript. It adds syntactic sugar inspired by *Ruby*, Python and Haskell in an effort to enhance JavaScript’s brevity and readability
Chắc là lụm của Ruby cái implicit return rồi :smile:
[9/30/2018, 11:24:13 PM] [// english-ignore]: Nó đó, syntax nhìn ra mùi Ruby mà
[9/30/2018, 11:24:26 PM] [// english-ignore]: Giờ hình như cũng chỉ còn mấy dự án Ruby xài XD
[10/1/2018, 12:27:26 AM] [Anh Xe Ôm]: #til package is lsb-release, commdand is lsb_release :oh:
[10/1/2018, 12:28:30 AM] [Cậu Làm Vườn]: Rails van con xai nhieu. Ma sau 5.0 thi do roi. Move sang xai ES6 voi webpack.
[10/1/2018, 12:38:32 AM] [hieu.huynh]: cùng thắc mắc, sao nào giờ thấy command có _ nhiều, mà ít thấy comand có -
[10/1/2018, 12:38:43 AM] [hieu.huynh]: coding standard chăng :doubt: ?
[10/1/2018, 12:41:57 AM] [Anh Xe Ôm]: đôi khi `-` bị sẽ bị nhầm lẫn thành subtract operator
[10/1/2018, 1:13:45 AM] [hieu.huynh]: mới nghĩ ra 1 idea là khó khăn khi parse command ra
[10/1/2018, 1:14:02 AM] [hieu.huynh]: vì `-` sẽ duplicate với arg
[10/1/2018, 1:14:18 AM] [hieu.huynh]: cơ mà nghĩ lại cơ chế bắt arg chỉ sau cái string `command`
[10/1/2018, 1:14:21 AM] [hieu.huynh]: nên thôi :byeanim:
[10/4/2018, 10:05:04 PM] [Anh Xe Ôm]: #til firebase has static hosting
[10/5/2018, 7:43:04 AM] [FULLCLEARONSTAGE]: #til currying is not partial application
[10/5/2018, 7:43:37 AM] [// english-ignore]: ^ how come? :think:
[10/5/2018, 7:53:17 AM] [FULLCLEARONSTAGE]: “Currying always produces nested unary (1-ary) functions. The transformed function is still largely the same as the original.”
“Partial application produces functions of arbitrary number of arguments. The transformed function is different from the original — it needs less arguments.”
[10/5/2018, 7:54:17 AM] [FULLCLEARONSTAGE]: `f(a)(b)(c)` and `f(a,b)(c)`
[10/5/2018, 8:02:47 AM] [// english-ignore]: trước giờ cứ nghĩ currying nó như subset của partial application, khi arity = 1 :thinkhard:
[10/8/2018, 10:04:40 PM] [hasagi]: #til function*, Promise.coroutine
[10/9/2018, 9:27:51 PM] [SFzxc]: #til Dockerfile Using a trick `ARG CACHEBUST=1` to disable cache for specific RUN commands
[10/10/2018, 11:17:30 PM] [anh bán chuối]: #til `<chrome://net-internals/> `
[10/11/2018, 1:26:42 AM] [Anh Xe Ôm]: #til yaml phức tạp hơn bạn tưởng nhiều, và Go yaml chưa implements đầy đủ
[10/11/2018, 1:42:39 AM] []: xml :omg:
[10/11/2018, 1:53:40 AM] [drake]: #til khi maintenance 1 feature khá cũ, có change base logic…hãy tách chúng ra và viết 1 version mới.
đừng edit code cũ.. :thinkcry:
[10/11/2018, 2:25:41 AM] [quannt]: 1st rule of refactor, don't :yaomin:
[10/11/2018, 2:26:19 AM] [quannt]: thuc ra la viet test truoc, roi hay refactor
[10/11/2018, 3:04:04 AM] [drake]: :think:
[10/12/2018, 4:02:45 AM] [SFzxc]: #til DOT language
[10/13/2018, 6:56:31 AM] [Anh Xe Ôm]: #til ip, dhcpd, netctl,... <https://wiki.archlinux.org/index.php/Network_configuration>
[10/13/2018, 8:16:44 AM] []: arch wiki is the best
[10/14/2018, 8:37:10 AM] [Anh Xe Ôm]: #til login steam via 1password: `steam -login duythinht "$(op get item steam | jq -r '.details.fields[0].value')"`
[10/14/2018, 8:17:09 PM] []: #til convergent evolution :thinkhard: <https://en.wikipedia.org/wiki/Cephalopod_eye#Convergent_evolution>
[10/16/2018, 11:15:04 PM] [unrealhoang]: #til drb <http://nithinbekal.com/posts/distributed-ruby/>
[10/16/2018, 11:48:33 PM] [anh bán chuối]: #til Chrome URLs <chrome://chrome-urls/>
[10/17/2018, 7:55:04 PM] [anh bán chuối]: #til conway’s game of life <https://youtu.be/C2vgICfQawE?t=72>
[10/18/2018, 12:37:30 AM] [anh bán chuối]: #til metacognition
&gt; awareness and understanding of one’s own thought processes.
[10/18/2018, 3:22:50 AM] []: javascript event propagation
[10/18/2018, 3:22:52 AM] []: <https://medium.freecodecamp.org/a-simplified-explanation-of-event-propagation-in-javascript-f9de7961a06e>
[10/18/2018, 3:23:16 AM] []: plus enzyme shallow simulate click k propagate
[10/18/2018, 5:48:06 AM] []: #til make incremental list in vim with `put = range()`
[10/18/2018, 7:47:52 PM] [quannt]: #til HTML `&lt;base&gt;`
[10/18/2018, 8:28:44 PM] [manhdv]: #til <https://computer.howstuffworks.com/c.htm>
[10/18/2018, 11:36:19 PM] []: #til make incremental list with formating in Vim with `:put = map(range(), 'printf(&lt;format&gt;)' )` :omg:
[10/20/2018, 9:29:47 AM] [// english-ignore]: #til cảm khác cúm
[10/20/2018, 9:55:39 AM] [SFzxc]: #til macro trong vim bá đạo quá :sexy:
[10/21/2018, 5:55:04 PM] [話せる森林]: Please tell me more detail. :disappointed:
[10/21/2018, 11:43:56 PM] [// english-ignore]: Cúm là cái này <https://en.wikipedia.org/wiki/Influenza.> Cảm có thể không chết nhưng cúm thì có thể. Và nên đi chích ngừa cúm hàng năm :-s
[10/21/2018, 11:49:57 PM] [// english-ignore]: <https://twitter.com/LVehlewald/status/1053298958494240772>
[10/22/2018, 3:21:52 AM] [typescriptpher]: #til Hyper-dual numbers <https://stacks.stanford.edu/file/druid:jw107zn5044/JeffFike_thesis_online_twosided-augmented.pdf>
[10/22/2018, 3:51:16 AM] [huynh.cam]: when I read this paper out loud, I created meaningless sounds
[10/22/2018, 3:51:31 AM] [typescriptpher]: = )))
[10/22/2018, 3:54:13 AM] [typescriptpher]: tl;dr là cái trò này dùng để tính vi phân tự động (automatic differentiation), mà cái này chính là để build mấy cái neural network đó
[10/22/2018, 3:54:44 AM] [typescriptpher]: có bài survey dễ đọc hơn <https://arxiv.org/pdf/1801.03614.pdf>
[10/22/2018, 7:28:05 AM] [hasagi]: .
[10/22/2018, 10:28:31 AM] [typescriptpher]: <https://github.com/tamnd/dual> ranh roi ko lam viec dc nghich chut /cc @hqc
[10/22/2018, 10:29:05 AM] [hasagi]: star roi nhe
[10/22/2018, 10:29:06 AM] [hasagi]: :3
[10/22/2018, 10:30:43 AM] [typescriptpher]: co' hieu no' la cai chi ko =))
[10/22/2018, 10:37:55 AM] [hasagi]: ko
[10/22/2018, 10:38:06 AM] [hasagi]: ko hieu moi star
[10/22/2018, 10:38:09 AM] [hasagi]: :3
[10/22/2018, 11:13:07 AM] [noob]: té ra bữa giờ có follow anh @eyeball à :33:
[10/22/2018, 11:14:16 AM] [huynh.cam]: vkl
[10/22/2018, 11:14:40 AM] [huynh.cam]: googling ...
[10/22/2018, 11:16:35 AM] [huynh.cam]: <https://en.wikipedia.org/wiki/Dual_number>
[10/22/2018, 8:45:00 PM] []: hơi hơi, ứng dụng là gì vậy anh :omg:
[10/22/2018, 9:16:52 PM] [typescriptpher]: ứng dụng để tính vi phân tự động (automatic differentiation), mà cái này là xài vào neural network <https://people.cs.umass.edu/~domke/courses/sml2010/07autodiff_nnets.pdf>
[10/24/2018, 11:42:05 PM] [// english-ignore]: #til dangling participles <https://www.thoughtco.com/what-is-a-dangling-participle-1857150>
[10/25/2018, 1:17:39 AM] [alias Trung.Le, as tle]: #til macOS High Sierra change behaviour of fork() which causes issues with unicorn, workaround is documented in <https://bogomips.org/unicorn-public/20170804191023.GA28511@dcvr/T/>
[10/25/2018, 1:24:22 AM] [alias Trung.Le, as tle]: #til `SchedulingStrategy = DAEMON` of AWS ECS would place the docker container task on every ECS Cluster Instance
[10/25/2018, 8:17:09 AM] [anh bán chuối]: #til <https://robots.thoughtbot.com/announcing-upcase-is-free>
[10/27/2018, 5:02:16 AM] [typescriptpher]: #til Các bạn Tàu giỏi quá T__T :adore:
[10/27/2018, 5:53:34 AM] [Anh Xe Ôm]: @hqc nói bạn kìa
[10/27/2018, 6:04:00 AM] [vthang]: Anh @hqc trước học hay làm bên tàu à. :adore:
[10/27/2018, 6:23:41 AM] [huynh.cam]: Ông cố mình hồi đó đẻ ở Tàu
[10/27/2018, 7:40:18 AM] []: #til <https://youtu.be/rNQdSfgJDNM>
[10/27/2018, 7:41:55 AM] [anh bán chuối]: #til <http://readline.kablamo.org/emacs.html>
[10/27/2018, 7:11:18 PM] [typescriptpher]: #til Python naming guide `module_name, package_name, ClassName, method_name, ExceptionName, function_name, GLOBAL_CONSTANT_NAME, global_var_name, instance_var_name, function_parameter_name, local_var_name`
[10/28/2018, 9:06:13 PM] [anh bán chuối]: #til windmap <https://earth.nullschool.net/#current/wind/surface/level/orthographic=-234.47,2.46,874/loc=104.250,0.910>
[10/28/2018, 11:21:36 PM] [hieu.huynh]: #til <https://en.wikipedia.org/wiki/Chroot>
hmmm :neutral_face:
[10/28/2018, 11:22:21 PM] [anh bán chuối]: :omg: omg omg
[10/28/2018, 11:25:23 PM] []: :think:
[10/28/2018, 11:33:19 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: are you kidding me? :neutral_face: u don’t know `chroot`? :surrender:
[10/28/2018, 11:37:05 PM] [hieu.huynh]: dạ, nào giờ không biết :sosad:
[10/28/2018, 11:38:13 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :neutral_face: lạy, làm linux mà ko biết chroot :neutral_face: cài Arch mà ko biết chroot, tooling engineer cmnr
[10/28/2018, 11:38:25 PM] [hieu.huynh]: mới biết hôm qua, vì đang vọc cái debian trên con android cũ
dùng debootstrap để export debian ra, sau đó chroot vào để init filesystem
[10/28/2018, 11:41:00 PM] [hieu.huynh]: em chưa cài arch :think: debian is king
[10/28/2018, 11:43:02 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :arggg: lạy
[10/29/2018, 8:54:44 PM] [typescriptpher]: #til Nodejs is awesome!
[10/29/2018, 8:55:20 PM] [huy]: :pac:
[10/29/2018, 8:55:41 PM] []: :facepalmanim:
[10/29/2018, 8:58:00 PM] [hieu.huynh]: #til <https://mysqlhighavailability.com/performance-improvements-in-mysql-8-0-replication/>
có thêm 2 cái improvements quan trọng:
- <https://dev.mysql.com/worklog/task/?id=7374>
- <https://dev.mysql.com/worklog/task/?id=8599>
[10/29/2018, 9:00:38 PM] []: :clap:
[10/29/2018, 9:59:26 PM] [hasagi]: NodeJS xịn quá
[10/29/2018, 9:59:30 PM] [hasagi]: discard Go
[10/29/2018, 9:59:31 PM] [hasagi]: hail Node
[10/30/2018, 12:17:23 AM] [Anh Xe Ôm]: all hail nodejs
[10/30/2018, 12:17:26 AM] [Anh Xe Ôm]: :"&gt;
[10/30/2018, 8:39:12 PM] [minh.nguyen]: #til `:qa` to close all in vim :beat_brick:
[10/30/2018, 8:49:25 PM] [Cậu Làm Vườn]: vậy đó giờ close từng cái à
[10/30/2018, 8:49:32 PM] [Cậu Làm Vườn]: :omg:
[10/30/2018, 8:50:31 PM] []: Dùng buffer nên `:q!` phát nó close luôn vim :omg:
[10/30/2018, 8:57:25 PM] [minh.nguyen]: chính xác :omg:
[10/30/2018, 8:57:55 PM] []: `:q :q :q :q :q ... ` :troll:
[10/30/2018, 9:01:19 PM] [Anh Xe Ôm]: `qq qq qq qq qq` :pikatroll:
[10/30/2018, 9:11:20 PM] [minh.nguyen]: chuẩn :beat_brick:
[10/30/2018, 9:15:17 PM] [SFzxc]: binh thuong dùng mỗi `:q!` nên nó vẫn còn cái nerdtree :omg: đóng thêm phát nữa
[11/1/2018, 9:23:47 PM] [hasagi]: `Ctrl W`
[11/2/2018, 6:33:14 AM] []: #til some basic sed
[11/2/2018, 9:09:49 AM] [hasagi]: ý là cách quit all in vim
[11/4/2018, 2:37:32 AM] [huynh.cam]: #til preface `PRI SM` của HTTP/2 là để gợi nhớ <https://en.wikipedia.org/wiki/PRISM_(surveillance_program)>
[11/6/2018, 2:29:38 AM] [typescriptpher]: #til <https://en.wikipedia.org/wiki/Ogham>
[11/6/2018, 3:20:48 AM] [typescriptpher]: #til 64 bit Erlang is slower than 32 bit Erlang
[11/6/2018, 4:41:11 AM] []: Có lý do cụ thể gì không anh
[11/6/2018, 6:27:54 AM] [typescriptpher]: &gt; This is because of almost twice as much memory used in the 64 bit version. And this is because most of the data contains pointers.
[11/7/2018, 12:00:21 AM] [hieu.huynh]: #til Critical thinking: `It's true because I believe it`
```
(innate egocentrism: in which case I find myself continually assuming that what I believe is true even though I have never questioned the basis for many of my beliefs)
```
:okay:
[11/7/2018, 2:12:24 AM] [ledongthuc]: #til street, road, way, avenue, boulevard, land, drive, terrace, place, court
[11/7/2018, 2:12:29 AM] [ledongthuc]: <https://lifehacker.com/the-difference-between-streets-boulevards-avenues-an-1789115850>
[11/7/2018, 3:08:37 AM] [typescriptpher]: @.@
[11/7/2018, 9:52:06 AM] [tanlinhnd]: #til ```
nice is used to invoke a utility or shell script with a particular priority, thus giving the process more or less CPU time than other processes. A niceness of −20 is the highest priority and 19 is the lowest priority. The default niceness for processes is inherited from its parent process and is usually 0.
```
<https://en.wikipedia.org/wiki/Nice_(Unix)>
[11/7/2018, 10:06:46 AM] [huynh.cam]: thế còn đường, hẻm, phố, ngõ, ngách thì sao :troll:?
[11/7/2018, 5:42:02 PM] [typescriptpher]: #til Mắt biếc là truyện chú nuôi hay nhất mọi thời đại
[11/7/2018, 5:50:51 PM] [ledongthuc]: hình như hẻm với ngõ nó tính là lane
ngách thì nó tính là alley
:)) thấy dịch ra lane là đường nhỏ, alley = lane nhỏ
[11/7/2018, 5:52:22 PM] [ledongthuc]: phố hình như là kiểu tên của 1 khu nhà đúng ko nhỉ? hình như gọi là quarter
[11/7/2018, 5:52:58 PM] [ledongthuc]: :pac: hôm qua điền cái form có address nó tách rara từng phần nhỏ, làm tìm muốn chết
[11/7/2018, 5:54:50 PM] [typescriptpher]: cái form của apple nó còn limit số kí tự, max stupid...
[11/7/2018, 8:04:39 PM] []: #til Vim use `:g/&lt;regexp&gt;/&lt;command&gt;` to execute command on regex matchs
[11/7/2018, 8:25:28 PM] []: #til nhiều lúc viết vim command dài tới mức muốn dùng vim để edit command thì vô `q:` cho Vim's command line mode =)))
[11/7/2018, 8:33:23 PM] []: :omg: đồng đạo đây rồi
[11/7/2018, 8:34:27 PM] [unrealhoang]: cái `:g` thường dùng để xoá matched lines
[11/7/2018, 8:34:30 PM] [unrealhoang]: :adore:
[11/7/2018, 8:35:07 PM] []: em vừa dùng để cứ 10 dòng thì insert 1 dòng trắng =)))))
[11/7/2018, 8:36:30 PM] [unrealhoang]: ngon, post command lên cho mọi người học hỏi bằng example luôn
[11/7/2018, 8:36:31 PM] [unrealhoang]: :adore:
[11/7/2018, 8:38:44 PM] []: ý lộn cái đó là `:s/\(.*\n\)\{10\}/\0\r/g` còn cái `:g/^/m0` vừa dùng để reverse line order :roflrofl:
[11/7/2018, 8:46:35 PM] [unrealhoang]: vim so advance, vim masterace
[11/7/2018, 8:46:40 PM] [unrealhoang]: :roflrofl:
[11/7/2018, 8:52:55 PM] []: real man use Vim :roflrofl:
[11/8/2018, 7:02:53 PM] [chua dc luong thien]: #til Trello using Node, Mongo in production
[11/9/2018, 2:41:33 AM] [huynh.cam]: #til nấu mì Ý phải xoay
[11/9/2018, 2:50:39 AM] [// english-ignore]: #yil organize imports trong VSCode
[11/9/2018, 3:03:12 AM] [Cậu Làm Vườn]: ^ cho xin thêm miếng info anh
[11/9/2018, 3:04:40 AM] [// english-ignore]: Nó tự động sắp xếp lại import theo thứ tự ABC các kiểu :-?
[11/9/2018, 3:04:55 AM] [// english-ignore]: Satisfied my OCD
[11/9/2018, 3:07:20 AM] [Cậu Làm Vườn]: rồi, em cũng chưa biết luôn
[11/9/2018, 3:07:26 AM] [Cậu Làm Vườn]: steps plz :adorable:
[11/9/2018, 3:07:54 AM] [// english-ignore]: chờ chút
[11/9/2018, 5:28:44 AM] []: thế trước giờ anh nấu sao
[11/9/2018, 5:29:16 AM] [// english-ignore]: #til trong mac có option để capture vô clipboard :thinkcry:
[11/9/2018, 5:37:15 AM] [huynh.cam]: cầm nguyên nắm bỏ đại vào nồi nước sôi :disappointed:
[11/9/2018, 5:37:48 AM] [// english-ignore]: vậy xoay là sao? :neutral_face:
[11/9/2018, 5:38:50 AM] [huynh.cam]: <https://youtu.be/D_2DBLAt57c?t=65>
[11/9/2018, 5:39:13 AM] [huynh.cam]: cc @mquy
[11/9/2018, 5:39:53 AM] [huynh.cam]: thật ra ko xoay thì cũng dc
[11/9/2018, 5:40:07 AM] [huynh.cam]: cơ mà nó dễ bị dính một cục
[11/9/2018, 5:40:49 AM] [noob]: thứ 2 đi ăn đồ ziệt lào
[11/9/2018, 5:41:28 AM] [huynh.cam]: thánh mquy toàn rủ đi ăn đồ việt :neutral_face:
[11/9/2018, 5:42:13 AM] [huynh.cam]: trời ơi nhìn dĩa pasta ngon quá
[11/9/2018, 5:42:29 AM] [// english-ignore]: miềng nấu hay bỏ miếng dầu vô :-?
[11/9/2018, 5:42:29 AM] [huynh.cam]: Jamie dạy nấu mà passionate vãi :adore:
[11/9/2018, 5:42:58 AM] [huynh.cam]: bỏ dầu sẽ bị vấn đề là lúc serve
[11/9/2018, 5:43:08 AM] [huynh.cam]: mì với sốt bị tách rời
[11/9/2018, 5:43:58 AM] [huynh.cam]: tụi Tây nghiên cứu ra mấy cái pasta có khóe, răng cưa là để dính sốt càng nhiều càng tốt đó
[11/9/2018, 5:44:13 AM] [// english-ignore]: :thinkhard:
[11/9/2018, 5:45:02 AM] [noob]: giờ có mẹ nên khỏe, đợt sau tự nấu căng rồi đây
[11/9/2018, 5:45:46 AM] [huynh.cam]: lớn rồi, nấu cho mẹ ăn đê
[11/9/2018, 5:46:06 AM] [// english-ignore]: rước má nhỏ qua
[11/9/2018, 5:57:33 AM] [noob]: đứng nhắc thêm buồn :okay:
[11/9/2018, 8:08:55 AM] [huy]: Kiếm má nhỏ nào ở bển cũng đc
[11/10/2018, 5:20:54 AM] []: #til <https://matplotlib.org> :thinkhard:
[11/11/2018, 6:11:15 AM] [Cậu Làm Vườn]: #til SQL is pronounced that way because its original name is actually SEQUEL - Structured English Query Language :ie:
[11/11/2018, 7:19:28 AM] [// english-ignore]: Hình như không có cách đọc chính thức mừ :smiley:
[11/11/2018, 7:22:29 AM] [Cậu Làm Vườn]: ý là một cách đọc
[11/11/2018, 7:22:49 AM] [Cậu Làm Vườn]: sí quô vs ét qui eo
[11/11/2018, 7:23:02 AM] [Cậu Làm Vườn]: trước giờ không biết sao SQL đọc ra sí qô được
[11/11/2018, 7:23:06 AM] [Cậu Làm Vườn]: :roflrofl:
[11/11/2018, 7:23:11 AM] [huynh.cam]: Cool :+1:
[11/11/2018, 7:24:17 AM] [Cậu Làm Vườn]: Hay thiệt anh ơi, em mới xong lecture 2 :adorable:
[11/11/2018, 7:30:18 AM] [// english-ignore]: :thumbsup:
[11/11/2018, 7:35:59 AM] [vthang]: Lecture ở course nào vậy a @harrisnguyen
[11/11/2018, 7:37:01 AM] [Cậu Làm Vườn]: Mại dô! Có homework nữa :adorable:
<https://www.youtube.com/playlist?list=PLSE8ODhjZXja3hgmuwhf89qboV1kOxMx7>
[11/11/2018, 7:38:13 AM] [Cậu Làm Vườn]: Luyện xong làm bài tập để tu thành chánh quả.
[11/11/2018, 7:40:31 AM] [vthang]: Oh xịn quá :stuck_out_tongue:
[11/11/2018, 7:44:32 AM] [huynh.cam]: Bài tập trả 800usd mới access dc e ơi :(
[11/11/2018, 7:46:20 AM] [vthang]: :oh:
[11/11/2018, 7:46:46 AM] [Cậu Làm Vườn]: Em thấy cho coi với cho down dataset của mấy cái homework đầu
<https://15445.courses.cs.cmu.edu/fall2018/assignments.html>
[11/11/2018, 7:48:04 AM] [Cậu Làm Vườn]: Mấy cái project em skim qua hình như cũng xem được.
[11/11/2018, 5:18:07 PM] [alias Trung.Le, as tle]: #til AWS ECS service can be run as DAEMON mode which would spawn service for every ECS cluster instance
[11/12/2018, 3:29:40 AM] [話せる森林]: #til Cho một ít muối đảo qua vào chảo chiên sẽ giúp đồ ăn không bị dính chảo tuy nhiên bù lại là đồ chiên sẽ hơi bị khô và không có độ mềm. Giải pháp là căn lượng muối vừa phải cộng với thêm một chút dầu nóng khi gần chiên xong.
<#C16AY670U|til> Để một ít giấy vệ sinh phủ mỏng lên phần nước của bồn cầu sẽ giúp cho dị vật khi rơi không làm bắn nước ướt mông.
[11/12/2018, 3:30:17 AM] [// english-ignore]: dị vật :omg:
[11/12/2018, 3:30:38 AM] [話せる森林]: Chẳng lẽ lại gọi nó là cục... thì thô quá
[11/12/2018, 3:31:17 AM] [// english-ignore]: thanks for the tip anyway :sweat_smile:
[11/12/2018, 3:31:36 AM] [__.__Sectumsempra__.__]: <https://forums.voz.vn/showthread.php?t=7431858> `Trước khi đi wc thả ít bột xả phòng hoặc nước giặt hoặc bột tạo bọt vào bồn cầu. Sau đó dùng cái vòi xịt vào cho nó xù bọt lên. Đi vừa k bị bắn vừa k có mùi vào phòng.`
[11/12/2018, 9:50:17 AM] [Anh Xe Ôm]: Thật là sâu sắc
[11/12/2018, 12:39:01 PM] [huynh.cam]: tổ cha ông thầy, thường mình coi 1.5 speed cho nhanh
[11/12/2018, 12:39:25 PM] [huynh.cam]: ông này nói 1.0 như đọc rap rồi
[11/12/2018, 6:49:12 PM] [Cậu Làm Vườn]: :roflrofl: Em đã chấp nhận 1.25x, y như coi 1.5 hay 2x bình thường.
[11/12/2018, 6:49:35 PM] [Cậu Làm Vườn]: Cái đó người ta gọi là vừa passionate, vựa bị cháy giáo án.
[11/12/2018, 11:43:22 PM] []: #til rails migration class method se tro thanh instance method khi chay migration
[11/13/2018, 12:05:27 AM] [meowwwwwwwwwwwwwwww]: Kinh nghiệm là viết trong một module
```
module ImportTestData
extend Rake::DSL
extend self
namespace :xxx do
task :xxx do
end
end
end
```
[11/13/2018, 1:28:15 PM] [huy]: #til React xài `requestAnimationFrame` để update render cycle, nhưng rAF sẽ không chạy nếu tab nằm ở background, React team sử dụng cách fallback về `setTimeout` để update, như thế dù tab đang inactive trong background thì nó vẫn render (mặc dù setTimeout vẫn bị throttle) :thinkhard:
[11/13/2018, 2:16:59 PM] [noob]: trước giờ chưa nghe React sử dụng `rAF` bao giờ :thinkhard:
[11/13/2018, 2:31:17 PM] [huy]: <https://github.com/facebook/react/blob/e2e7cb9f4cb3b415775688fb118846a9927acaf3/packages/scheduler/src/Scheduler.js#L402>
[11/13/2018, 2:31:19 PM] [huy]: here you go
[11/13/2018, 2:32:26 PM] [huy]: <https://github.com/facebook/react/blob/c7ce0091dcb2036e19df980247c9a4388ad75741/packages/shared/ReactDOMFrameScheduling.js>
[11/13/2018, 4:02:10 PM] [typescriptpher]: kết hợp với Electron với 1 đống gif động nữa thì quá tuyệt vời, cho dù chạy background nó vẫn ăn pin và CPU như thường?
[11/13/2018, 4:02:35 PM] [huy]: em không biết :omg: nhưng nếu đúng vậy thì đúng vậy
[11/13/2018, 4:06:57 PM] [typescriptpher]: thiệt là vi diệu :)))
[11/13/2018, 4:15:55 PM] [huy]: đó là cái e hiểu khi đọc cái này
[11/13/2018, 4:15:57 PM] [huy]: ```
// requestAnimationFrame does not run when the tab is in the background. If
// we're backgrounded we prefer for that work to happen so that the page
// continues to load in the background. So we also schedule a 'setTimeout' as
// a fallback.
```
[11/13/2018, 4:16:01 PM] [huy]: không biết đúng ko :thinkhard:
[11/13/2018, 4:39:32 PM] [typescriptpher]: ở dưới code thì sao em, document là cái thứ ko đáng tin :roflrofl:
[11/13/2018, 4:39:52 PM] [typescriptpher]: code react toàn hack với hack nên anh ko đọc bao h, phí time lắm
[11/13/2018, 4:42:00 PM] [huy]: cái scheduler kia nó viết có vẻ hơi generic, điểm cuối của cái module này là bind vào một cái event tên là `message`
[11/13/2018, 4:42:05 PM] [huy]: nên e chưa coi kĩ đc nó dùng như nào
[11/13/2018, 4:50:00 PM] [huy]: có vẻ như nó ko dùng để schedule render
[11/13/2018, 5:50:26 PM] [tay vịn của anh bán chuối - cty A tìm FE]: Nó dùng để schedule fiber work unit á
[11/13/2018, 5:50:55 PM] [tay vịn của anh bán chuối - cty A tìm FE]: Em chưa coi nó có schedule luôn phần render ko
[11/13/2018, 5:51:06 PM] [huy]: mới coi lướt qua có vẻ như ko
[11/13/2018, 5:51:13 PM] [huy]: nhưng có schedule effect đồ
[11/13/2018, 5:51:25 PM] [huy]: thấy mấy cái hooks nó nằm khắp mọi nơi trong codebase
[11/13/2018, 5:51:28 PM] [huy]: kinh
[11/13/2018, 5:51:28 PM] [tay vịn của anh bán chuối - cty A tìm FE]: Scheduler viết generic vì muốn share với third party lib mà
[11/13/2018, 5:52:04 PM] [tay vịn của anh bán chuối - cty A tìm FE]: Ultimate goal là làm việc với chrome team thêm scheduler vào browser
[11/13/2018, 5:52:04 PM] [huy]: uhm
[11/13/2018, 5:52:12 PM] [huy]: :scream:
[11/13/2018, 5:52:21 PM] [tay vịn của anh bán chuối - cty A tìm FE]: Thím check cái chrome dev summit đi
[11/13/2018, 5:52:56 PM] [tay vịn của anh bán chuối - cty A tìm FE]: Đó lad thông tin em hóng được trên podcast
[11/13/2018, 5:53:15 PM] [huy]: mới lướt trên đó, toàn polymer :disappointed:
[11/13/2018, 6:49:17 PM] []: #til <https://github.com/nicohaenggi/SafariBooks-Downloader>
[11/13/2018, 7:03:02 PM] [typescriptpher]: #til <http://www.open-std.org/jtc1/sc22/wg14/www/docs/n2310.pdf> who said C is simple?
[11/13/2018, 7:03:27 PM] [unrealhoang]: said no one ever :roflrofl:
[11/13/2018, 7:04:32 PM] [typescriptpher]: :roflrofl:
[11/13/2018, 7:05:01 PM] [typescriptpher]: C2x đó, có bài này tổng kết mấy cái mới: <https://gustedt.wordpress.com/2018/11/12/c2x/>
[11/13/2018, 8:47:57 PM] [dan]: #til srcset
[11/13/2018, 9:07:48 PM] [Cậu Làm Vườn]: Loading image is hard :thinkcry:
[11/13/2018, 9:07:51 PM] [Cậu Làm Vườn]: <https://cloudfour.com/thinks/responsive-images-101-definitions/>
[11/13/2018, 9:08:02 PM] [Cậu Làm Vườn]: ^ great series
[11/13/2018, 9:15:10 PM] [alias Trung.Le, as tle]: indeed ^
[11/13/2018, 9:27:41 PM] [alias Trung.Le, as tle]: #til the art of reviewing work of someone's is to turn your comment from a statement to a question. Question their intent, question why they decide to do things that you consider a bad code.
[11/13/2018, 10:06:36 PM] [// english-ignore]: Tuần trước em mới lên máu vì bị quăng cả lô questions vô mặt :stuck_out_tongue:
[11/14/2018, 12:46:27 AM] [noob]: vụ này có biết, code trên chỉ để làm polyfill trong trường hợp ko có requestIdleCallback thôi, mục đích của nó là sử dụng requestIdleCallback kìa
[11/14/2018, 1:16:58 AM] [meowwwwwwwwwwwwwwww]: #til Rails encodes BigDecimal as String
<https://github.com/rails/rails/pull/12183/commits/4d02296cfbd69b4d2757dfd20f23d778bb23b81b>
[11/14/2018, 1:26:07 AM] [huynh.cam]: :oh:
[11/14/2018, 1:48:32 AM] [minh.nguyen]: ```
ActiveSupport.encode_big_decimal_as_string = true```
[11/14/2018, 1:48:37 AM] [minh.nguyen]: bật cái này mới có mà
[11/14/2018, 1:52:14 AM] [huynh.cam]: commit này đổi lại thành `finite?` rồi mà
[11/14/2018, 1:57:55 AM] [meowwwwwwwwwwwwwwww]: ```
[11] pry(main)&gt; BigDecimal.new("1.23456789").to_json
=&gt; "\"1.23456789\""
```
[11/14/2018, 2:04:45 AM] []: :open_mouth:
[11/15/2018, 11:50:09 AM] [huy]: #til `git diff` hoạt động đc với mọi thể loại file, ngay cả khi ko nằm trong git workspace
[11/15/2018, 11:50:22 AM] [huy]: #til `git diff --word-diff --color | diff-highlight`
[11/15/2018, 4:37:42 PM] [typescriptpher]: <https://fabiensanglard.net/git_code_review/diff.php>
[11/15/2018, 4:37:56 PM] [typescriptpher]: fyi nếu muốn tìm hiểu algo về diff
[11/15/2018, 4:41:05 PM] [huy]: e bookmark cái này cũng vài năm trước rồi
[11/15/2018, 4:41:08 PM] [huy]: mà chưa đọc
[11/15/2018, 4:41:09 PM] [huy]: :omg:
[11/15/2018, 4:51:34 PM] [typescriptpher]: "bookmark" sẽ cho người ta cảm giác done roài, ko cần đocj nữa :roflrofl:
[11/15/2018, 4:51:58 PM] [typescriptpher]: cái getpocket với twitter của anh là tool cho việc đó =))
[11/15/2018, 4:52:21 PM] [huy]: =)))
[11/15/2018, 4:52:31 PM] [huy]: giờ trong pocket e có từa lưa bài
[11/15/2018, 4:52:34 PM] [huy]: ko đọc nổi luôn
[11/15/2018, 4:52:35 PM] [huy]: :))
[11/15/2018, 4:59:45 PM] [typescriptpher]: ko sort dc theo số lần bookmark nhỉ, cái nào bookmark 10 lần thì đọc =))
[11/15/2018, 5:06:53 PM] [huy]: :))
[11/15/2018, 5:06:57 PM] [huy]: ý tởng hay đó
[11/15/2018, 5:07:03 PM] [huy]: tự build 1 cái pocket clone
[11/15/2018, 5:07:08 PM] [huy]: priority theo số lần bookmark
[11/15/2018, 5:07:13 PM] [huy]: *số lần duplicate
[11/15/2018, 5:07:15 PM] [huy]: :roflrofl:
[11/15/2018, 5:42:59 PM] [話せる森林]: #til console của chrome đã có chức năng tính toán realtime. Nghĩa là không cần phải enter nữa cũng hiện sẵn luôn kết quả bên dưới.
[11/15/2018, 5:43:47 PM] [unrealhoang]: Vậy gọi hàm gì đó có side effect thì sao?
[11/15/2018, 5:44:45 PM] [話せる森林]: Nó chỉ ra như thế này thôi. Chứ viết sai cũng không hiện kết quá.
[11/15/2018, 5:45:11 PM] [話せる森林]: #til Đã có thể gửi được ảnh vào trong comment thread của slack.
[11/15/2018, 5:45:32 PM] [unrealhoang]: Đang hỏi về side effect mà
[11/15/2018, 5:45:47 PM] [tay vịn của anh bán chuối - cty A tìm FE]: Thì nó thực hiện lại side effect đó @unstoppable30121997
[11/15/2018, 5:46:01 PM] [tay vịn của anh bán chuối - cty A tìm FE]: Lol tah nhầm
[11/15/2018, 5:46:07 PM] [話せる森林]: Tôi chưa thử nên không biết
[11/15/2018, 5:46:29 PM] [unrealhoang]: Thực thi luôn side effect à
[11/15/2018, 5:46:29 PM] [話せる森林]: Mà @nhducit làm sao viết được cái mờ mờ gì đó đằng sau vậy?
[11/15/2018, 5:46:32 PM] [tay vịn của anh bán chuối - cty A tìm FE]: Gõ thử console.log(new Date())
[11/15/2018, 5:47:20 PM] [tay vịn của anh bán chuối - cty A tìm FE]: Em có biết đâu. Trên phone em ko có hiện
[11/15/2018, 5:48:05 PM] [話せる森林]: Ơ đúng nhỉ new Date() là nó lấy luôn kết quả trả về tại thời điểm kết thúc việc truyền vào kí tự `)`. Các bạn GG thật hịn.
[11/15/2018, 7:48:27 PM] [typescriptpher]: #til Register transfer language <https://gcc.gnu.org/onlinedocs/gccint/RTL.html>
[11/16/2018, 10:09:37 PM] [minh.nguyen]: #til &gt; The results came to an estimated total value for the Linux kernel version 2.6.30 (released in December 2009) of 1,025,553,430 euros
[11/17/2018, 8:47:15 AM] [typescriptpher]: #til Point-free style programming <https://en.wikipedia.org/wiki/Tacit_programming>
[11/17/2018, 8:56:09 AM] []: haskell hay có mấy người lạm dụng cái này lắm
[11/17/2018, 9:54:21 AM] [noob]: khổ một cái là một cái style guide nó toàn hướng đến cái này :vayvay:
[11/17/2018, 7:20:37 PM] [typescriptpher]: #til Erlang Abstract Format <http://erlang.org/doc/apps/erts/absform.html>
[11/19/2018, 1:26:06 AM] [hasagi]: #til async waterfall
[11/19/2018, 3:58:32 AM] [tay vịn của anh bán chuối - cty A tìm FE]: JS async ah :thinking_face:
[11/19/2018, 5:14:13 PM] []: #til <http://plantuml.com/> &amp; <https://www.planttext.com/>
[11/19/2018, 5:27:14 PM] [hasagi]: Nó đo
[11/19/2018, 5:30:33 PM] [tay vịn của anh bán chuối - cty A tìm FE]: Default làm gì có waterfall function nhỉ. Nếu xài caolan async thì có
[11/19/2018, 5:39:52 PM] [hasagi]: Đích thị là caolan đó, parallel series waterfall =))
[11/19/2018, 6:01:43 PM] []: Say goodbye to <http://draw.io|draw.io>
[11/19/2018, 7:38:45 PM] [alias Trung.Le, as tle]: #til SQL with ES <https://www.elastic.co/elasticon/conf/2018/sf/elasticsearch-sql>
[11/19/2018, 8:28:04 PM] [typescriptpher]: single threaded concurrency :roflrofl:
[11/19/2018, 8:28:36 PM] [typescriptpher]: klq nhưng đang đọc processes + agent trong Erlang, phê vcl :roflrofl:
[11/19/2018, 8:29:24 PM] [tay vịn của anh bán chuối - cty A tìm FE]: nếu là call nhiều request thì cái này xài cũng ok mà anh :thinking_face:
[11/19/2018, 9:02:53 PM] [dan]: how about <https://dbdiagram.io/> :vayvay:
[11/20/2018, 2:02:42 AM] [typescriptpher]: #til Gimple <https://www.cse.iitb.ac.in/grc/gcc-workshop-09/downloads/gccw09-gimple.pdf>
[11/20/2018, 2:02:59 AM] [typescriptpher]: <https://www.youtube.com/watch?v=Tlr_mIZ82-U>
[11/20/2018, 2:03:53 AM] [typescriptpher]: <https://gcc-python-plugin.readthedocs.io/en/latest/gcc-overview.html>
[11/20/2018, 2:05:06 AM] [typescriptpher]: <https://www.airs.com/dnovillo/200711-GCC-Internals/200711-GCC-Internals-3-IR.pdf>
[11/20/2018, 10:10:02 PM] [meowwwwwwwwwwwwwwww]: #til <https://ux.stackexchange.com/>
[11/20/2018, 10:11:15 PM] [話せる森林]: #til Github giờ xịn xò quá.
[11/21/2018, 2:16:59 AM] [ko luong thien]: toàn code không review đồng đội..
[11/21/2018, 3:01:56 AM] [話せる森林]: Đâu có quyền review đâu
[11/21/2018, 3:25:28 AM] [ko luong thien]: nghe có vẻ phân biệt engineer :think:
[11/21/2018, 3:28:14 AM] [ko luong thien]: AND IT'S CROSS BROWSER!
[11/21/2018, 3:28:23 AM] [ko luong thien]: AND IT'S BEEN SUPPORTED SINCE 200X
[11/21/2018, 4:07:23 AM] [// english-ignore]: :thinkhard:
[11/21/2018, 4:08:18 AM] [dat]: dung hom nay em cung gap cai nay :))
[11/21/2018, 4:08:55 AM] [ko luong thien]: gặp cái pdf hay gặp cái embed?
[11/21/2018, 4:17:18 AM] [dat]: embed
[11/21/2018, 4:17:36 AM] [ko luong thien]: wy u tho
[11/21/2018, 4:17:53 AM] [dat]: phai sign mot van ban digitally :))
[11/21/2018, 4:18:39 AM] [ko luong thien]: wait a minute how?
[11/21/2018, 4:19:03 AM] [ko luong thien]: làm sao cái app sign nó work với cái embed được nhỉ
[11/21/2018, 4:34:49 AM] [dat]: no idea
[11/21/2018, 4:35:02 AM] [dat]: :fast-omg:
[11/21/2018, 6:40:08 AM] [tay vịn của anh bán chuối - cty A tìm FE]: Anh đoán nhé. App sign nó dùng canvas đè lên cái document để người dùng sign
[11/21/2018, 6:40:24 AM] [tay vịn của anh bán chuối - cty A tìm FE]: Canvas để capture signature
[11/21/2018, 6:41:36 AM] [tay vịn của anh bán chuối - cty A tìm FE]: Sau đó dùng phần mêm edit pdf để add signature vào pdf document
[11/21/2018, 6:58:02 AM] [ko luong thien]: Khó.. ví dụ có 2 trang đi, làm sao anh biết nó đang ở trang nào để apply cái signature vào
[11/21/2018, 6:58:10 AM] [ko luong thien]: Hoặc ví dụ nó đang zoom
[11/21/2018, 6:58:45 AM] [ko luong thien]: Em chưa tìm ra cách nào để bên ngoài có thông tin đó từ cái embed được
[11/21/2018, 7:01:04 AM] [ko luong thien]: @taurandat cho anh tên cái app với
[11/21/2018, 8:07:03 AM] [dat]: bamboohr
[11/21/2018, 8:07:16 AM] [dat]: co mot cai document, xong em phai sign len do
[11/21/2018, 8:07:31 AM] [dat]: sign o cuoi document
[11/21/2018, 8:26:22 AM] [tay vịn của anh bán chuối - cty A tìm FE]: yay, anh chỉ đoán mò thôi, đúng là cách giả định của anh có chỗ hổng là mình không biết được vị trí của current page/position của chỗ cần sign strong pdf file
[11/21/2018, 8:26:43 AM] [tay vịn của anh bán chuối - cty A tìm FE]: hồi trước anh cũng có ký vài lần mà không nhớ cái link đề vào xem lại
[11/21/2018, 8:43:30 AM] [tay vịn của anh bán chuối - cty A tìm FE]: <https://mozilla.github.io/pdf.js/examples/index.html#interactive-examples>
[11/21/2018, 8:43:46 AM] [tay vịn của anh bán chuối - cty A tìm FE]: dùng pdf.js thì mình có nhiều info từ pdf document hơn
[11/21/2018, 8:44:31 AM] [tay vịn của anh bán chuối - cty A tìm FE]: search thử thì chưa thấy api support để detect vùng signature cả
[11/21/2018, 9:04:34 AM] [ko luong thien]: Pdfjs thì có á :))
[11/21/2018, 9:04:45 AM] [ko luong thien]: Bên tụi em dùng nó vì cần tương tác sâu với document
[11/21/2018, 9:05:05 AM] [ko luong thien]: Chi tiết thì google anduin career
[11/21/2018, 9:09:00 AM] [dat]: HR in 2018
[11/21/2018, 9:09:07 AM] [dat]: 1: post a technical finding
[11/21/2018, 9:09:12 AM] [dat]: 2: raise a discussion
[11/21/2018, 9:09:25 AM] [dat]: 3: kindly invite them to ur company
[11/21/2018, 9:21:53 AM] [ko luong thien]: Nghe hợp lí vl nhỉ :thinking_face:
[11/21/2018, 9:44:36 AM] [tay vịn của anh bán chuối - cty A tìm FE]: lol
[11/21/2018, 10:24:11 AM] [huy]: #til What's the best RSS reader? It's theoldreader
[11/21/2018, 10:47:01 AM] [huy]: #til Singapore có chương trình hợp tác để gửi sinh viên các trường ĐH đi thực tập ở các startups tại Mỹ. Trông người mà ngẫm tới ta. Thiệt là gato quá thể.
[11/21/2018, 10:48:31 AM] [// english-ignore]: <https://startuplifers.org/>
[11/21/2018, 10:49:13 AM] [huy]: tính ra chinh phủ Sing cũng muốn biến Sing thành silicon valley
[11/21/2018, 10:49:23 AM] [huy]: và có cách thiết thực là gửi sinh viên đi du học xong bắt về
[11/21/2018, 10:49:41 AM] [huy]: từ đó có lực lượng nòng cốt để xây dựng
[11/21/2018, 10:49:50 AM] [huy]: đám sing intern qua đây đứa nào cũng về
[11/21/2018, 10:49:56 AM] [huy]: ko ai tính ở lại
[11/21/2018, 10:50:54 AM] [// english-ignore]: Không biết sống ở Sing với ở Mỹ chỗ nào sướng hơn :thinkhard:
[11/21/2018, 10:51:05 AM] [ko luong thien]: bên Canada cũng có, nhưng hình như là ở cấp độ trường thay vì quốc gia
[11/21/2018, 10:51:21 AM] [ko luong thien]: hơi random nhưng chắc tuỳ nhiều thứ chứ nhỉ
[11/21/2018, 11:06:08 AM] [huy]: ở Sing sống sướng hơn
[11/21/2018, 11:06:12 AM] [huy]: mặc dù đắt đỏ hơn
[11/21/2018, 11:06:21 AM] [huy]: nhưng ít ra thì ra đường thấy xe cộ chạy đông đúc vui hơn
[11/21/2018, 11:06:40 AM] [huy]: cá nhân thấy ở Việt Nam sống vui nhất
[11/21/2018, 11:06:50 AM] [huy]: tất nhiên vui chỉ là một trong nhiều phương diện sống
[11/21/2018, 11:09:39 AM] [ko luong thien]: ngược với mình :disappointed:
[11/21/2018, 11:10:06 AM] [huy]: cứ sống ở nước ngoài đủ lâu là sẽ thấy nhớ nhà thôi :sosad:
[11/21/2018, 11:10:12 AM] [huy]: ở nhật vẫn còn vui chán
[11/21/2018, 11:12:46 AM] [ko luong thien]: em đang ở VN actually..
[11/21/2018, 11:12:53 AM] [ko luong thien]: cơ mà ở Nhật zui..
[11/21/2018, 11:20:04 AM] [huy]: zui quá xá ấy chứ
[11/21/2018, 11:22:38 AM] [noob]: khi ta ở chỉ là nơi đất ở
khi ta đi đất bổng hoá đất vàng :yaomin:
[11/21/2018, 11:24:08 AM] [huy]: khi ta ở đất chỉ là nơi đất ở
khi ta đi, đất bổng hóa lân bang
[11/21/2018, 11:24:10 AM] [huy]: :yaomin:
[11/21/2018, 4:07:32 PM] [typescriptpher]: vì đám sinh viên giỏi của Sing thì đi Mỹ học đại học roài ở lại luôn r :roflrofl:
[11/21/2018, 4:08:52 PM] [huy]: :roflrofl:
[11/21/2018, 5:11:48 PM] [alias Trung.Le, as tle]: #til <https://www.elastic.co/guide/en/elasticsearch/reference/current/reindex-upgrade-remote.html>
[11/21/2018, 5:44:26 PM] [minh.nguyen]: #til GitGutter in Vim is f*cking slow
[11/21/2018, 7:02:15 PM] [thai]: hỏi ko liên quan: #til là gì vậy mọi người?
[11/21/2018, 7:03:18 PM] [alias Trung.Le, as tle]: `#til` == `Today I learn`
[11/21/2018, 7:03:24 PM] []: Today I learned
[11/21/2018, 7:06:52 PM] [typescriptpher]: #til <https://modern-sql.com/blog/2017-06/whats-new-in-sql-2016> :ie:
[11/21/2018, 7:32:59 PM] [話せる森林]: #til Mọi người hầu như ít khi đọc Channel Purpose để hiểu về channel hiện tại.
&gt; Today I learn - hôm nay bạn học đc gì? chia sẻ để tiến bộ
[11/21/2018, 7:37:39 PM] [alias Trung.Le, as tle]: #til <https://blog.cloudflare.com/the-road-to-quic/>
[11/21/2018, 8:47:15 PM] []: cũng có đọc channel purpose mà :smile:
[11/21/2018, 8:48:12 PM] []: trước hay dùng IRC chat, mới vào channel nó spam cho vài trang nội quy luôn, qua slack ko thấy có ghi chú gì lại thấy hơi lạ :smile:
[11/22/2018, 3:02:47 AM] [typescriptpher]: #tir <https://www.cs.columbia.edu/~ruigu/papers/socc18-final100.pdf>
[11/22/2018, 3:38:55 AM] [huynh.cam]: pocketed (and probably will never read)
[11/22/2018, 10:51:13 AM] [// english-ignore]: #til Hội chứng Tourette <https://vi.wikipedia.org/wiki/H%E1%BB%99i_ch%E1%BB%A9ng_Tourette>
[11/22/2018, 8:29:00 PM] [SFzxc]: #til Start your command with a space and it won't be included in the terminal history
[11/22/2018, 8:31:18 PM] [SFzxc]: Em đang cần vậy để nó ko lưu private_key nha a @xluffy ko phải accident =))
[11/22/2018, 8:31:53 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :troll: nhưng có 1 cách là dù em có space vẫn bị log lại nhé
[11/22/2018, 8:32:43 PM] [SFzxc]: chỉ e với :adore:
[11/22/2018, 8:32:47 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: mẹo để tránh trick trên là lưu file local, đẩy lên rồi `srm` sau khi xong
[11/22/2018, 8:33:46 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: <http://blog.kxr.me/2012/01/logging-shell-commands-in-linux.html>
[11/22/2018, 8:34:24 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: log tất cả command của em vào 1 file log (kể cả em có mấy space thì nó cũng trim, kể cả `history -c` hoặc edit file đó nó cũng log lại
[11/22/2018, 8:37:42 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: tất nhiên biết chỗ rồi thì chỉ cần stop rsyslog là ko bị log nữa :smile:
[11/22/2018, 8:40:57 PM] [SFzxc]: cái stop ryslog em chưa biết nơi, để em google phát. Thankiu a :beauty:
[11/22/2018, 8:41:16 PM] []: cơ mà tại sao space ở đầu thì nó không log vậy anh @xluffy
[11/22/2018, 8:42:03 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: space ở đầu thì nó ko log trong lệnh history, tại sao thì chắc do nó thiết kế vậy :))
[11/22/2018, 8:43:04 PM] [John]: cùng issue thì phải
<https://askubuntu.com/questions/423707/get-bash-history-to-remember-only-the-commands-run-with-space-prefixed>
[11/22/2018, 8:43:41 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: <https://unix.stackexchange.com/questions/115917/why-is-bash-not-storing-commands-that-start-with-spaces>
[11/22/2018, 8:43:54 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: ```
&gt; echo $HISTCONTROL
ignoreboth
```
[11/22/2018, 8:44:06 PM] [John]: right! :slightly_smiling_face:
[11/22/2018, 8:45:17 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: ```
&gt; man bash
/HISTCONTROL
```
[11/22/2018, 8:45:18 PM] [SFzxc]: `ignoreboth` is shorthand for `ignorespace` and `ignoredups`
[11/22/2018, 8:45:28 PM] []: cũng vừa mới xem xong :thinkmid:
<https://unix.stackexchange.com/questions/115934/why-does-bash-have-a-histcontrol-ignorespace-option>
[11/22/2018, 8:46:50 PM] [SFzxc]: vậy là mình overrate lại env này thì vẫn lưu như thường :omg:
[11/22/2018, 8:47:24 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: đúng :v
[11/23/2018, 5:21:10 AM] [FULLCLEARONSTAGE]: #til stow <https://alexpearce.me/2016/02/managing-dotfiles-with-stow/>
[11/23/2018, 5:28:58 AM] [sai]: @tobiwon rsyslog ma` cung~ ko biet', hoc. he. phan tan' de? dau het' roi` ha? thay` Ly buon` do' biet' ko
[11/25/2018, 6:04:56 AM] [// english-ignore]: #til ở Đà Nẵng có đường tên Dũng Sĩ Thanh Khê :muscle:
[11/25/2018, 11:27:05 PM] [caothang]: #til trong Rails 5.0.x trường hợp có nhiều after_commit vào cùng 1 action thì các callback này ko chạy theo thứ tự khai báo từ trên xuống dưới :headbang:
[11/25/2018, 11:27:19 PM] [caothang]: Tham khảo: <https://github.com/rails/rails/issues/20911>
[11/25/2018, 11:47:48 PM] [hieu.huynh]: #til làm cách nào để fork một public repo về org của mình, thành một private repo (vì cần phát triển thêm một số tính năng) :point_down:
<https://gist.github.com/jacquesd/85097472043b697ab57ba1b1c7530274>
[11/27/2018, 11:08:31 AM] [// english-ignore]: #til nhấn `i` trên youtube desktop để player thu nhỏ lại :scream:
[11/27/2018, 11:11:00 AM] [huy]: #til `instapaper_body` class
[11/27/2018, 9:19:24 PM] []: #til `git show branch:path/to/file` để coi file ở branch khác :omg:
[11/27/2018, 10:07:19 PM] [Cậu Làm Vườn]: #til phantom types
[11/27/2018, 10:29:11 PM] [// english-ignore]: Nà gì?
[11/27/2018, 10:30:24 PM] [unrealhoang]: Rút à :adore:
[11/27/2018, 11:11:28 PM] [Cậu Làm Vườn]: OCaml anh
[11/27/2018, 11:11:41 PM] [Cậu Làm Vườn]: @kcj.pop.com_rbvn ReasonML here
<https://medium.com/reasontraining/phantom-types-in-reasonml-1a4cfc18d999>
[11/27/2018, 11:13:09 PM] [Cậu Làm Vườn]: Good anwser on application
<https://www.quora.com/What-are-good-applications-of-phantom-types?share=1>
[11/27/2018, 11:14:05 PM] [unrealhoang]: qua rút còn thấy phantom type quan trọng hơn nữa
[11/27/2018, 11:15:03 PM] [unrealhoang]: là để annotate cho raw pointer
[11/28/2018, 7:16:25 PM] [anh bán chuối]: TIL <https://blog.phusion.nl/2017/10/13/why-ruby-app-servers-break-on-macos-high-sierra-and-what-can-be-done-about-it/>
[11/28/2018, 8:05:11 PM] [typescriptpher]: #til Memory Consistency Models <https://homes.cs.washington.edu/~bornholt/post/memory-models.html>
[11/28/2018, 8:05:29 PM] [typescriptpher]: <http://15418.courses.cs.cmu.edu/spring2015content/lectures/13_consistency/13_consistency_slides.pdf>
[11/28/2018, 8:05:38 PM] [typescriptpher]: <https://courses.cs.washington.edu/courses/cse451/15au/notes/l17-mcm-slides.pdf>
[11/28/2018, 8:06:14 PM] [minh.nguyen]: mấy course của tụi kia xịn nhỉ :cry:
[11/28/2018, 8:07:25 PM] [typescriptpher]: uah, cơ mà khó quá nên US thiếu engineer trầm trọng :))
[11/28/2018, 8:07:41 PM] [typescriptpher]: giờ sv chỉ thích học cái j dev nhanh, raise fund roài build startup thoai :v
[11/28/2018, 8:07:56 PM] [thai]: vậy mình ở VN ráng luyện
[11/28/2018, 8:08:06 PM] [thai]: xong qua đó bù đắp cho sự thiếu hụt
[11/28/2018, 10:12:42 PM] [ko luong thien]: #til _*La mort de l'auteur*_ or "The Death of the Author" is a theory in literary criticism argues that the meaning of a book or poem should be detached from its author's identity, intention or view. Only words that were written in the creation matters.
[11/28/2018, 10:14:09 PM] [ko luong thien]: <https://en.wikipedia.org/wiki/The_Death_of_the_Author#Influences_and_overview>
&gt; [...] a poem does not belong to its author; rather, it is detached from the author at birth and goes about the world beyond his power to intend about it or control it. The poem belongs to the public.
[11/28/2018, 10:15:53 PM] [ko luong thien]: One popular example is Dumbledore's sexuality. The 7 Harry Potter books could not convey or even deliver that idea, so what JK Rowling said in real life interviews or on TV doesn't matter at all.
JK Rowling is "detached" from her 7 books as soon as they were born.
[11/28/2018, 10:19:33 PM] [dat]: :+1:
[11/28/2018, 10:19:40 PM] [dat]: co ma em tuong cai nay obvious :))
[11/28/2018, 10:24:04 PM] [ko luong thien]: vẫn có đứa fight mà :))
[11/28/2018, 10:24:21 PM] [ko luong thien]: vẫn có 1 hướng cho rằng cái intention của author là undeniable
[11/28/2018, 10:24:58 PM] [ko luong thien]: what were written is purely because of the ability of the author (at such time) to deliver their meaning
[11/28/2018, 10:25:09 PM] [dat]: em theo hướng kia hơn
[11/28/2018, 10:25:13 PM] [ko luong thien]: the lack of their ability could not affect their initial intention at all
[11/28/2018, 10:25:16 PM] [dat]: tác phẩm là tác phẩm, tác giả là tác giả
[11/28/2018, 10:25:31 PM] [ko luong thien]: ừa same here :v anh cũng kiểu the hell viết rồi mà còn git amend
[11/28/2018, 10:25:38 PM] [dat]: hồi đó còn học văn cái này là vấn đề core
[11/28/2018, 10:25:48 PM] [dat]: “đồng sáng tạo” problem
[11/28/2018, 10:25:56 PM] [ko luong thien]: "hồi đó còn học văn"..
[11/28/2018, 10:26:27 PM] [dat]: mỗi người đọc = 1 version của tác phẩm
[11/28/2018, 10:26:34 PM] [dat]: tác giả có version của tác giả
[11/28/2018, 10:28:58 PM] [ko luong thien]: ờ
[11/28/2018, 10:29:01 PM] [ko luong thien]: make sense
[11/28/2018, 10:29:10 PM] [ko luong thien]: #GitNoAmend
[11/28/2018, 10:29:35 PM] [unrealhoang]: word is law
[11/28/2018, 10:30:06 PM] [unrealhoang]: như code is law trong crypto currency
[11/28/2018, 10:30:58 PM] [dat]: trong văn có cái example kinh điển
[11/28/2018, 10:31:09 PM] [dat]: tác giả làm hộ bài văn cho con
[11/28/2018, 10:31:18 PM] [dat]: bị cô phê là “không hiểu ý tác giả”
[11/28/2018, 10:31:22 PM] [dat]: :roflrofl:
[11/28/2018, 10:32:04 PM] [ko luong thien]: [thuyết âm mưu] đấy là lí do tác giả qua đời thì tác phẩm mới vào SGK :think:
[11/28/2018, 10:32:37 PM] [dat]: nhiều người còn sống mà còn bài trong sách mà
[11/29/2018, 1:38:49 AM] [Anh Xe Ôm]: #til Tonkin <https://en.m.wikipedia.org/wiki/Tonkin>
[11/29/2018, 1:41:30 AM] [// english-ignore]: #til ké Cochinchina <https://en.wikipedia.org/wiki/Cochinchina> :neutral_face:
[11/29/2018, 1:41:34 AM] []: mình biết tới từ Tonkin do cái club 1900 :vayvay:
[11/29/2018, 1:51:00 AM] [tanlinhnd]: Nghìn 9 cơ đấy :vayvay:
[11/29/2018, 2:07:36 AM] [dat]: em biet tu bai nay <http://webcache.googleusercontent.com/search?q=cache:5U1sV3vs4xMJ:www.procul.org/blog/2007/06/14/ch%25E1%25BB%25AF-hanoi-trong-tower-of-hanoi/>
[11/29/2018, 2:08:08 AM] [dat]: <http://procul.org/blog|procul.org/blog> gio bi loi gi nhi
[11/29/2018, 2:08:12 AM] [dat]: khong vao duoc link truc tiep
[11/29/2018, 2:10:36 AM] [__.__Sectumsempra__.__]: Em vào được bt :thinkhard:
[11/29/2018, 2:12:05 AM] []: bình thường mà @taurandat
[11/29/2018, 2:12:05 AM] []: :vayvay:
[11/29/2018, 2:13:08 AM] [dat]: <http://www.procul.org/blog/2005/07/16/bai-toan-thap-hanoi/|www.procul.org/blog/2005/07/16/bai-toan-thap-hanoi/>
[11/29/2018, 2:13:21 AM] [dat]: bam vao cai nay toan ra trang chu
[11/29/2018, 2:16:35 AM] [dat]: cũng không search được
[11/29/2018, 2:16:42 AM] [dat]: trên trang main
[11/29/2018, 2:16:48 AM] [dat]: ồ gỡ www ra thì được
[11/29/2018, 2:17:42 AM] [Anh Xe Ôm]: Thanism -&gt; đạo thờ Thần ở VN :vayvay:
[11/29/2018, 2:18:09 AM] [hieu.huynh]: blog này nhiều bài viết chất lượng phếch
[11/29/2018, 2:18:17 AM] [hieu.huynh]: nhưng hết ai maintain rồi ?
[11/29/2018, 2:19:48 AM] [dat]: <https://cse.buffalo.edu/~hungngo/>
[11/29/2018, 2:19:59 AM] [dat]: Sep 2017 -- present: Stealth Mode.
[11/29/2018, 2:20:02 AM] [dat]: sad
[11/29/2018, 4:15:49 AM] [typescriptpher]: #til Cortex-A9 architecture <http://meseec.ce.rit.edu/551-projects/spring2013/2-2.pdf>
[11/29/2018, 4:52:36 AM] [Cậu Làm Vườn]: #til Whataboutism
[11/29/2018, 4:53:05 AM] [Cậu Làm Vườn]: tìm mãi mới ra được cái từ này
[11/29/2018, 8:10:43 AM] [huy]: Tonkin, cocochina, rồi còn có Tourance nữa
[11/29/2018, 7:48:31 PM] [anh bán chuối]: TIL: <https://wiki.postgresql.org/wiki/What%27s_new_in_PostgreSQL_9.1#SQL_and_PL.2FPgSQL_features>
from postgres 9.1 Group by can guess some missing columns, the reason you need to specify all the columns you want to select in GROUP BY clause is the data return by group by might have multiple records and the DBMS cannot know which record to take data for you.
works from postgres &gt;= 9.1 (doesn't work with other DBMS or postgres 9.0)
```SELECT users.*
FROM users
GROUP BY users.uid```
doesn't work even with postgres 9.1 while users.email is a unique index on users
```SELECT users.*
FROM users
GROUP BY users.email
```
[11/29/2018, 7:51:23 PM] []: e chưa bao giờ làm như vầy cả, toàn group trước để lấy id rồi, select lại từ cái đó :omg:
[11/29/2018, 7:52:10 PM] [anh bán chuối]: uhm nay bi 1 case bug, mo vo code thay bon no toan group by id ma van select * :disappointed: noi la query sai roi
[11/29/2018, 7:52:15 PM] [anh bán chuối]: co dieu codes do chay dc hon 1 nam
[11/29/2018, 7:52:38 PM] [anh bán chuối]: cuoi cung loi ra ong noi devops migrate DB, chua add primary case tren uid
[11/29/2018, 7:53:38 PM] [anh bán chuối]: btw hieu tai sao a huydx go ko dau roi, cty cho may moi luoi cai qua nen xai luon
[11/29/2018, 7:54:40 PM] []: sao ko upgrade lên đi anh, sắp 2019 rồi còn dùng 9.1 :omg:
[11/29/2018, 7:55:45 PM] [anh bán chuối]: ah ko, from 9.1, bon a xai 10.4 roi, co dieu la ko biet sao codes vay chay dc =)) truoc gio cu tuong la phai group by roi moi dc select
[11/29/2018, 8:00:27 PM] [minh.nguyen]: Lên mongodb cho nó scale qnj :troll:
[11/29/2018, 8:01:12 PM] [anh bán chuối]: yeah postgres is not web-scale :trollface:
[11/30/2018, 12:29:57 AM] [SFzxc]: #til <https://en.wikipedia.org/wiki/Three-way_comparison>
Ruby 2.4 Comparable#clamp
<https://ruby-doc.org/core-2.4.0/Comparable.html>
[11/30/2018, 1:58:25 AM] [ko luong thien]: #til `new (a()).b() !== new a().b()` because `new` is stronger than `.`
[11/30/2018, 1:59:13 AM] [ko luong thien]: to be fair, `new` has the same priority with `.`, in which case the priority will be from left to right
[11/30/2018, 2:13:59 AM] [Cậu Làm Vườn]: #til
[11/30/2018, 7:20:48 AM] [// english-ignore]: `new Date().toLocaleDateString()` :-?
[11/30/2018, 7:22:54 AM] [ko luong thien]: @kcj.pop.com_rbvn anh nghĩ cái đó là
A. `( new Date() ) .toLocaleDateString()` hay
B. `new ( Date().toLocaleDateString() )`
[11/30/2018, 7:25:00 AM] [ko luong thien]: #til a sad truth that sublime's performance is better than vim :disappointed:
[11/30/2018, 7:25:17 AM] [ko luong thien]: or at least that's what happen when I try to edit a 130mb js file
[11/30/2018, 7:26:26 AM] [// english-ignore]: A :thinkhard:
[11/30/2018, 7:27:25 AM] [ko luong thien]: bingo :+1:
[11/30/2018, 7:27:50 AM] [// english-ignore]: :bow: để post lên Tàu Nhanh
[11/30/2018, 7:29:11 AM] [// english-ignore]: ngày xưa còn có lời khuyên xài `new Date` thôi
[11/30/2018, 7:29:23 AM] [// english-ignore]: :omg:
[11/30/2018, 7:30:26 AM] [ko luong thien]: `new Date.toLocaleDateString()` won't work :omg:
[11/30/2018, 7:30:40 AM] [ko luong thien]: `new Date().toLocaleDateString()` works :triumph:
[11/30/2018, 7:31:00 AM] [ko luong thien]: `new Foo()` &gt; `Foo.bar` &gt; `new Foo`
[11/30/2018, 7:36:40 AM] [// english-ignore]: Um xài Prettier nó tự sửa thành `Date()`
[11/30/2018, 7:37:05 AM] [dat]: how 'bout nvim
[11/30/2018, 7:42:54 AM] [ko luong thien]: ded
[11/30/2018, 7:43:11 AM] [ko luong thien]: <https://askubuntu.com/questions/28847/text-editor-to-edit-large-4-3-gb-plain-text-file>
[11/30/2018, 8:49:53 AM] [minh.nguyen]: Is your vim optimal :trollface:
[12/2/2018, 6:42:23 AM] [Anh Xe Ôm]: #til typescript hay vkl :doubt:
[12/2/2018, 6:46:46 AM] [linhnn]: có trang nào hướng dẫn typescript hay không @duythinht :adore:
[12/2/2018, 6:47:13 AM] [Anh Xe Ôm]: <https://www.typescriptlang.org/docs/handbook/migrating-from-javascript.html>
[12/2/2018, 6:48:41 AM] [linhnn]: trang này mình biết rồi nè, có trang nào kiểu mỗi ngày một ví dụ hay tut nhỏ trong typescript không ah :adore:
[12/2/2018, 6:51:26 AM] [Anh Xe Ôm]: không biết, mới ngâm cứu thử thôi
[12/2/2018, 6:01:08 PM] [tay vịn của anh bán chuối - cty A tìm FE]: Đọc hết cuốn handbook đi @linhvt22
[12/2/2018, 6:01:12 PM] [tay vịn của anh bán chuối - cty A tìm FE]: :))
[12/2/2018, 6:06:52 PM] [linhnn]: :fast-omg:
[12/3/2018, 8:03:21 AM] [typescriptpher]: #til Numba <https://rushter.com/blog/numba-cython-python-optimization/>
[12/5/2018, 4:57:51 AM] []: #til Bose quyên góp lợi nhuận thu được về cho phát triển giáo dục và nghiên cứu ở MIT <https://en.wikipedia.org/wiki/Amar_Bose>
[12/5/2018, 5:35:16 PM] [typescriptpher]: #til SPMD compiler <https://github.com/ispc/ispc/>
[12/5/2018, 6:05:26 PM] [alias Trung.Le, as tle]: #til ipse se nihil scire id unum sciat
[12/5/2018, 6:07:17 PM] [huy]: <https://media.giphy.com/media/NCTbhL8AG2s8g/giphy.gif>
[12/5/2018, 6:14:47 PM] [typescriptpher]: #tir vector models for data-parallel computing <https://www.cs.cmu.edu/afs/cs.cmu.edu/Web/People/blelloch/papers/Ble90.pdf>
[12/5/2018, 6:17:12 PM] [huy]: how can you read 260 pages in a day? :cggt:
[12/5/2018, 7:09:31 PM] [typescriptpher]: only read those parts that i haven't known yet?
[12/5/2018, 7:10:02 PM] [typescriptpher]: and when start reading something, i have a concrete purpose, so i will ignore all things that i don't need
[12/5/2018, 7:14:10 PM] []: Hmmm
[12/5/2018, 7:14:34 PM] []: Vẫn khó, ví dụ cái anh quăng em
[12/5/2018, 7:14:43 PM] []: Nếu ko đọc hết qua sao hiểu nổi anh
[12/5/2018, 7:14:54 PM] []: Trừ khi đã có kiến thức trước
[12/5/2018, 7:16:56 PM] [typescriptpher]: Cái anh quăng em thì anh đọc lâu rồi =))
[12/5/2018, 7:17:15 PM] [typescriptpher]: tại hôm qua bạn anh mention coq với cái này =))
[12/5/2018, 7:34:32 PM] []: Ặc
[12/5/2018, 7:36:39 PM] [ko luong thien]: #til the word "elicitation"
[12/5/2018, 9:32:52 PM] [alias Trung.Le, as tle]: #til ASN.1 <https://www.thanassis.space/asn1.html>
[12/5/2018, 9:52:41 PM] [alias Trung.Le, as tle]: #til react-dom hydrate()
[12/5/2018, 9:54:14 PM] [typescriptpher]: giờ anh đọc xuống compiler với arch rồi, có đọc cùng cho vi ko =)))
[12/5/2018, 10:06:48 PM] []: Thôi anh, em đọc cho xong cái type này đã
[12/5/2018, 10:25:32 PM] [tay vịn của anh bán chuối - cty A tìm FE]: Đang làm SSR hả anh
[12/6/2018, 4:22:25 PM] [meowwwwwwwwwwwwwwww]: #til `<https://apidock.com/ruby/Method/arity>`
[12/6/2018, 6:03:29 PM] []: #til postgres foreign key khong tu dong tao index
[12/6/2018, 6:26:06 PM] [typescriptpher]: #til Đừng quên cài Fortran trước khi cài Python, nếu ko mí chương trình của bạn sẽ chạy rất chậm :roflrofl:
[12/6/2018, 7:57:58 PM] [John]: why? có bài nào viết về nó ko anh?
[12/6/2018, 8:21:20 PM] [typescriptpher]: numpy xài fortran đó em, ko có fortran nó sẽ simulate lại mấy hàm tính multi dimensional array, nên châm hơn <https://www.numpy.org/devdocs/user/building.html>
[12/6/2018, 9:28:07 PM] [John]: Thank anh nhưng cho em hỏi tý.
Theo em biết thì python sử dụng library ở dạng singleton &amp; sau khi compile thì cache xuống binary file.
Nên việc simulate lại mấy hàm trên thì cũng ko gây ra việc chậm lắm?
[12/6/2018, 9:29:59 PM] [typescriptpher]: em cứ hình dung Python chỉ là cái thin wrapper của 1 loạt các thư viện tính toán bên dưới (C, C++, Fortran, etc)
[12/6/2018, 9:34:42 PM] [John]: :+1:
[12/6/2018, 9:34:44 PM] [John]: Thank anh!
[12/6/2018, 9:36:58 PM] [typescriptpher]: ấy, chưa nói hết :)))
[12/6/2018, 9:37:22 PM] [John]: tiếp đi anh, em đang đợi mà :smile:
[12/6/2018, 9:38:35 PM] [typescriptpher]: mà các thư viện đo kể cả dùng bản prebuild cũng sẽ ko dc tối ưu với phần cứng mình có, nên cũng phải build lại từ đầu hết
[12/6/2018, 9:42:02 PM] [typescriptpher]: mà cùng 1 thư viện nó có rất nhiều configvkhacs nhau, nếu lúc sinh file build ra nó sẽ detect xem hệ thống có sẵn lib nào thì nó sẽ build các phần code khác nhau
[12/6/2018, 9:42:32 PM] [typescriptpher]: đến cái đơn giản như floating point, nếu phần cứng ko có nó cũng simulate luôn
[12/6/2018, 9:49:19 PM] [John]: vậy việc setup trước &amp; sau như ở trên sẽ ảnh hưởng đến việc tận dụng tối ưu các resource code đc build ra. &amp; cuối cùng là performance. phải vậy ko anh?
[12/6/2018, 11:06:05 PM] [typescriptpher]: uah
[12/7/2018, 11:06:27 AM] [// english-ignore]: #til classic serverless &amp; neo serverless :ga: <https://sqlite.org/serverless.html>
[12/7/2018, 11:12:53 AM] [huy]: &gt; folks have begun to use the word "serverless" to mean something subtly different from its intended meaning
[12/7/2018, 11:12:55 AM] [huy]: :roflrofl:
[12/7/2018, 8:33:37 PM] [typescriptpher]: #til Clojure, Haskell, Scala, Erlang đều xài cái này cho map <https://infoscience.epfl.ch/record/64398/files/idealhashtrees.pdf>
[12/8/2018, 7:00:51 AM] [typescriptpher]: #tir <https://shipilev.net/blog/2016/close-encounters-of-jmm-kind/> giải trí cuối tuần :3
[12/9/2018, 4:40:27 AM] [typescriptpher]: #til <https://en.wikipedia.org/wiki/FYIFV> Fuck You, I'm Fully Vested
[12/9/2018, 6:06:29 PM] [alias Trung.Le, as tle]: chỉ vọc xem có gì mới thôi, mấy tháng đổ lại thì anh không đụng frontend nữa, chỉ vọc backend và devops
[12/9/2018, 6:13:08 PM] [ko luong thien]: #til
- in HTML5, it's valid to have a `div` inside an `a` but not inside a `button`
- in HTML4, it's not valid for both
[12/9/2018, 6:13:40 PM] [ko luong thien]: <https://www.w3.org/TR/html52/textlevel-semantics.html#the-a-element>
<https://www.w3.org/TR/html52/dom.html#phrasing-content-2>
<https://www.w3.org/TR/html401/struct/links.html#edef-A>
[12/9/2018, 10:59:02 PM] [hasagi]: ^^2 hay
[12/10/2018, 12:58:38 AM] [話せる森林]: #til `stackoverflow` phiên bản được dịch qua tiếng Việt `<https://stackoverrun.com/>`
[12/10/2018, 1:00:18 AM] [unrealhoang]: seen @nguyenquangminh
[12/10/2018, 1:00:34 AM] [minh.nguyen]: copy nhaafm =))
[12/10/2018, 1:00:48 AM] [dan]: tieng viet :v
[12/10/2018, 1:01:07 AM] [minh.nguyen]: <https://www.dropbox.com/s/8ut0z5zd4rldasg/Screenshot%202018-12-10%2015.59.49.png?dl=0>
[12/10/2018, 1:01:11 AM] [minh.nguyen]: google dịch chắc
[12/10/2018, 1:02:08 AM] [unrealhoang]: seen cái copy nhầm thứ 2
[12/10/2018, 1:02:11 AM] [unrealhoang]: :roflrofl:
[12/10/2018, 1:02:14 AM] [dan]: ^ mới thấy cái tiền nhà xong :vayvay:
[12/10/2018, 1:02:24 AM] [unrealhoang]: :vayvay:
[12/10/2018, 1:02:35 AM] [minh.nguyen]: mới upgrade lên mojave :beat_brick: dropbox nó ứ ăn đựo clipboard
[12/10/2018, 1:03:13 AM] [unrealhoang]: thanh niên có điều kiện :crying:
[12/10/2018, 1:04:08 AM] [minh.nguyen]: :bick
[12/10/2018, 1:04:11 AM] [minh.nguyen]: :beat_brick:
[12/10/2018, 1:07:23 AM] [dan]: e ở bằng 1/8 :crying:
[12/10/2018, 1:09:06 AM] [unrealhoang]: nhà 1.8tr sao ở :think:
[12/10/2018, 1:09:59 AM] [dan]: phòng 1/7
[12/10/2018, 1:10:32 AM] [dan]: :thinkcry:
[12/10/2018, 1:10:50 AM] [ko luong thien]: random :-&lt;
[12/10/2018, 1:10:55 AM] [ko luong thien]: vì sự trong sáng của #til
[12/10/2018, 2:32:20 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til Don't mess up with zshrc file and backup it :omg:
[12/10/2018, 2:43:28 AM] [ledongthuc]: zshrc, vimrc, ssh =&gt; :okay: dropbox sync
[12/10/2018, 2:44:06 AM] [tay vịn của anh bán chuối - cty A tìm FE]: :okay:
[12/10/2018, 3:08:36 AM] [thai]: #til C++
```
vector&lt;int&gt; v1(10, 0), v2(10, 0); // fill vector by 0
for (int i = -1; i &gt;= -5; i--) { v2[i] = i; } // access invalid index
output(v1); // =&gt; "0 0 0 0 0 0 0 -5 -4 -3"
```
[12/10/2018, 3:09:19 AM] [thai]: vector access index thoải mái :disappointed:
[12/10/2018, 3:21:29 AM] [unrealhoang]: UB đấy
[12/10/2018, 3:30:27 AM] [thai]: UB là gì :omg:
[12/10/2018, 4:40:45 AM] [dat]: undefined behaviors
[12/10/2018, 7:30:03 AM] [FULLCLEARONSTAGE]: why don’t manage them with git
[12/10/2018, 7:40:13 AM] [tay vịn của anh bán chuối - cty A tìm FE]: auto sync :thinking_face:
[12/10/2018, 8:42:48 AM] [FULLCLEARONSTAGE]: Auto sync is good, but git is much more powerful when it comes to retrieve file histories
[12/10/2018, 8:46:05 AM] [anh bán chuối]: optimized for growth :omg:
[12/10/2018, 8:50:36 AM] [vthu]: <https://darkpatterns.org/hall-of-shame>
[12/10/2018, 9:00:25 AM] [huy]: :))
[12/10/2018, 5:26:54 PM] [ko luong thien]: #til "Rapid Serial Visual Presentation" (<https://accelareader.com/>)
[12/10/2018, 5:56:16 PM] [ledongthuc]: :okay: sự thật là đã từng sửa từa lưa + lười commit -&gt; quên -&gt; cài lại máy
[12/11/2018, 3:12:29 AM] [typescriptpher]: #til Yes <https://github.com/coreutils/coreutils/blob/master/src/yes.c>
[12/11/2018, 3:41:59 AM] [unrealhoang]: Bữa đọc bài về yes
[12/11/2018, 3:42:04 AM] [unrealhoang]: Hay voãi
[12/11/2018, 4:23:10 AM] [typescriptpher]: yes
[12/11/2018, 4:24:27 AM] [typescriptpher]: First version vieet boi Ken Thompson =))
[12/11/2018, 3:00:48 PM] [huy]: #til Luôn tìm cách tháo gỡ những khúc mắc càng sớm càng tốt, nhất là những vấn đề liên quan đến tâm ~sinh~ lý trong các mối quan hệ, hoặc các vấn đề liên quan đến lỗ hổng kiến thức trong khi nghiên cứu, hoặc là những vấn đề liên quan đến khác biệt góc nhìn giữa đôi bên trong khi họp về technical. Thường trong đại đa số các trường hợp, thì vấn đề chỉ đến từ việc hiểu lầm, hoặc thiếu kiến thức. :thinkhard: càng giải quyết sớm càng đảm bảo được performance/productivity.
[12/11/2018, 3:09:00 PM] [manhdv]: ^ tl;dr: cái gì chưa mượt thì nên giải quyết ngay :v
[12/11/2018, 3:09:19 PM] [huy]: :okay:
[12/11/2018, 3:09:28 PM] [huy]: best tl;dr
[12/11/2018, 3:19:33 PM] []: Lol
[12/11/2018, 4:54:56 PM] [alias Trung.Le, as tle]: lol
[12/12/2018, 7:06:27 AM] [typescriptpher]: #til Abstract Interpretation <https://www.di.ens.fr/~cousot/AI/IntroAbsInt.html>
[12/12/2018, 7:10:36 AM] [typescriptpher]: <https://github.com/NASA-SW-VnV/ikos> - Static analyzer for C/C++ based on the theory of Abstract Interpretation. from NASA with love :3
[12/12/2018, 3:01:29 PM] [huy]: #til *Slacktivism*: showing support for a cause with the main purpose of boosting the egos of participants in the movement <https://en.m.wikipedia.org/wiki/Slacktivism>
[12/12/2018, 7:17:11 PM] [dan]: #til ppa-purge
[12/13/2018, 12:21:17 AM] [SFzxc]: #til Command-line JSON processor <https://github.com/stedolan/jq>
Ex:
```
~$ echo "{\"key\": \"value\"}" | jq '.key' | tr -d '"'
value
```
[12/13/2018, 12:24:19 AM] [manhdv]: #til string trong go ko co built in `reverse` method :disappointed:
[12/13/2018, 12:24:48 AM] [ko luong thien]: this depends on your language I think so maybe note that?
[12/13/2018, 12:25:20 AM] [unrealhoang]: vì nó costly, i.e. memory allocation
[12/13/2018, 12:25:27 AM] [unrealhoang]: và usually you don’t want that
[12/13/2018, 12:26:12 AM] [ko luong thien]: hợp lí :think:
[12/13/2018, 12:26:23 AM] [ko luong thien]: :+1: @unrealhoang
[12/13/2018, 12:31:25 AM] [manhdv]: mình chỉ muốn cắt bỏ các số 0 sau số 1 trong `"0.000000100000"` đi thôi, mà sao cảm thấy khó quá :)))))))))))
[12/13/2018, 12:31:56 AM] [unrealhoang]: đấy, nên anh đâu cần reverse string
[12/13/2018, 12:32:46 AM] [unrealhoang]: reverse string là phải tạo ra 1 string mới `"000001000000.0"`
[12/13/2018, 12:34:40 AM] []: :think: search index xong `[from:to]` thôi nhỉ
[12/13/2018, 12:34:59 AM] [unrealhoang]: reverse search thôi
[12/13/2018, 12:35:36 AM] [unrealhoang]: hoặc là chuyển qua xài Rust, vì Rust có generic iterator nên có hàm `reverse` nhé
[12/13/2018, 12:38:07 AM] [manhdv]: thì lười iterator đó, đọc cái pkg strings mới phát hiện ra ko có built in này thôi mà :v
[12/13/2018, 12:39:53 AM] [unrealhoang]: uh thì không có generic iterator nên lười
[12/13/2018, 12:40:02 AM] [unrealhoang]: bởi vậy qua xài Rust đi anh :roflrofl:
[12/13/2018, 9:33:25 AM] [dat]: #til `swapoff -a &amp;&amp; swapon -a`
[12/13/2018, 2:46:34 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: free swap :omg:
[12/13/2018, 4:27:17 PM] []: for a better life, please set swappiness
[12/14/2018, 1:00:01 AM] [huy]: #til Bạc xỉu là từ gốc hoa :flag-cn:
[12/14/2018, 1:08:40 AM] [// english-ignore]: "cái tẩy" có phải là từ gốc Hoa luôn hông
[12/14/2018, 1:10:42 AM] [huy]: cái này chắc phải mời lão đại @hqc
[12/14/2018, 1:12:00 AM] []: Maybe…
<https://ask.fm/Cunghoctv/answers/128867137874>
cc @snacky
[12/14/2018, 1:13:33 AM] [huy]: hình như còn cả mấy chữ như "xạo ke" nữa
[12/14/2018, 1:13:38 AM] [huy]: cũng từ tiếng tàu
[12/14/2018, 1:19:35 AM] [huynh.cam]: ừa
[12/14/2018, 1:20:13 AM] [huynh.cam]: cái "tẩy" 底 tiếng quảng đông có nghĩa là cái đế, miếng lót
[12/14/2018, 1:22:12 AM] [typescriptpher]: xạo ke là từ từ nào @hqc ơi :adore:
[12/14/2018, 1:23:03 AM] [huynh.cam]: e chưa nghe xạo ke là tiếng tàu bao giờ :thinking_face:
[12/14/2018, 1:23:22 AM] [huynh.cam]: mà e tìm dc cái này <https://bacsinguyenxuanquang.wordpress.com/2011/07/29/y-nghia-nh%E1%BB%AFng-t%E1%BB%AB-tho-t%E1%BB%A5c-trong-vi%E1%BB%87t-ng%E1%BB%AF/>
[12/14/2018, 1:23:34 AM] [huynh.cam]: ko biết bác sĩ nguyên xuân quang có credibility ko
[12/14/2018, 1:25:05 AM] [typescriptpher]: oh, có cả nghiên cứu dài luôn :roflrofl:
[12/14/2018, 1:25:23 AM] [typescriptpher]: anh dân bắc nên giờ mới biết từ ke có nghĩa bậy á :))
[12/14/2018, 1:25:50 AM] [huynh.cam]: e dân nam cũng thế thôi :roflrofl:
[12/14/2018, 1:26:03 AM] [huynh.cam]: trước giờ cứ nói xạo ke ...
[12/14/2018, 1:28:01 AM] [typescriptpher]: cty trước của anh, có bạn designer người Pháp, nc với hắn toàn nói tiếng Anh
[12/14/2018, 1:28:46 AM] [typescriptpher]: cho đến 1 ngày team designer post lên 1 câu hắn kêu:"xạo chó" :roflrofl:
[12/14/2018, 1:29:06 AM] [typescriptpher]: hoá ra còn rành tiếng Việt hơn mềnh :))
[12/14/2018, 1:30:34 AM] [huynh.cam]: lol
[12/14/2018, 1:31:22 AM] [huy]: nice
[12/14/2018, 1:34:53 AM] [// english-ignore]: Có thằng bạn người Hung chuyên la "cút"
[12/14/2018, 1:35:43 AM] [huy]: cút thì từ chung rồi thì phải
[12/14/2018, 1:35:44 AM] [huy]: a lê cút
[12/14/2018, 1:35:49 AM] [huy]: chắc từ hồi pháp
[12/14/2018, 2:36:37 AM] [chua dc luong thien]: #til <https://docs.microsoft.com/en-us/windows/console/console-aliases>
[12/14/2018, 3:01:33 AM] [typescriptpher]: #tir <https://www.cs.virginia.edu/~robins/Turing_Paper_1936.pdf>
[12/14/2018, 10:19:15 PM] [typescriptpher]: #til Journey Mapping <https://www.nngroup.com/articles/journey-mapping-101/>
[12/16/2018, 12:04:32 AM] [ko luong thien]: #til "Polictical Answer":
&gt; Q: "What is your name?"
&gt; A: "That is a good question but what is really important is that is cold outside".
[12/16/2018, 8:23:57 PM] [Dz]: #til dùng `npx npm-check -u` để biết được package nào trong repo cần update và có thể chọn từng cái để update
[12/16/2018, 9:52:46 PM] [alias Trung.Le, as tle]: #til rspec `aggregate_failures`
[12/16/2018, 11:56:07 PM] [tay vịn của anh bán chuối - cty A tìm FE]: mình hay dùng yarn upgrade-interactive và ncu
[12/16/2018, 11:56:25 PM] [tay vịn của anh bán chuối - cty A tìm FE]: <https://github.com/tjunnone/npm-check-updates>
[12/17/2018, 12:07:46 AM] [anh bán chuối]: :+1: đúng cái em đang cần, omg
[12/17/2018, 1:10:31 AM] [SFzxc]: sao thấy a til cách đây 3 năm rồi
<https://kipalog.com/posts/Gioi-thieu-ham-aggregate_failures---trong-RSpec> :thinkhard:
[12/17/2018, 1:13:18 AM] [anh bán chuối]: =)) chắc ảnh quên rồi
[12/17/2018, 11:04:28 AM] [trexnix]: #til <https://erlangbyexample.org/>
[12/17/2018, 11:57:43 AM] [huy]: #tic (today I coined): Zombie Dev - a developer who quit long a go, but his effing code still causing bugs today :doubt:
[12/17/2018, 6:56:15 PM] []: Cảm giác rất nhột :blush:
[12/18/2018, 12:07:55 AM] []: #til What Is `Idempotence`?
From a RESTful service standpoint, for an operation (or service call) to be idempotent, clients can make that same call repeatedly while producing the same result and the system has same state
[12/18/2018, 12:09:11 AM] [// english-ignore]: Post Twitter đi để retweet cho viral nào
[12/18/2018, 12:17:18 AM] [huy]: as you wish <https://twitter.com/huydotnet/status/1074941558460362753>
[12/18/2018, 3:28:28 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til What are covariance and contravariance?
<https://www.stephanboyer.com/post/132/what-are-covariance-and-contravariance>
[12/19/2018, 12:45:41 AM] []: #til git squash
[12/19/2018, 12:46:02 AM] [__.__Sectumsempra__.__]: @neacao :vayvay:
[12/19/2018, 12:54:18 AM] [tucao]: :notlikethis: still messing in it
[12/19/2018, 2:14:03 AM] []: đơn giản nhất là `git reset --soft #commit` rồi commit lại. Không cần biết rebase là gì
[12/19/2018, 8:20:49 AM] [SFzxc]: #til vim `ciw`
[12/19/2018, 8:22:28 AM] [ledongthuc]: ci{
[12/19/2018, 8:28:30 AM] [huynh.cam]: ```
&lt;a&gt;cont|ent&lt;/a&gt;
```
`cit`
[12/19/2018, 8:47:29 AM] [SFzxc]: `ci{` cái này là gì sao em bấm nó ko ra gì hết nhỉ :think:
[12/19/2018, 8:48:15 AM] [ledongthuc]: ```
func name() {
content
}
```
[12/19/2018, 8:49:43 AM] [SFzxc]: à e test trong code ruby, hèn gì :roflrofl:
[12/19/2018, 8:51:34 AM] [SFzxc]: vậy là ci[, ci( cũng sẽ work tương tự :bow:
[12/19/2018, 5:28:12 PM] []: *c* hange- *i* n- *w* ord
*c* hange- *i* n- *t* ab
*c* hange- *i* n- *{*
*c* hange- *i* n-&lt;you name it&gt;
[12/19/2018, 5:28:36 PM] []: viw = visualize-in-word
same
[12/19/2018, 5:35:29 PM] [話せる森林]: Anh em viết #til có thể viết rõ hơn là đưa ra keywords không? :disappointed: Vì không hiểu context.
[12/19/2018, 5:35:56 PM] []: :think:
[12/19/2018, 5:36:08 PM] [SFzxc]: inner :omg:
[12/19/2018, 5:36:31 PM] []: Nếu anh dùng vim thì sẽ hiểu, ngắn gọn là shortcut keys trong vim
[12/19/2018, 5:37:18 PM] []: @tobiwon chuyển mấy cái từ viết tắt thành từ rõ ràng dễ nhớ với áp dụng hơn :omg:
[12/19/2018, 5:37:23 PM] [話せる森林]: Hãy viết #til có Tâm :vayvay:
[12/20/2018, 9:49:43 PM] [hasagi]: vscode nhe
[12/21/2018, 10:10:18 PM] []: #til <https://tools.ietf.org/html/rfc4122>
[12/23/2018, 2:38:47 AM] []: #til NoSQL xuất phát từ một Twitter hashtag :fast-omg:
[12/23/2018, 3:11:09 AM] [Cậu Làm Vườn]: Source please
[12/23/2018, 5:37:54 AM] []: Design data intesive application : nosql was originated from a hashtag on twitter to promote meetups about alternatives to sql. :omg:
[12/23/2018, 7:11:33 AM] [typescriptpher]: #til Perl is the most popular language for bioinformatics.
[12/24/2018, 1:52:14 AM] [typescriptpher]: #til <https://github.com/python/cpython/blob/master/Objects/obmalloc.c#L686> Object allocator for Python - "A fast, special-purpose memory allocator for small blocks, to be used on top of a general-purpose malloc -- heavily based on previous art."
[12/24/2018, 7:01:39 PM] [manhdv]: #til A socket is identified by `{SRC-IP, SRC-PORT, DEST-IP, DEST-PORT, PROTOCOL}`
[12/24/2018, 7:37:15 PM] [typescriptpher]: #til <http://lampwww.epfl.ch/resources/lamp/teaching/advancedCompiler/2004/slides/ImplementationOfConcurrency_slides.pdf>
[12/24/2018, 8:03:24 PM] [ledongthuc]: #til raw socket protocol supports to control and work directly with network layer 3. By pass tcp/udp
[12/24/2018, 11:11:32 PM] [ko luong thien]: epfl :heart:
[12/24/2018, 11:11:39 PM] [ko luong thien]: dream place to me
[12/25/2018, 12:11:05 AM] [huynh.cam]: Erlang :heart_eyes:
[12/25/2018, 2:46:24 AM] [ko luong thien]: #til that the lady I randomly met in a random meetup in Japan, asking me for help on coding a very basic website back then, is actually a Creative Programs Lead of Google..
She was learning Front End to implement a MVP of her idea, before proposing it to other engineers for further development.
I'm speechless
[12/25/2018, 2:47:00 AM] [Cậu Làm Vườn]: :adore:
[12/25/2018, 2:48:42 AM] [ko luong thien]: cc @unrealhoang :disappointed: không ngờ lần đó gặp người tài..
[12/25/2018, 2:49:23 AM] [unrealhoang]: =))
[12/25/2018, 2:53:16 AM] [typescriptpher]: #til Linux Weekly News <https://lwn.net/Archives/> cứ thứ 5/6 hàng tuần đọc cái này toàn bài hay vcl
[12/25/2018, 11:27:32 PM] [anh bán chuối]: #til <https://www.macobserver.com/tips/quick-tip/macos-mojave-screenshot/> :ie:
[12/26/2018, 8:46:40 AM] [Cậu Làm Vườn]: #todayIfound <http://www.devopsbookmarks.com/>
[12/27/2018, 7:18:22 AM] [thai]: #til tmux
[12/27/2018, 8:37:04 AM] [handcode]: xai them frontend Byobu fancy :omg:
<https://gist.github.com/inhumantsar/bf86ff1961cccdf8be06>
[12/27/2018, 8:38:56 AM] [minh.nguyen]: Muxinator nữa. Cộng thêm mapping giống vim nữa là chuẩn.
[12/27/2018, 7:03:38 PM] [typescriptpher]: tmuxinator chu nhi?
[12/27/2018, 7:14:22 PM] [typescriptpher]: #til <https://elpa.gnu.org/packages/undo-tree.html>
[12/28/2018, 12:42:40 AM] [// english-ignore]: :til-en: dev rel = developer relations
[12/28/2018, 4:34:12 AM] [handcode]: <https://kinsta.com/blog/php-benchmarks/>
[12/28/2018, 4:46:15 AM] [huynh.cam]: 148.80 req/sec :thinking_face: hơi chậm nhỉ
[12/29/2018, 12:42:33 PM] [// english-ignore]: #til <http://xitrum.net|xitrum.net> vẫn còn :scream:
[12/30/2018, 6:07:02 AM] [ko luong thien]: #til Olbers' paradox
&gt; In essence, if we posit that the universe is infinitely large and contains an infinite number of stars, then every line of sight an observer can see should eventually end at a star. So if the universe is infinitely old, every point in the sky should be as bright as the surface of a star.
&gt;
&gt; Since it clearly isn't - we have to discard one or more of our assumptions. (They are the universe is infinitely large, contains an infinite number of stars and is infinitely old)
&gt;
&gt; This is evidence for the big bang - we discard the idea that the universe is infinitely old, so although every line of sight does end in a star, the light from those stars has not had time to arrive yet. (As the speed of light is slow compared to the size of the universe).
[12/30/2018, 6:07:33 AM] [ko luong thien]: <https://www.reddit.com/r/explainlikeimfive/comments/aaolj7/eli5_why_is_space_black_arent_the_stars_emitting/ecu52lo/>
[12/30/2018, 6:28:21 AM] [dat]: <https://www.youtube.com/watch?v=gxJ4M7tyLRE>
[12/30/2018, 7:04:04 AM] [ko luong thien]: Nice thanks ku
[12/30/2018, 7:21:28 AM] [dat]: hinh nhu ngay truoc anh hoc Ly a
[12/30/2018, 7:21:30 AM] [dat]: :o
[12/30/2018, 7:21:42 AM] [dat]: theory confirmed hoc Ly gioi = good engineer
[12/30/2018, 9:12:37 AM] []: #til redis clusters resharding :D <https://redis.io/topics/cluster-spec>
[12/30/2018, 9:35:34 AM] [ko luong thien]: hồi đó anh học mỗi năm 1 môn mà
[12/30/2018, 9:35:42 AM] [ko luong thien]: 10 toán 11 tin 12 lý
[12/30/2018, 9:35:48 AM] [ko luong thien]: theory unconfirmed
[1/1/2019, 7:03:50 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til:
<https://www.2dimensions.com>
<https://www.2dimensions.com/about-nima>
<https://www.2dimensions.com/about-flare>
[1/1/2019, 6:49:23 PM] [alias Trung.Le, as tle]: #til PHP7 + Nginx as reverse LB and for a slight moment I thought Wordpress has said goodbye to PHP years ago <https://www.nginx.com/blog/maximizing-php-7-performance-with-nginx-part-ii-multiple-servers-and-load-balancing/>
[1/2/2019, 12:01:36 PM] [huynh.cam]: #til `one schema` `two schemata`
[1/2/2019, 5:07:08 PM] [ko luong thien]: #til CSS Sticky cannot be applied to `thead` or `tr` (well, for the majority of browsers) but can be applied to `th`, which is nice
[1/2/2019, 7:21:00 PM] [SFzxc]: #til <https://slack.com/apps/A03CMKFPN-sameroom>
Sameroom provides real-time interoperability between Slack and other chat systems.
[1/2/2019, 7:21:50 PM] [SFzxc]: <https://sameroom.io/open-a-tube>
[1/2/2019, 8:41:29 PM] []: #til MySQL `RESTRICT == NO ACTION`, PostgreSQL `RESTRICT != NO ACTION` :cry:
[1/3/2019, 6:15:52 PM] [typescriptpher]: #til <https://slingerjansen.files.wordpress.com/2009/04/2017saner-eventsourcing.pdf>
[1/4/2019, 6:17:57 PM] [ledongthuc]: #til coconut milk, coconut oil, coconut water :coconut:
[1/4/2019, 11:41:44 PM] [typescriptpher]: #til Pinning <https://www.owasp.org/index.php/Certificate_and_Public_Key_Pinning>
[1/5/2019, 12:57:47 AM] []: Nghe bảo mọi người đang move away khỏi cái này
[1/5/2019, 8:24:21 AM] [minh.nguyen]: #til &gt; Most software at Google gets rewritten every few years.
[1/5/2019, 8:48:49 AM] [tay vịn của anh bán chuối - cty A tìm FE]: cho xin link đi bạn
[1/5/2019, 10:21:56 AM] [FULLCLEARONSTAGE]: ^ co phai cai nay ko nhi <https://arxiv.org/ftp/arxiv/papers/1702/1702.01715.pdf>
[1/6/2019, 4:46:20 AM] [typescriptpher]: #til đọc lại Paxos, và vẫn ko hiểu j :roflrofl: <https://vadosware.io/post/paxosmon-gotta-concensus-them-all/>
[1/6/2019, 7:51:13 PM] [SFzxc]: #til <https://www.postgresql.org/docs/current/indexes-partial.html>
[1/7/2019, 2:06:07 PM] [huy]: #til you can bookmark any pỏnhub page and firefox won't show it in new tab page <https://www.reddit.com/r/firefox/comments/achchj/firefox_easter_egg/>
[1/7/2019, 2:09:28 PM] [huy]: The data is from here <https://github.com/matthewruttley/contentfilter/blob/master/sites.json>
:warning: It does not have Vietnamese sites, so don't bookmark one.
[1/7/2019, 2:12:35 PM] [huy]: Well, the reason they do this [1] is not for the sake of your privacy, but because they don't want commercials being displayed next to pron.
[1]: <https://bugzilla.mozilla.org/show_bug.cgi?id=1159884>
[1/8/2019, 8:15:54 PM] [typescriptpher]: #til make all the things <https://gist.github.com/isaacs/62a2d1825d04437c6f08> <https://nullprogram.com/blog/2017/08/20/>
[1/8/2019, 8:20:53 PM] [huy]: Makefile for Go <https://github.com/huytd/playgo/blob/master/Makefile>
[1/8/2019, 8:25:02 PM] [typescriptpher]: `sudo rm -f /usr/local/bin/$(OUT)` I'm okay :roflrofl:
[1/8/2019, 8:27:24 PM] [huy]: don't blame the young developer's config
[1/9/2019, 5:47:14 AM] [// english-ignore]: #til how to chỉnh lăn chuột với git diff <https://askubuntu.com/questions/803486/can-i-scroll-to-new-lines-using-mouse-wheel-inside-git-diff>
[1/9/2019, 7:38:55 AM] [typescriptpher]: #til <https://github.com/wasamasa/eyebrowse>
[1/11/2019, 2:51:08 AM] [typescriptpher]: #til M$ is awesome! <https://github.com/MicrosoftDocs/cpp-docs/tree/master/docs/c-language>
[1/11/2019, 11:40:19 AM] [huy]: #tic (today I coined): *"Note debt"* - it's a note or document which the written work is never finished.
[1/11/2019, 11:43:38 AM] [huy]: #til You can use Emacs's keybinding in Firefox MacOS, on any textbox, type:
```
C-f / C-b : to move to the next/previous characters
C-n / C-p : to jump to next/previous line
C-e : to the end of the line
C-a : to the beginning of the line
C-k : to delete everything from the cursor
C-d : to delete backwards
```
[1/11/2019, 11:47:50 AM] [trexnix]: Chrome, iTerm cũng được nhe anh
[1/11/2019, 11:48:17 AM] [// english-ignore]: Cái đó hình như apply cho tất cả cursor movement trên mac phải hông? Bữa thử bấm trên Terminal cũng được
[1/11/2019, 11:48:56 AM] [huy]: Oh, chrome cũng đc nè
[1/11/2019, 11:49:06 AM] [huy]: hóa ra là macos
[1/11/2019, 11:49:07 AM] [huy]: :omg:
[1/11/2019, 11:49:52 AM] [huy]: xịn xỏ
[1/11/2019, 11:52:38 AM] [huy]: Full list <https://jblevins.org/log/kbd>
[1/11/2019, 12:21:15 PM] [trexnix]: :omg:
[1/11/2019, 12:21:19 PM] []: <https://en.wikipedia.org/wiki/GNU_Readline>
[1/11/2019, 12:21:48 PM] []: app nào cũng chạy
[1/11/2019, 12:21:51 PM] []: đa số
[1/11/2019, 1:19:01 PM] [huy]: quá ngon
[1/11/2019, 7:05:12 PM] [anh bán chuối]: #til <https://www.maketecheasier.com/omit-developer-search-results-mac/> silly bug, cần tạo 1 file <http://Xcode.app|Xcode.app> empty để disable developers files in spotlight search
[1/12/2019, 7:35:42 AM] [// english-ignore]: #til Mobile Twitter mượt hơn bản desktop <https://mobile.twitter.com/home> :thinkcry:
[1/12/2019, 7:38:54 AM] [vunv]: #til javascript String.prototype.normalize() <https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/normalize>
[1/12/2019, 7:39:49 AM] [tay vịn của anh bán chuối - cty A tìm FE]: thấy bảo đang AB testing để xài bản mobile trên desktop luôn đó
[1/12/2019, 7:41:07 AM] [// english-ignore]: Ít ra trên đây còn có cái mục Explore
[1/12/2019, 8:10:39 AM] [SFzxc]: #til <https://jobs.netflix.com/culture>
[1/12/2019, 8:11:51 AM] [// english-ignore]: font đẹp :disappointed:
[1/12/2019, 8:13:57 AM] [SFzxc]: đẹp thì phải vui chớ sao buồn a :omg:
[1/12/2019, 8:14:24 AM] [// english-ignore]: web mình font xấu hơn web người ta
[1/12/2019, 8:27:59 AM] [Cậu Làm Vườn]: Mới thấy React Native Web bị chửi vì output ra non sensible class name :omg:
[1/12/2019, 8:29:47 AM] [// english-ignore]: Oh :-? lý do thiệt nhảm
[1/12/2019, 8:31:41 AM] [Cậu Làm Vườn]: <https://mobile.twitter.com/modernserf/status/1084079691923968000>
[1/12/2019, 8:33:50 AM] [Cậu Làm Vườn]: Nguyên nhân chính là làm cho khó tinkering hơi :think:
[1/12/2019, 8:36:00 AM] [// english-ignore]: Deal with it. Giờ làm web đòi source phải dễ cho thằng khác chọt nữa thì thôi lên làm cha người ta luôn đi
[1/12/2019, 8:37:05 AM] [Cậu Làm Vườn]: React Native Web giờ đúng là best of both world luôn, viết css-in-js quăng ra atomic :vayvay:
[1/12/2019, 8:38:37 AM] [Cậu Làm Vườn]: Style Property thì có type hết, suggest được giá trị nào cho phép. Có thêm console warning nếu mình dùng sai cái gì đó.
[1/13/2019, 6:54:35 AM] [dat]: #til (un)likely <https://stackoverflow.com/questions/109710/how-does-the-likely-unlikely-macros-in-the-linux-kernel-works-and-what-is-their>
[1/13/2019, 8:38:44 AM] [typescriptpher]: #til Tháng 9, năm 1993, FPT ký hợp đồng phần mềm đầu tiên bán cho khách hàng nước ngoài (Cathay Trust Bank - sau này đổi thành Chinfon Bank - Đài Loan). Đây là core banking có tuổi thọ khá lâu, được phát triển trên nền FOX for DOS, có nhiều tranh cãi nhưng tên tuổi của SIBA vẫn gắn liền với FPT, trước đây được sử dụng rất rộng rãi nhưng tại thời điểm hiện tại ko đáp ứng được nhu cầu.
[1/13/2019, 10:49:44 AM] [dat]: #til `gsettings set org.gnome.desktop.interface gtk-key-theme "Emacs"` :open_mouth:
[1/13/2019, 10:49:57 AM] [dat]: cc @eyeball
[1/13/2019, 4:48:43 PM] [ko luong thien]: ..
[1/13/2019, 4:48:52 PM] [ko luong thien]: xài vim buồn vỡi :-&lt;
[1/13/2019, 9:02:36 PM] [dat]: xai emacs di
[1/14/2019, 1:35:14 AM] [typescriptpher]: #til Chrome is the new IE, có những app chỉ chạy dc trên chrome :neutral_face:
[1/14/2019, 1:35:44 AM] [huy]: that's not what makes IE IE
[1/14/2019, 1:41:32 AM] [typescriptpher]: That's IE 6 boy
[1/14/2019, 1:42:00 AM] [huy]: :joy:
[1/14/2019, 1:49:26 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: It’s evil <http://prntscr.com/m6wykg> :sosad:
[1/14/2019, 1:54:28 AM] [tuandh]: emacs cũng có package cho Vim ấy đang xài ngon phết
[1/14/2019, 1:59:19 AM] []: fuck chrome :cry:
[1/14/2019, 2:01:39 AM] [huy]: Do you really have to care about that?
[1/14/2019, 2:01:47 AM] [huy]: Google already has full access to your Google account
[1/14/2019, 2:22:18 AM] []: hic hồi browser wars thì em bé quá chưa hiểu, nhưng đọc mọi người kể thì có vẻ là darkest age of the internet :omg:
[1/14/2019, 3:29:14 AM] [anh bán chuối]: Brave ftw
[1/14/2019, 6:22:53 AM] [FULLCLEARONSTAGE]: #til git filter-branch <https://stackoverflow.com/a/750182/7070779>
[1/14/2019, 12:48:47 PM] [huy]: #til Flags Emojis (emoji cờ quốc gia) được tạo thành bằng cách kết hợp các kí tự regional indicator symbols (<https://en.m.wikipedia.org/wiki/Regional_Indicator_Symbol>). Theo thời gian, với sự biến chuyển của xã hội và tình hình quốc tế, một số emoji đã bị bỏ đi, ví dụ như chuỗi emoji "SU" dành cho Soviet Union, đã bị tách ra làm nhiều emoji nhỏ khác, giống với thực tế lịch sử.
[1/14/2019, 7:48:46 PM] [typescriptpher]: #til <https://github.com/tallesl/Rich-Hickey-fanclub> :okay:
[1/14/2019, 8:17:42 PM] []: <https://ambrevar.xyz/guix-advance/index.html> til guix
[1/14/2019, 11:07:33 PM] [ko luong thien]: The hell
[1/14/2019, 11:13:47 PM] [anh bán chuối]: sao sao
[1/15/2019, 12:01:49 AM] [dat]: #til “What doesn’t kill you makes you stronger” is attributed to the German philosopher, Friedrich Nietzsche. Actually, he said it much more eloquently: “That which does not kill us, makes us stronger.”
[1/15/2019, 3:33:23 AM] [ledongthuc]: #til How to create image in github wiki =&gt; upload to image issue
<https://github.com/RWTH-EBC/AixLib/wiki/How-to:-Add-images-to-the-Wiki>
[1/15/2019, 3:59:22 AM] [// english-ignore]: Thay vì kéo thả thì paste cái hình vô nó cũng upload
[1/15/2019, 5:01:42 AM] [// english-ignore]: #til schemata (pl.)
[1/15/2019, 6:16:19 AM] [typescriptpher]: Mongodb doesnt need schema(ta)
[1/16/2019, 8:14:34 AM] [huynh.cam]: Is it a db?
[1/16/2019, 7:16:59 PM] []: #til <https://disablessl3.com/>
[1/16/2019, 7:19:04 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: <https://xluffy.github.io/post/what-is-difference-between-ssl-tls-https/> :vayvay:
[1/16/2019, 7:55:50 PM] [chua dc luong thien]: #til <https://en.wikipedia.org/wiki/Quickselect>
[1/16/2019, 8:01:12 PM] [ko luong thien]: #til <https://slackthemes.net/#/team_pizza> is a good theming choice (ie. they have enough amount of colors a theme should need)
[1/17/2019, 1:15:06 AM] [tuandh]: @thien cần lắm cái theme dark của body @@
[1/17/2019, 4:13:34 AM] [noob]: #til <https://twitter.com/home> :scream:
[1/17/2019, 5:23:14 AM] [ko luong thien]: sao thế anh?
[1/18/2019, 12:34:26 AM] []: #til mysql co `GROUP_CONCAT` de merge gia tri cua mot column trong `GROUP BY` query
[1/18/2019, 12:47:59 AM] [typescriptpher]: #til <https://itunes.apple.com/us/app/microsoft-remote-desktop-10/id1295203466?mt=12> Microsoft Remote Desktop ngầu lòi, có thể `Cmd + C` để copy ở máy mac, roài `Cmd + P` để paste file ở remote windows :3
[1/18/2019, 12:50:38 AM] [unrealhoang]: :adore:
[1/18/2019, 1:27:17 AM] [typescriptpher]: share dc clipboard, copy/paste dc cả url, text lun :3
[1/18/2019, 1:27:33 AM] [typescriptpher]: thế là tiết kiệm khỏi cần mua cái laptop chạy windows =))
[1/18/2019, 2:16:29 AM] [typescriptpher]: #til <https://docs.microsoft.com/en-us/cpp/vcpkg?view=vs-2017> Open Source C++ Package Manager from M$
[1/18/2019, 3:54:05 AM] [// english-ignore]: #til M$ account cannot use more-than-16-character passwords :rolling_on_the_floor_laughing:
[1/20/2019, 8:03:06 AM] [typescriptpher]: #til SQL Server Enterprise Edition includes both the core database engine and add-on services, with a range of tools for creating and managing a SQL Server cluster. It can manage databases as large as 524 petabytes and address 12 terabytes of memory and supports 640 logical processors (CPU cores)
[1/20/2019, 6:26:15 PM] [dan]: #til Aptronym
[1/20/2019, 7:24:09 PM] [typescriptpher]: #til <https://resources.sei.cmu.edu/downloads/secure-coding/assets/sei-cert-c-coding-standard-2016-v01.pdf>
[1/20/2019, 7:24:19 PM] [typescriptpher]: HTML version: <https://wiki.sei.cmu.edu/confluence/display/c/SEI+CERT+C+Coding+Standard>
[1/20/2019, 8:24:35 PM] [typescriptpher]: #til Redis RCP (Redis Change Proposals) <https://github.com/redis/redis-rcp/blob/master/RCP11.md>
[1/21/2019, 12:01:25 AM] []: #til <https://help.github.com/articles/creating-a-commit-with-multiple-authors/>
[1/21/2019, 12:27:50 AM] [typescriptpher]: @ledongthuc cái này ngon mà :evil: là sao =))
[1/21/2019, 12:33:31 AM] [ledongthuc]: dạ :evil: là thể hiện sự hài lòng 1 cách ranh ma đó anh
[1/21/2019, 12:33:50 AM] [ledongthuc]: vì có cớ chỉ xài redis, không cần xài mấy cái stream query của cái khác
[1/21/2019, 12:37:34 AM] [typescriptpher]: Yeah, cái này mới cho vào Redis 5.0, để ngó coi phát :))
Em dùng production chưa
[1/21/2019, 12:42:41 AM] [ledongthuc]: dạ chưa anh, em mới biết lúc anh gửi cái link ấy luôn
[1/21/2019, 12:43:04 AM] [ledongthuc]: :evil:
[1/21/2019, 12:53:05 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: em nghĩ chưa xài cho production đc đâu, chắc còn dài, vụ stream này em đọc cũng lâu rồi từ blog của bạn brandur ở stripe, trong đó bạn đó cũng so sánh với kafka, bài anh share trên twitter luôn á
[1/21/2019, 1:18:00 AM] [typescriptpher]: #til <https://en.wikipedia.org/wiki/Murphy%27s_law> "Anything that can go wrong will go wrong".
[1/21/2019, 1:32:59 AM] [typescriptpher]: Anh đang nghĩ đến mấy use case với data nhỏ như streaming list events về cho client để làm real-time update
[1/21/2019, 1:41:49 AM] [typescriptpher]: với nó khá light weight có thể dùng cho IOT data stream luôn
[1/21/2019, 1:55:10 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: nó đc cái dễ setup, kiến trúc đơn giản và tận dụng đc redis sẵn có so với kafka, mới xài mà nhảy vào kafka cũng mất công tìm hiểu
[1/21/2019, 2:42:54 AM] [dat]: @snacky
[1/21/2019, 3:11:07 AM] [ledongthuc]: #til “data” is the plural form of “datum”
[1/21/2019, 3:37:15 AM] [ko luong thien]: ```
data.map(datum =&gt; ...)
```
cc @nhducit
[1/21/2019, 3:39:31 AM] [ledongthuc]: :pac: ngày xưa mình không biết chữ datum, toàn đặt là `item` trong case ở trên ^
[1/21/2019, 4:13:57 AM] [tay vịn của anh bán chuối - cty A tìm FE]: Em có biết từ datum nhưng vẫn hay xài item :))
[1/21/2019, 5:10:14 AM] []: quanta = quantum plural :))
[1/21/2019, 5:10:38 AM] []: criteria = criterion plural :))
[1/21/2019, 8:25:19 AM] [// english-ignore]: :til: <https://gitmoji.carloscuesta.me/>
[1/21/2019, 8:48:18 AM] [huy]: :33:
[1/22/2019, 5:19:04 AM] [ledongthuc]: #til <https://msgpack.org> khi bạn muốn nén nhưng lười đổi :disappointed:
[1/22/2019, 5:21:00 AM] [// english-ignore]: cái này có giống protobuf hông ta
[1/22/2019, 5:25:57 AM] [ledongthuc]: hình như cũng giống về mục đích serialize/deserialize. Nhưng mà bản chất là msgpack nó base trên JSON để làm việc binary encoding
[1/22/2019, 5:26:42 AM] [ledongthuc]: mấy cái như type checking gì đấy lại không có như protobuf
[1/22/2019, 5:27:01 AM] [ledongthuc]: msgpack thật ra simple hơn chỉ là encode JSON -&gt; binary
[1/22/2019, 5:27:19 AM] [// english-ignore]: :bow:
[1/22/2019, 5:29:11 AM] [ledongthuc]: #til datum’s a word in Sweden/Gemany/Czech, means date
[1/22/2019, 5:29:50 AM] [ledongthuc]: @nhducit <@U240KFCLS> cẩn thận khi xài :disappointed:
[1/22/2019, 5:30:14 AM] [ledongthuc]: hình như chung 1 dòng ngôn ngữ ấy luôn đều hiểu datum là date
[1/22/2019, 5:42:03 AM] [// english-ignore]: `sex` = :six: trong tiếng Thuỵ Điển
[1/22/2019, 5:46:24 AM] [ledongthuc]: :cggt: tốt nhất ko nên nói, cty mình toàn nam
[1/22/2019, 6:03:03 AM] [huynh.cam]: protobuf có schema cơ mà msgpack thì ko
[1/22/2019, 6:04:03 AM] [huynh.cam]: một cái lợi khác của msgpack là nó hỗ trợ extension
[1/22/2019, 6:04:36 AM] [huynh.cam]: vd bạn có thể encode `DateTime` dưới dạng binary và gán cho nó một cái internal type flag
[1/22/2019, 6:05:18 AM] [huynh.cam]: cái này rất là hữu dụng khi bạn phải encode/decode một cái gì đó như kiểu double chẳng hạn
[1/22/2019, 6:06:54 AM] [huynh.cam]: <https://github.com/msgpack/msgpack/blob/master/spec.md#extension-types> :grin:
[1/22/2019, 6:07:30 AM] [huynh.cam]: app bên mình chuyển từ JSON -&gt; msgpack khi giao tiếp với mobile client, payload giảm hơn 40%
[1/22/2019, 6:08:30 AM] [huynh.cam]: mà encode/decode lại nhanh hơn
[1/22/2019, 6:08:42 AM] [huynh.cam]: in a nutshell, dùng msgpack đi đừng dùng json :grin:
[1/22/2019, 6:09:32 AM] [ledongthuc]: :full_moon_with_face: mình cũng nghĩ nên chuyển qua. Vì đứng từ phía mình mà thấy thì việc chuyển đổi cũng ko tốt nhiều công lắm
[1/22/2019, 6:10:06 AM] [ledongthuc]: bên mình đang thử benchmark mấy case có sẵn trong hệ thống đang chạy coi kết quả sao rồi apply đại trà
[1/22/2019, 6:10:38 AM] [ledongthuc]: thật ra căn bản nó cũng là JSON dc encode lại dạng binary thôi, nên cũng cảm giác ko có gì quá nhiều thay đổi
[1/22/2019, 6:21:05 AM] [// english-ignore]: em cháu thích type/schema thì có nên nhảy qua protobuf không :thinkhard:
[1/22/2019, 6:42:50 AM] [minh.nguyen]: Thích thì cứ nhảy thôi :thinkhard:
[1/22/2019, 6:47:38 AM] [// english-ignore]: trước giờ k có xài cả hai :omg:
[1/22/2019, 7:04:35 AM] [huynh.cam]: Browser thi chac json van nhanh hon ay
[1/22/2019, 7:05:19 AM] [typescriptpher]: nói họ tưởng thật thì tiu :roflrofl:
[1/22/2019, 7:09:23 AM] [unrealhoang]: yep, với lại json readable
[1/22/2019, 7:09:29 AM] [unrealhoang]: msgpack thì phải có tool
[1/22/2019, 7:09:45 AM] [unrealhoang]: nên trừ phi hot loop
[1/22/2019, 7:09:54 AM] [unrealhoang]: cực kì quan trong dung lượng
[1/22/2019, 7:10:00 AM] [unrealhoang]: thì hãy xài msgpack
[1/22/2019, 7:10:26 AM] [unrealhoang]: còn về speed chưa chắc đã nhanh hơn json trong mấy ngôn ngữ high level như elixir/ruby
[1/22/2019, 7:11:13 AM] [huynh.cam]: Elixir thi confirm msgpack nhanh hon
[1/22/2019, 7:11:17 AM] [huynh.cam]: Ruby thi ko biet
[1/22/2019, 7:12:01 AM] [huynh.cam]: Còn readability thì ... tụi nó là machine mà
[1/22/2019, 7:14:00 AM] [ledongthuc]: mà nhanh là mọi người tính thời gian encode/decode + thời gian transfer luôn chứ nhỉ?
Vì nếu thật ra chắc 90% case đơn giản thì cũng ko cần nhanh làm gì, hoặc là nhanh ko đủ nhiều để tradeoff với chuyện dễ debug.
Chỉ có vài case mình cần data nó nhẹ bớt để transfer qua internet nhanh hơn thì mới cần
[1/22/2019, 7:14:49 AM] [unrealhoang]: yep
[1/22/2019, 7:15:11 AM] [unrealhoang]: readability ở đây là nói người đọc mà
[1/22/2019, 7:17:24 AM] [unrealhoang]: mà encode/decode nếu đầu tư lượng thời gian ngang nhau để viết lib thì msgpack hơn
[1/22/2019, 7:17:51 AM] [unrealhoang]: tuy nhiên usecase của json hơn hẳn nên khả năng cao là nhiều người đã bỏ time vào improve json rồi
[1/22/2019, 8:06:15 AM] [huy]: Vậy nếu cần security thì xài msgpack somewhat bảo đảm seciruty :all-the-things:
[1/22/2019, 8:44:39 AM] []: #til: Git diff file between two repos
```
git remote add other-repo git@github.com:repository.git:master
git remote update
git diff origin/master:path/file2 other-repo/master:path/file1
```
[1/22/2019, 2:36:07 PM] [dat]: sex = 6 trong tieng Latin, chac Thuy Dien cung anh huong
[1/22/2019, 7:26:33 PM] [unrealhoang]: @snacky yep, seciruty sẽ được đảm bảo :roflrofl:
[1/22/2019, 9:23:45 PM] [huy]: :roflrofl:
[1/24/2019, 11:25:45 AM] [huy]: #til Mega Commuter or Super Commuter: People who fly to work. <http://www.bbc.com/capital/story/20141118-the-worlds-longest-commutes>
[1/24/2019, 1:14:03 PM] [ledongthuc]: #til postgres and phrase search: tsvector, tsquery
[1/24/2019, 5:57:46 PM] [huy]: On which planet are you come from?
[1/24/2019, 6:02:59 PM] []: I was thinking about the ISS but since you did ask I came from Pluto :hugging_face:.
[1/24/2019, 6:04:10 PM] [huy]: that place might be cold
[1/24/2019, 6:04:21 PM] [huy]: probably too cold so it affects the way you're thinking
[1/24/2019, 6:04:23 PM] [huy]: :roflrofl:
[1/24/2019, 6:05:40 PM] []: How come anh Huytd still thức :o
[1/24/2019, 6:09:24 PM] []: Quen mat mới ngủ dậy ngáo quá :roflrofl:
[1/24/2019, 6:10:34 PM] [huy]: :)))
[1/24/2019, 6:50:28 PM] [huy]: #til Get any NPM package's source code <https://huytd.github.io/random/get-npm-package-source.html>
[1/24/2019, 8:49:20 PM] [ko luong thien]: Sao giờ này mới có người làm nhỉ..
[1/24/2019, 10:53:34 PM] [ko luong thien]: #til <https://github.com/atom/xray>
[1/24/2019, 10:56:13 PM] [unrealhoang]: cũng lâu rồi mà, học Rút đi @thien
[1/24/2019, 10:56:34 PM] [ko luong thien]: the hell
[1/24/2019, 10:56:43 PM] [ko luong thien]: giờ mới để í nó ghi chữ Rust
[1/24/2019, 11:09:16 PM] []: #til Quick look JSON, `brew cask install quicklook-json`
[1/24/2019, 11:43:49 PM] [huy]: Làm what
[1/25/2019, 10:05:36 AM] [huy]: uhm :))
[1/25/2019, 10:05:53 AM] [huy]: ủa mà sao máy e ko hiện font bold luôn
[1/25/2019, 6:28:32 PM] []: I blame :huytd_finish: =))
[1/26/2019, 1:11:40 AM] [typescriptpher]: #til <https://www.google.com/teapot> Tea Pot from Google
[1/26/2019, 2:05:05 AM] [thai]: Really :open_mouth:
```418 I'm a teapot (RFC 2324)
This code was defined in 1998 as one of the traditional IETF April Fools' jokes, in RFC 2324, Hyper Text Coffee Pot Control Protocol, and is not expected to be implemented by actual HTTP servers. However, known implementations do exist. An Nginx HTTP server uses this code to simulate goto-like behaviour in its configuration.```
[1/27/2019, 8:34:22 PM] [dan]: #til Stemming <https://en.wikipedia.org/wiki/Stemming>
[1/29/2019, 12:59:58 AM] [// english-ignore]: #til FUBAR <https://en.wikipedia.org/wiki/List_of_military_slang_terms#FUBAR>
[1/29/2019, 1:08:33 AM] [// english-ignore]: #til con rắn tự cắn đuôi gọi là ouroboros <https://en.wikipedia.org/wiki/Ouroboros>
[1/30/2019, 8:15:31 AM] [Cậu Làm Vườn]: #til `tc` for traffic control
[1/30/2019, 8:16:26 AM] [Cậu Làm Vườn]: <https://twitter.com/b0rk/status/1090458969234173953>
[1/30/2019, 3:09:39 PM] [ledongthuc]: #til postgres generate_series(start, stop, steps)
[1/30/2019, 5:30:33 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: generate data for testing :vayvay:
[1/30/2019, 6:38:15 PM] [ledongthuc]: :thinking_face: có ai dùng cái này để join với data để return data theo ngày không nhỉ?
[1/30/2019, 6:39:32 PM] [ledongthuc]: đang tính thử làm report kiểu đó. Dạng như:
| date 1 | outcome | 0 |
| date 1 | income | 0 |
| date 2 | outcome | 50 |
| date 2 | income | 100 |
| date 3 | outcome | 4 |
| date 3 | income | 70 |
| date 4 | outcome | 0 |
| date 4 | income | 0 |
[1/30/2019, 6:40:02 PM] []: mah favourite one
```
WITH time_range AS (
select generate_series('2015-12-31 00:00:00', '2016-12-31 00:00:00', '1 day'::interval) AS day_d
),
select generate_series(CAST((NOW() + INTERVAL '-30 day') AS date), CAST((NOW() + INTERVAL '-0 day') AS date), '1 day'::interval) AS day_d
```
[1/30/2019, 6:43:51 PM] [ledongthuc]: :trollface: vậy là có à, để chiều vọc thử. Tin tưởng CTO của cty hàng đầu trong ứng dụng ăn uống tại đó nha
[1/31/2019, 7:33:47 PM] [vthang]: #til Notion web clipper
[2/2/2019, 11:57:46 PM] [anh bán chuối]: #til EBS IO Burst Balance
[2/3/2019, 12:10:05 AM] [anh bán chuối]: btw chuyển qua Provisioned IOPS SSD rồi mà cái giá tính `$0.065 per provisioned IOPS-month` là sao @xluffy :smile:
[2/3/2019, 12:13:32 AM] [anh bán chuối]: tui để max (size * 50, 1100 IOPS cho volume 22Gb) ko biết cuối tháng bị charge nhiều ko :v
[2/3/2019, 12:20:47 AM] [anh bán chuối]: oh mới coi lại dc cái graph - tính ra lúc peak tui cũng chỉ write 90 ops/s nên chắc chút giảm về 100 :v
[2/3/2019, 12:29:24 AM] [anh bán chuối]: hmm ko đúng :v base của cái cũ là 100 rồi, nhìn kỹ lại thì 300-400 OK hơn
[2/3/2019, 2:24:15 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: `Provisioned IOPS SSD` là `io1` hỉ, zô cái <https://calculator.s3.amazonaws.com/index.html> bấm cost thử
[2/3/2019, 2:24:42 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: `io1` thì nó tính giá dựa trên 2 cái, `size` + `custom IOPS`
[2/3/2019, 3:18:41 AM] [anh bán chuối]: thanks!
[2/3/2019, 3:22:03 AM] [anh bán chuối]: ko thấy có storage hay volume thì trên cái price calc :v
[2/3/2019, 8:57:31 AM] [toanha]: ```
with installs as (
select date_trunc('day', inserted_at) as mday, count(*)
from mo_user
where inserted_at &gt;= $1 and inserted_at &lt; $2
group by mday
)
select m_date,
coalesce(installs.count, 0) as install_count
from generate_series ($1::timestamp, $2::timestamp, '1 day'::interval) m_date
left join installs on m_date = installs.mday
```
[2/4/2019, 6:39:10 AM] [dan]: #til Ad Hominem
[2/5/2019, 4:31:14 AM] [minh.nguyen]: Source: <https://github.com/ruby/ruby/blob/trunk/lib/rubygems/remote_fetcher.rb#L356>
[2/5/2019, 4:31:35 AM] [minh.nguyen]: Just wonder when it will support GCP or Azue :lol:
[2/5/2019, 4:33:54 AM] [minh.nguyen]: The code was added 5 years ago: <https://github.com/rubygems/rubygems/pull/856>
[2/6/2019, 4:48:03 AM] [Cậu Làm Vườn]: #til css `opacity` can create a new stacking context
[2/6/2019, 4:50:47 AM] [ko luong thien]: what do u mean by “stacking context”?
[2/6/2019, 4:51:16 AM] [ko luong thien]: is it some kind of browser’s rendering implementation detail?
[2/6/2019, 4:51:23 AM] [ko luong thien]: is this why it’s supposed to be fast?
[2/6/2019, 4:54:37 AM] [Cậu Làm Vườn]: z-index stuffs
[2/6/2019, 4:55:30 AM] [ko luong thien]: nà ní? I demand a trial by ~combat~ codepen
[2/6/2019, 4:59:47 AM] [Cậu Làm Vườn]: <https://codepen.io/philipwalton/pen/dfCtb>
[2/6/2019, 5:01:27 AM] [ko luong thien]: chưa hiểu lắm..
[2/6/2019, 5:02:18 AM] [Cậu Làm Vườn]: Nếu không thay đổi opacity của red container thì nó phải nằm trên, vì có z-index là 1.
[2/6/2019, 5:06:36 AM] [Cậu Làm Vườn]: Vì việc đổi opacity khác 1 một tạo ra stacking context mới, nên coi như cái z-index của red chỉ có ý nghĩa trong phạm vi cái stacking context đó thôi -&gt; nó xếp theo appearance order
[2/6/2019, 5:08:14 AM] [ko luong thien]: nice :+1:
[2/6/2019, 5:08:32 AM] [Cậu Làm Vườn]: &gt; In addition to opacity, several newer CSS properties also create stacking contexts. These include: transforms, filters, css-regions, paged media, and possibly others. As a general rule, it seems that if a CSS property requires rendering in an offscreen context, it must create a new stacking context.
[2/6/2019, 5:09:12 AM] [ko luong thien]: I see
[2/6/2019, 5:09:12 AM] [ko luong thien]: <https://stackoverflow.com/a/11742116>
[2/6/2019, 5:50:18 AM] []: ai biết lỗi này là gì ko â?
[2/6/2019, 6:35:24 AM] []: Nhầm channel rồi bạn, Python chắc bạn qua #newbie hoặc <#C0TUQGY83|random> hỏi nha
[2/6/2019, 7:15:40 AM] []: à mình fix rồi
[2/6/2019, 7:15:45 AM] []: lồi do python3
[2/6/2019, 7:15:45 AM] []: :smile:
[2/6/2019, 12:36:58 PM] [ko luong thien]: #til <https://en.wikipedia.org/wiki/Pneumonoultramicroscopicsilicovolcanoconiosis> while looking at CSS's `word-break` examples..
[2/7/2019, 6:12:07 AM] [// english-ignore]: lạnh không? :wink:
[2/7/2019, 6:12:44 AM] [ledongthuc]: :sweat_smile: quéo hết cả người. Mới qua hôm t2, tuyết khắp mặt trận
[2/7/2019, 6:14:11 AM] [// english-ignore]: chào mừng đến Bắc Âu :omg:
[2/7/2019, 6:18:12 AM] [noob]: Sướng bạn :omg:
[2/7/2019, 6:41:47 AM] [ledongthuc]: :joy::joy::joy:
[2/7/2019, 6:42:32 AM] [ledongthuc]: Hồi sáng mém đi lộn tàu
[2/7/2019, 6:42:59 AM] [ledongthuc]: Cầm vé SL của stockholm mà mém leo lên SJ
[2/7/2019, 6:44:30 AM] [// english-ignore]: Tàu ở bển mắc không? Một tháng bên này phải trả 113e tiền tàu :disappointed:
[2/7/2019, 6:46:13 AM] [tay vịn của anh bán chuối - cty A tìm FE]: Xmax hả sếp @ledongthuc
[2/7/2019, 6:50:45 AM] [ledongthuc]: Bên này 870kr 1 tháng. Mua 1 năm thì 750kr/1 tháng
[2/7/2019, 6:52:04 AM] [ledongthuc]: @nhducit tết kỷ hợi nha
[2/7/2019, 6:56:17 AM] [// english-ignore]: :33:
[2/7/2019, 6:57:15 AM] [ledongthuc]: Ủa sao bên đó mắc quá vậy?
[2/7/2019, 7:46:15 AM] [huy]: Kinh nghiệm là phone cty đừng nên xem porn trên đố
[2/7/2019, 7:46:24 AM] [huy]: Cty ko biết nhưng cản giác tội lỗi
[2/7/2019, 7:47:36 AM] [noob]: Vl ai lại xem porn trên phone :face_palm:
[2/7/2019, 9:15:27 AM] [ledongthuc]: :unamused: quăng cái máy trên cty rồi
[2/7/2019, 9:15:43 AM] [ledongthuc]: Chừng nào cần recharge tiền cho máy cá nhân thì lôi nó ra
[2/7/2019, 9:28:28 AM] [huy]: e thì dùng máy cty để nghe audiobook với bản đồ, xong đem về cho thằng con chơi
[2/7/2019, 10:16:09 AM] [huy]: @nhi.luong các câu hỏi thì bạn vui lòng post vô #general hoặc <#C0TUQGY83|random> hoặc bất kì room nào liên quan đến câu hỏi nhé. room <#C16AY670U|til> là để chia sẻ kinh nghiệm (như trong phần topic có ghi). P/S: mình chưa xài :pac:
[2/7/2019, 2:01:45 PM] []: ok thank you bạn, mình tưởng chia sẽ kinh nghiệm cũng giống như Q/A haha
[2/9/2019, 4:09:32 AM] [SFzxc]: #til #github Open up any git repository and press `t`. You can now search for the name of any file in the repository
[2/9/2019, 4:11:56 AM] [SFzxc]: can also jump to a function when reviewing code
[2/10/2019, 6:39:15 PM] [dan]: #til `target.addEventListener(type, listener, { once: true })`
[2/11/2019, 3:02:06 AM] [ledongthuc]: #til <https://github.com/tmux-plugins/tmux-resurrect> :skull:
[2/12/2019, 12:10:49 AM] [dan]: #til <https://github.com/philipwalton/flexbugs>
[2/12/2019, 5:50:12 AM] [ledongthuc]: #til sô đa cho thêm chút muối uống ngon ghê
<https://www.healthline.com/nutrition/carbonated-water-good-or-bad>
[2/12/2019, 11:37:41 AM] [huy]: sô đa + sữa đặc + lòng đỏ trứng gà
[2/12/2019, 11:39:38 AM] [ledongthuc]: :cry: hồi nhỏ bị bệnh dc mẹ cho uống 1 lần duy nhất
[2/12/2019, 11:39:55 AM] [ledongthuc]: chẳng nhớ ói ỉa ra sao mà không bao giờ dc uống lại
[2/12/2019, 11:40:41 AM] [huy]: giờ làm lại ún đi bác
[2/12/2019, 11:40:43 AM] [huy]: giải khác cực kì
[2/12/2019, 11:41:33 AM] [ledongthuc]: :thinking_face: vậy để 1 tối T6 nào đó thử
[2/12/2019, 8:36:42 PM] [typescriptpher]: #til <https://github.com/google/sanitizers>
[2/12/2019, 8:37:34 PM] [typescriptpher]: <https://sonthuyvu.wordpress.com/2014/05/24/soda-sua-trung-ga-tuyet-chieu-dan-gian-giup-tang-can-nhanh/>
Soda + trung ga là mẹo để tăng cân đó @ledongthuc :roflrofl:
[2/12/2019, 8:38:07 PM] [unrealhoang]: <https://www.rust-lang.org>
[2/12/2019, 8:38:13 PM] [ledongthuc]: :okay: vậy nghỉ uống luôn, em đang béo bụng
[2/12/2019, 8:38:20 PM] [typescriptpher]: :okay:
[2/12/2019, 8:38:34 PM] [unrealhoang]: :roflrofl:
[2/12/2019, 8:38:48 PM] [typescriptpher]: Hôm trước rủ code Rust trên facebook thì bơ mềnh = )))
[2/12/2019, 8:39:12 PM] [unrealhoang]: Ấy tết bận đi trượt tuyết
[2/12/2019, 8:39:15 PM] [unrealhoang]: Quên mất
[2/12/2019, 8:39:52 PM] [unrealhoang]: Không là comment: “or javascript” :roflrofl:
[2/12/2019, 8:40:07 PM] [typescriptpher]: biết mà :roflrofl:
[2/12/2019, 8:40:32 PM] [unrealhoang]: Ae hiểu nhau quá :okay:
[2/12/2019, 8:40:47 PM] [unrealhoang]: Tháng 3 chừng nào qua anh
[2/12/2019, 8:41:05 PM] [unrealhoang]: Qua sớm chứ cuối tháng em ra HN đó
[2/12/2019, 8:41:12 PM] [unrealhoang]: :roflrofl:
[2/12/2019, 8:41:30 PM] [typescriptpher]: :roflrofl:
[2/12/2019, 8:41:41 PM] [typescriptpher]: bể kèo qua Nhật roài, tháng 3 anh bận như điên :roflrofl:
[2/12/2019, 8:41:58 PM] [typescriptpher]: cuối tháng 3 về ping anh :))
[2/12/2019, 8:42:05 PM] [unrealhoang]: Oke
[2/12/2019, 8:42:34 PM] [unrealhoang]: Ra HN thăm họ hàng, chắc cũng có ngày free
[2/12/2019, 8:42:47 PM] [typescriptpher]: Hình như mềnh còn chưa gặp nhaooo bao h :roflrofl:
Nhớ đeo cái biển: "I am unreal" :roflrofl:
[2/12/2019, 8:43:35 PM] [unrealhoang]: :roflrofl:
[2/12/2019, 8:43:41 PM] [typescriptpher]: ah, nhìn cái avatar mới nhớ để lúc nào cài lại FF IX chơi lại =)))
[2/12/2019, 8:43:53 PM] [unrealhoang]: Có bản mobile đó anh
[2/12/2019, 8:45:09 PM] [typescriptpher]: Uah, anh mua bản Android rồi, cơ mà giờ chuyển qua iOS :roflrofl:
[2/12/2019, 8:45:33 PM] [typescriptpher]: <https://en.another-eden.jp> -&gt; đang chơi game này, hình ảnh đẹp, nhạc hay, game play cũng hay :))
[2/12/2019, 8:46:56 PM] [typescriptpher]: composer với writer của Chrono :))))
[2/12/2019, 8:47:34 PM] [unrealhoang]: Ok để em check thử
[2/12/2019, 8:47:36 PM] [unrealhoang]: :))
[2/12/2019, 8:48:20 PM] [unrealhoang]: Có recommendation từ near neighbor chắc sẽ ngon
[2/12/2019, 9:49:30 PM] [話せる森林]: Ông hôm nào về thế. 30 tháng 4 tôi cũng về.
[2/12/2019, 10:27:22 PM] [unrealhoang]: :think:
[2/12/2019, 10:27:33 PM] [unrealhoang]: 1 tháng 4 tôi về lại Nhật rồi
[2/12/2019, 10:27:34 PM] [unrealhoang]: :roflrofl:
[2/12/2019, 10:47:24 PM] [typescriptpher]: về kịp cá tháng 4 :roflrofl:
[2/13/2019, 5:23:55 PM] [話せる森林]: #til 13 năng nói chuyện 14 nhiều chocolates. Happy valentines anh em.
[2/13/2019, 5:25:24 PM] [huy]: KLQ nhưng hình như chỉ có ở Nhật mới có chuyện valentine con gái tặng chocolate cho con trai
[2/13/2019, 5:25:27 PM] [huy]: Ở mấy nước
[2/13/2019, 5:25:28 PM] [huy]: khác
[2/13/2019, 5:25:33 PM] [huy]: toàn con trai phải tặng quà
[2/13/2019, 6:06:09 PM] [tay vịn của anh bán chuối - cty A tìm FE]: #til For all media, the term canvas describes "the space where the formatting structure is rendered." The canvas is infinite for each dimension of the space, but rendering generally occurs within a finite region of the canvas, established by the user agent according to the target medium. For instance, user agents rendering to a screen generally impose a minimum width and choose an initial width based on the dimensions of the viewport. User agents rendering to a page generally impose width and height constraints. Aural user agents may impose limits in audio space, but not in time.
[2/13/2019, 6:06:16 PM] [tay vịn của anh bán chuối - cty A tìm FE]: <https://www.w3.org/TR/CSS2/intro.html#canvas>
[2/13/2019, 6:27:54 PM] []: hình như cũng chỉ có Nhật mới tặng lại bánh quy :thinking_face:
[2/13/2019, 9:42:32 PM] []: Nhà em theo nhật nên :omg:
[2/13/2019, 10:29:48 PM] [huy]: sướng quá
[2/15/2019, 7:37:59 AM] [ledongthuc]: :see_no_evil:
[2/15/2019, 7:46:56 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :kappa: `git add .` thì gom cả mớ rác à, rồi `gogogo` gõ dài mỏi tay phết
[2/15/2019, 7:58:51 AM] [ledongthuc]: :cry: tại em lười quá lười.
[2/15/2019, 7:59:09 AM] [ledongthuc]: sợ nhấn nhầm nên em để nó dài dài tí
[2/15/2019, 8:21:47 AM] []: nếu anh xài sh nào có auto complete thì có để dài đến mấy anh cũng chết vì `&lt;tab&gt; &lt;return&gt;` =))
[2/15/2019, 8:22:18 AM] [ledongthuc]: :okay: cũng đúng, mong là không nhấm nhầm quá 3 lần
[2/15/2019, 8:23:13 AM] [ledongthuc]: thật ra trường hợp nhấn xong rồi mới nhớ ra chỗ sót bị thường gặp hơn
[2/15/2019, 8:23:40 AM] []: commit them rồi squash lại cũng dược mà :smile:
[2/15/2019, 8:28:18 AM] [ledongthuc]: mình không thích squash lắm, nhưng ok, cũng là 1 option để phòng hờ, còn nếu chỉ có 1 mình mình trên branch đó thì nhanh tay reset vậy
[2/15/2019, 12:56:17 PM] [// english-ignore]: :til: ligers and tigons :lion_face: :tiger: <https://en.m.wikipedia.org/wiki/Liger>
[2/15/2019, 12:59:15 PM] [dndn]: #til Vue v-for: &lt;span v-for="(_, index) in 10"&gt; {{ index }}&lt;/span&gt; start with 0
[2/15/2019, 8:21:33 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: btw, mình thích standard vầy hơn cho func
```
gogogo() {
...
}
```
hơn là kiểu `function gogogo () {}` :smile:
[2/16/2019, 7:47:25 AM] [imah]: Vegito &amp; Gogeta :sweat_smile:
<https://www.quora.com/What-is-the-difference-between-Vegito-and-Gogeta>
[2/17/2019, 10:40:03 PM] [meowwwwwwwwwwwwwwww]: #til Ruby regex: `/\h{20}\z/`
[2/18/2019, 7:12:49 PM] []: Nice post - still useful regardless of your current level
<https://medium.com/@juliahaigh/how-to-feel-less-overwhelmed-as-a-developer-79bc816709de>
[2/18/2019, 7:16:35 PM] [話せる森林]: #til Trong tiếng Nhật kí tự này `ノ` đọc là `nô` dùng để phiên âm tiếng nước ngoài, có thể hiểu là No trong tiếng anh. Nhưng mà khi hỏi ai đó có tham gia hay đồng ý một cái gì đó hay không. Thì nó lại có nghĩa là `I raised my hand`.
[2/18/2019, 8:59:35 PM] [trung]: @minami.dev
`\h` What it mean?
-&gt; match a "h" character?
[2/18/2019, 10:15:40 PM] [meowwwwwwwwwwwwwwww]: hexa characters =))
[2/19/2019, 2:49:15 AM] [ledongthuc]: #til bulk vs batch
<https://dictionary.cambridge.org/dictionary/english/bulk>
<https://dictionary.cambridge.org/dictionary/english/batch>
process bulk != process batch
[2/19/2019, 9:20:29 AM] [thai]: #til English: when to double a consonant before adding -ed or -ing to a verb: <https://speakspeak.com/resources/english-grammar-rules/english-spelling-rules/double-consonant-ed-ing>, trước giờ toàn làm theo thói quen :disappointed:
[2/19/2019, 12:14:16 PM] [huy]: #tifu: &lt;button&gt; cannot be a flex container
[2/19/2019, 1:34:44 PM] []: #til Cropping images in multiple shapes with `clip-path` <https://css-tricks.com/clipping-masking-css/>
[2/19/2019, 2:14:51 PM] [// english-ignore]: Thấy theo thói quen dễ hơn :face_with_rolling_eyes: kiểu nó tự nhiên thay vì phải nhớ rule
[2/20/2019, 4:37:54 AM] []: #til <https://avro.apache.org/docs/1.8.1/spec.html>
[2/20/2019, 4:58:51 AM] [Cậu Làm Vườn]: "Oh, that does not look right. Double then"
[2/20/2019, 5:09:36 AM] [// english-ignore]: quai not? <https://jsfiddle.net/1a83dbL7/>
[2/20/2019, 6:05:03 AM] [ko luong thien]: sau đó thì google confirm
[2/20/2019, 6:06:33 AM] [ko luong thien]: <https://stackoverflow.com/questions/35464067/flexbox-not-working-on-button-or-fieldset-elements>
[2/20/2019, 6:08:37 AM] [// english-ignore]: Ra là vậy :thinkhard:
[2/20/2019, 6:14:02 AM] [// english-ignore]: :waving_white_flag:
[2/20/2019, 6:17:10 AM] [ko luong thien]: <https://css-tricks.com/flexbox-truncated-text/>
[2/20/2019, 6:44:46 AM] [// english-ignore]: css có nhiều cái hidden trick quạ, chả trách quần chúng la ó om sòm
[2/20/2019, 9:52:55 AM] [huy]: cơ bản flexbox tạch trên nhiều browser cũ :okay:
[2/20/2019, 11:16:47 AM] [minh.nguyen]: #til Despacito chuẩn bị 6 tỷ view <https://www.youtube.com/watch?v=kJQP7kiw5Fk>
[2/21/2019, 12:42:42 AM] [dan]: #til <https://ruby-doc.org/stdlib-2.0.0/libdoc/forwardable/rdoc/Forwardable.html>
[2/21/2019, 2:56:53 AM] [Cậu Làm Vườn]: #til `addEventListener` `capture` flag
[2/21/2019, 2:59:32 AM] [Cậu Làm Vườn]: :ie: :chicken: :okay:
[2/21/2019, 4:49:42 AM] [ko luong thien]: This is :chrome: to me
[2/22/2019, 4:52:01 AM] []: #til encrypt file with gnu’s `gpg`
[2/22/2019, 5:29:42 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: and sign
[2/22/2019, 5:59:03 AM] []: @xluffy ố new :omg: gpg cứu tinh bởi server em không được cài thêm cái gì hết :omg:
[2/22/2019, 8:11:03 AM] [dat]: nhờ lưu crypto key mới biết cái này
[2/22/2019, 8:12:26 AM] [ledongthuc]: #til <http://shisaa.jp/postset/postgresql-full-text-search-part-1.html>
[2/24/2019, 9:35:07 AM] []: #til cái súng bắn vịt hoạt động sao :))) <https://youtu.be/Nu-Hoj4EIjU>
[2/24/2019, 10:58:40 PM] [// english-ignore]: #til `.well-known/change-password` <https://github.com/WICG/change-password-url/blob/gh-pages/explainer.md>
[2/26/2019, 12:03:06 AM] [ledongthuc]: #til Poison != Venom
Poison là loại độc bị nhiễm thông qua ăn, uống, liếm, đụng phải hoặc hít phải.
Venom là do bị trực tiếp tiêm vào qua bị cắt, bị chích hay bị đâm gì đó (độc lúc này sẽ đi theo đường máu).
Và có 1 vài con vừa có poison, vừa có venom.
[2/26/2019, 12:14:42 AM] [noob]: dc bạn ơi, cần lắm những #til
[2/26/2019, 12:14:46 AM] [noob]: như thế lày
[2/26/2019, 12:42:44 AM] [SFzxc]: tính ra ulti của venomancer là poison a @mquy nhỉ :omg:
[2/26/2019, 2:44:01 AM] [Dz]: #til tz_aware=False sẽ ngăn mongoengine/pymongo tự cộng timezone khi lấy dữ liệu
[2/26/2019, 2:45:42 AM] [unrealhoang]: @tobiwon thì tên skill là poison nova còn gì :oh:
[2/26/2019, 4:18:47 AM] [SFzxc]: ko để ý nơi a @unrealhoang :omg:
[2/26/2019, 5:11:54 AM] [話せる森林]: `Toxic` là thuốc độc nói chung. `Venom` là độc bị nhiễm do từ sinh vật. Còn `Poison` là độc bị nhiễm do bị đầu độc. Đúng không nhỉ?
[2/26/2019, 5:12:08 AM] [話せる森林]: #til <https://www.growingwiththeweb.com/> Trang này có nhiều bài viết hay hay.
[2/26/2019, 5:18:34 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: ớ, vậy Viper cũng poison à
[2/26/2019, 7:33:14 AM] [ledongthuc]: @bach.do.ucl toxin hay toxic nhỉ? toxin hình như là mấy cái chất độc dc thải ra trong tế bào như kiểu chất dơ ấy đúng ko nhỉ?
[2/26/2019, 8:07:34 AM] [ledongthuc]: <https://www.reddit.com/r/DotA2/comments/57tkvv/is_venomancer_poisonous_or_venomous_how_does_his/>
:thinking_face: có cả thread tranh luận mấy cái này thật luôn à
[3/1/2019, 1:09:03 AM] [meowwwwwwwwwwwwwwww]: #til Float values comparing in MySQL
[3/6/2019, 8:45:46 AM] [anh bán chuối]: #til :ie: ```
ActiveSupport::Inflector.titleize('đoàn dự')
$ đoàn Dự
```
[3/7/2019, 1:14:28 AM] [hasagi]: #til: `=TEXTJOIN(", ",TRUE,B1:B121)`
[3/7/2019, 11:52:16 AM] [huy]: #til Slack lại đổi font/design (cc @thien <@U0GF4T4D9>)
[3/7/2019, 11:53:08 AM] [huy]: #til Ngày 8/3 ko có mang tính quốc tế như chúng ta vẫn tưởng <http://www.rferl.org/content/womens_day_feature_soviet_socialist_origins_100th_anniversary/2330712.html|www.rferl.org/content/womens_day_feature_soviet_socialist_origins_100th_anniversary/2330712.html> chỉ còn ở các nước xhcn mà thôi
[3/7/2019, 3:51:18 PM] [huy]: #til Algebraic Data Type vs Abstract Data Type
[3/7/2019, 6:59:48 PM] [SFzxc]: #til :ie: Using scratch containers with Go app is a more secure and lightweight method to deploy Go containers.
[3/7/2019, 6:59:55 PM] [SFzxc]: Ex:
```
# build stage
FROM golang:alpine AS builder
WORKDIR /usr/local/go/src
COPY main.go .
RUN CGO_ENABLED=0 GOOS=linux go build -o main .
# final stage
FROM scratch
WORKDIR /
COPY --from=builder /usr/local/go/src/main main
COPY html html
EXPOSE 8080
ENTRYPOINT ["/main"]
```
[3/7/2019, 7:19:17 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: #til: trên Ubuntu có 1 package `secure-delete` và tương ứng có command `srm` để safe delete (overwrite file), trên macOS thì ko kiếm đc cái nào tương tự có thể xài `rm -fP`
```
-P Overwrite regular files before deleting them. Files are overwritten three times, first with the byte
pattern 0xff, then 0x00, and then 0xff again, before they are deleted.
```
Có thể viết 1 func như vầy để tiện xài khi cần xóa 1 cách tương đối an toàn (muốn an toàn hơn thì tìm mấy chương trình wipe với số lần overwrite thay đổi đc)
```
_log() {
printf "\x1B[2;32m"
echo "[LOG]" "[$(date)]:" "$*"
printf "\x1B[0m"
}
srm() {
read -p "Are you sure to delete $1? (y/n) " yn
if [ "${yn}" == "y" ]; then
rm -Pfv "$1"
_log "Secure deleted $1"
else
_log "Don't delete"
fi
}
```
[3/7/2019, 7:43:23 PM] [manhdv]: tai sao phai overwrite truoc khi delete vay @xluffy?
[3/7/2019, 7:45:45 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: bản chất của việc delete thông thường là un-ref file đó chứ thức sự thì nó vẫn trên đĩa cứng (cách mà các chương trình phục hồi file hoạt động). Overwrite nhiều lần là 1 cách an toàn để xóa mà ko có khả năng phục hồi lại file đó thôi anh, file vớ vẩn thì ko sao, nhưng có n~ file như private-key, secret-key thì muốn an toàn nên overwrite lại
[3/7/2019, 7:47:30 PM] [manhdv]: ~vay neu xoa theo cach thong thuong, ma file do van tren dia cung, thi file do co duoc os tu dong don dep hay ko?~
~hay ta phai lam them buoc thu cong nua la xoa no han tren dia cung vay Q?~
[3/7/2019, 7:49:46 PM] [manhdv]: bảo sao mấy cái soft phục hồi disk nó khuyến cáo là sau khi lỡ delete file thì nên phục hồi ngay, ko nên write cái gì vào rồi mới phục hồi
[3/7/2019, 7:50:48 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: dạ, OS ko tự dọn nha anh, nhưng khi anh tạo ra các file mới, ghi dữ liệu vào đĩa cứng thì tới 1 lúc nào đó nó cũng trúng cái vùng đĩa mà chứa cái file anh đã xóa -&gt; nên sau 1 thời gian ghi dữ liệu thì file kia cũng đc coi là overwrite và ko có khả năng phục hồi rồi anh
[3/7/2019, 7:52:04 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: đúng rồi anh, sau khi xóa nhầm thì recover ngay thì khả năng recover đc sẽ cao, còn đã ghi thêm dữ liệu thì hên xui (trúng hoặc ko trúng vùng mà file đó đc chứa)
[3/7/2019, 7:53:29 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: xài máy cty, có các thông tin cá nhân thì khi nghỉ việc nên `wipe` :smile: đọc thêm về chương trình này ở đây <http://manpages.ubuntu.com/manpages/bionic/man1/wipe.1.html>
nhiều khi wipe mất cả ngày chạy ko xong vì nó lặp đi lặp lại nhiều lần, cái `rm -P` ở trên có 3 lần thôi :smile:
[3/7/2019, 7:53:47 PM] [manhdv]: vậy là khi xem properties của đĩa, thấy báo đã dùng xMB, có nghĩa là nó count dung lượng của những file đang có ref (được hiểu là ko bị xóa) nhỉ.
[3/7/2019, 7:55:53 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: dạ, em nghĩ xMB thể hiện những file đang có ref. Vùng đĩa mà chứa các file un-ref có thể tái sử dụng đc mà, nên có thể coi nó là free.
[3/7/2019, 7:58:40 PM] [manhdv]: #til
truoc gio cu nghi `rm -f` la ngon roi co :))))))))))))
[3/7/2019, 8:10:06 PM] []: cái nào cần secure hẳn overwrite, ghi nhiều hại ổ cứng lắm...
[3/7/2019, 8:12:12 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: ^ đúng luôn, nhưng khi trả máy cty … thì nó là máy cty, wipe tẹt cho chắc
[3/7/2019, 10:47:22 PM] [// english-ignore]: <https://twitter.com/JeffDean/status/1103908372191965185?s=19>
[3/8/2019, 12:24:57 AM] [noob]: thắc mắc tụi phục hồi nó làm sao nhỉ, kiểu như fat16 đi nó xóa fat/root table thì sao mà biết để tìm file
[3/8/2019, 1:04:34 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: ối, `mos` vô rồi, viết cái OS xong chỉ tui nha :okay:
[3/8/2019, 1:30:10 AM] [noob]: :omg:
[3/8/2019, 1:31:53 AM] [manhdv]: chắc nó lần theo từng block của đĩa, nếu block đó ko có ref đến mà vẫn có data thì nó tạo ra cái gì đó ref đến :thinkold:
[3/8/2019, 4:28:02 AM] [ko luong thien]: Where
[3/8/2019, 4:28:06 AM] [ko luong thien]: I dont sse
[3/8/2019, 4:28:07 AM] [ko luong thien]: Huhu
[3/8/2019, 4:28:17 AM] [ko luong thien]: How
[3/8/2019, 4:28:18 AM] [ko luong thien]: Huhu
[3/8/2019, 4:28:20 AM] [ko luong thien]: Which fo t
[3/8/2019, 4:28:38 AM] [ko luong thien]: No more lato ho
[3/8/2019, 4:53:52 AM] [Cậu Làm Vườn]: #todayIfound <https://github.com/kdeldycke/awesome-falsehood>
[3/8/2019, 4:55:28 AM] [noob]: lần thế nào, khi đã xóa root directory và fat, lúc phần còn lại chỉ là contiguous chunks of data
[3/8/2019, 8:19:49 AM] [huy]: Noto rồi
[3/8/2019, 4:55:50 PM] [Huy]: đúng là mấy hãng lớn làm việc
[3/8/2019, 4:56:01 PM] [Huy]: thay đổi nhiều thứ mà users như mình ko hiểu nổi
[3/8/2019, 5:00:05 PM] [Huy]: True
[3/8/2019, 5:01:01 PM] [Huy]: nhưng mà cũng chưa đủ bằng chứng lắm
[3/8/2019, 5:01:13 PM] [Huy]: như cái font cũng cũng invisible mà
[3/8/2019, 5:01:20 PM] [Huy]: to me lol
[3/8/2019, 5:02:46 PM] [huy]: về cái gì e, về vụ phải invisible hả
[3/8/2019, 5:02:48 PM] [Huy]: kiểu e nghĩ vụ thay đổi này liên quan tới vấn đề nó muốn mọi người để ý lại là có 1 cái sản phẩm như Slack tồn tại hơn
[3/8/2019, 5:02:52 PM] [huy]: vậy e muốn gì :))
[3/8/2019, 5:03:06 PM] [huy]: true
[3/8/2019, 5:03:21 PM] [Huy]: e đâu muốn gì đâu, ý là e ko hiểu sao nó đổi vì cái font cũ đối với e nó cũng tốt rồi
[3/8/2019, 5:03:27 PM] [huy]: những cái change vô thưởng vô phạt này thì đúng
[3/8/2019, 5:03:30 PM] [Huy]: còn tốt hơn sao e ko hiểu
[3/8/2019, 5:03:47 PM] [huy]: hoặc nó đang cố optimize cho cái gì đó
[3/8/2019, 5:04:08 PM] [Huy]: Slack nó tốt ở mức nhiều team ko cần trả tiền
[3/8/2019, 5:04:11 PM] [Huy]: vẫn xài được
[3/8/2019, 5:04:18 PM] [huy]: hoặc có khi nó test design
[3/8/2019, 5:04:19 PM] [Huy]: e nghĩ nó đang muốn kiếm cách làm tiền
[3/8/2019, 5:04:22 PM] [Huy]: nên branding xong bán
[3/8/2019, 5:04:32 PM] [huy]: bán à
[3/8/2019, 5:04:40 PM] [Huy]: đoán thôi
[3/8/2019, 5:04:54 PM] [huy]: bán cho microsoft để tích hợp thành skyfe
[3/8/2019, 5:05:07 PM] [Huy]: hehe maybe
[3/8/2019, 9:58:25 PM] []: gán mấy cái orphan blocks cho 1 cái inode trên đĩa mới được không nhỉ ?
[3/9/2019, 1:03:00 AM] [ko luong thien]: Noto so với Lato khác nhiều mà :v
[3/9/2019, 1:03:02 AM] [ko luong thien]: going global
[3/9/2019, 1:05:04 AM] [ko luong thien]: các đồng chí xài latin thật là :triumph:
[3/9/2019, 4:58:22 AM] [Huy]: uh, có thể vậy, a nhớ cái Lato trên Google bị lỗi tiếng Việt
[3/9/2019, 6:52:31 AM] [ko luong thien]: cái Lato trên Google là bản ngu học á
[3/9/2019, 6:52:38 AM] [ko luong thien]: nó là Lato v1
[3/9/2019, 6:52:51 AM] [ko luong thien]: chỉ có 2 weight + k có latin extended (e.g. Vietnamese)
[3/9/2019, 6:53:25 AM] [ko luong thien]: Slack trước đây nó dùng Lato v2, nhưng Lato v2 nó có license conflict với Google nên k có distribute lên google fonts được
[3/9/2019, 6:53:36 AM] [ko luong thien]: Lato v2 thì ngon, có latin extended và 8 weights
[3/9/2019, 6:53:51 AM] [ko luong thien]: nhưng kiểu gì cũng không nhiều bằng Noto hoặc Source
[3/9/2019, 6:53:59 AM] [ko luong thien]: fun fact: Noto CJK and Source Hans is the same
[3/11/2019, 4:41:40 PM] [huy]: #til Brave Browser has Tor integrated
[3/11/2019, 6:14:07 PM] [ko luong thien]: #til it's squircle, not just rounded rectangle
[3/11/2019, 6:14:53 PM] [ko luong thien]: <https://en.wikipedia.org/wiki/Squircle>
[3/11/2019, 6:15:19 PM] [ko luong thien]: học được sau 1 buổi sáng ngồi vẽ icon :arggg: <https://anduin.design/icon-product>
[3/11/2019, 9:28:02 PM] [// english-ignore]: :til:
[3/11/2019, 10:31:49 PM] [Cậu Làm Vườn]: #OutOfTheLoop Tại sao cái til lại ra cái icon đó
[3/11/2019, 10:44:13 PM] [// english-ignore]: Summon @snacky
[3/11/2019, 11:08:28 PM] [ko luong thien]: Biết được mỗi cái đầu tiên là "now"
[3/12/2019, 12:51:13 AM] [huy]: tiếng mẹ đẻ mà mấy cha
[3/12/2019, 9:39:56 AM] [minh.nguyen]: #til RubyVietnam slack được thành lập vào ngày 11/12/2015. Đến nay đã được 3 năm 3 tháng và 1 ngày :think:.
[3/12/2019, 10:03:14 AM] [huy]: thật không? a nhớ lâu hơn mà ta, biết tới slack này từ trước tháng 8/2015 lận
[3/12/2019, 10:14:37 AM] [minh.nguyen]: slack được tạo vào ngày đó. Còn trước đó là gitter hay gì đó
[3/12/2019, 10:16:38 AM] [huy]: à nhớ rồi
[3/12/2019, 9:38:29 PM] [meowwwwwwwwwwwwwwww]: #til
`tsconfig.json`:
```
..."paths": {
"@app/*": ["*"]
}
```
And
```
import {...} from "@app/models/...";
```
[3/13/2019, 10:44:07 PM] [// english-ignore]: #til <#C4EKCK0TF|gaming> không phải chỉ để bàn về game
[3/13/2019, 10:44:42 PM] [Cậu Làm Vườn]: ^ :ie:
[3/13/2019, 10:45:11 PM] [Cậu Làm Vườn]: toy cũng đã từng ngây thơ nghĩ vậy
[3/13/2019, 10:46:00 PM] [Cậu Làm Vườn]: was expecting dota and stuffs
[3/13/2019, 10:46:20 PM] [Cậu Làm Vườn]: but all I see is chicks :baby_chick:
[3/13/2019, 10:46:29 PM] [Cậu Làm Vườn]: and :peach:
[3/13/2019, 10:55:01 PM] [// english-ignore]: and :cherries:
[3/13/2019, 11:11:34 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: về g* mà
[3/13/2019, 11:18:43 PM] [// english-ignore]: :yaomin:
[3/14/2019, 12:07:13 AM] [dan]: and :cucumber:
[3/14/2019, 12:53:59 AM] [tucao]: and :crossed_swords:
[3/14/2019, 1:17:14 AM] [// english-ignore]: Your name triggered me :nosebleed:
[3/14/2019, 1:22:47 AM] [tucao]: :neutral_face:
[3/15/2019, 2:04:09 AM] [// english-ignore]: #til blocking commands in Redis <https://redis.io/topics/modules-blocking-ops>
[3/15/2019, 2:06:10 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: shame pr <https://xluffy.github.io/post/sidekiq-how-to-reliability> :vayvay: có nhắc tới 1 khúc ở cuối cuối
[3/15/2019, 2:11:29 AM] [// english-ignore]: :bow:
[3/15/2019, 3:04:24 AM] [hieu.huynh]: :raised_hands:
[3/16/2019, 1:15:55 AM] [Cậu Làm Vườn]: #til this is a jumbotron
[3/16/2019, 1:15:56 AM] [Cậu Làm Vườn]: <https://nhl.bamcontent.com/images/photos/284853890/640x360/cut.jpeg>
[3/16/2019, 1:17:52 AM] [Cậu Làm Vườn]: def: a very large video display screen of a type used in venues such as sports stadiums.
[3/16/2019, 3:59:50 AM] [typescriptpher]: #til <https://google.github.io/kunit-docs/third_party/kernel/docs/index.html> KUnit - Unit Testing for the Linux Kernel
[3/16/2019, 4:05:46 AM] [ko luong thien]: #til `display: inline-block` should be wrote as `display: inline block` and how `display` actually work
[3/16/2019, 4:06:14 AM] [ko luong thien]: The key here is that `display` is usually used with a single value (e.g. `display: block`), but it is actually designed (or at least updated) to expect 2 values:
```
display: &lt;outside-value&gt; &lt;inside-value&gt;
```
[3/16/2019, 4:26:26 AM] [Cậu Làm Vườn]: My god, I just realize what that mean :scream_cat:
[3/16/2019, 4:26:32 AM] [Cậu Làm Vườn]: My life is a lie
[3/16/2019, 4:28:12 AM] [ko luong thien]: Yes I told @nhducit the same =)) my life was a lie
[3/16/2019, 4:32:44 AM] [Cậu Làm Vườn]: Now I can finally remember the exact behavior without looking up every now and then :scream:
[3/16/2019, 4:33:25 AM] [Cậu Làm Vườn]: Why is this not common knowledge :why:
[3/16/2019, 4:34:31 AM] [Cậu Làm Vườn]: Or is it common knowledge and we're just :ie: :okay:
[3/16/2019, 4:52:21 AM] [huynh.cam]: Cho bần tăng xin 500 đ link dc ko?
[3/16/2019, 4:52:51 AM] [ko luong thien]: link: @nhducit
[3/16/2019, 4:52:54 AM] [ko luong thien]: joke: <https://developer.mozilla.org/en-US/docs/Web/CSS/display>
[3/16/2019, 4:53:47 AM] [ko luong thien]: ^ @harrisnguyen the fact that it is extensively described at the default entry of MDN determines that we are just :ie:
[3/16/2019, 8:24:03 AM] [// english-ignore]: Hoặc không bao giờ đọc docs những cái mình nghĩ đã biết
[3/16/2019, 8:24:12 AM] [// english-ignore]: &lt;- same
[3/16/2019, 8:24:36 AM] [ko luong thien]: @kcj.pop.com_rbvn agree :disappointed: nên có thói quen đọc lại..
[3/16/2019, 8:24:44 AM] [ko luong thien]: it's not a book
[3/16/2019, 8:35:57 AM] [huy]: #til Paul Graham từng startup trong 3 năm (1995-1998) với cty tên là Viaweb, sau đc Yahoo mua lại giá 49 triệu đô. Vì tiền nhiều quá nên anh ấy cả đời đã ko cần làm việc nữa. Và cũng mất luôn motivation để tiếp tục startup. :thinkcry:
[3/16/2019, 8:58:01 AM] [typescriptpher]: Ảnh ko làm startup nữa nhưng dạy người khác cách làm startup (mặc dù ảnh rùa) :roflrofl:
[3/16/2019, 9:20:49 AM] [huy]: Đúng rùa luô
[3/17/2019, 5:25:08 AM] [imah]: ước gì 1 lần được rùa như anh ấy :turtle:
[3/17/2019, 1:26:20 PM] [ko luong thien]: #til "detail" vs "details" <https://english.stackexchange.com/questions/123672/detail-or-details-read-on-for-more-detail-details>
[3/17/2019, 9:14:08 PM] [huy]: #til Learned how to read binary clock :omg:
[3/17/2019, 9:14:23 PM] [huy]: (not today, 2 days ago)
[3/17/2019, 9:49:02 PM] [huy]: #til Vào những năm 1960s, người VN dùng máy đánh chữ với một cái layout gọi là AĐERTY
<https://upload.wikimedia.org/wikipedia/commons/0/0c/Typewriter-aderty-vn.jpg>
[3/17/2019, 10:04:16 PM] [anh bán chuối]: nhưng ko thể phủ nhận ảnh pick founders ngon :v pick dc nhiều unicorn
[3/18/2019, 3:29:56 PM] [ko luong thien]: good til
[3/18/2019, 8:33:06 PM] [dat]: trước còn vẽ được mấy cái như `(x^2 + y^2 - 1)^3 - x^2 y^3 = 0`, mà giờ bỏ rồi thì phải :-?
[3/18/2019, 10:12:57 PM] [unrealhoang]: vẽ trái tim đi @taurandat
[3/19/2019, 4:06:57 AM] [John]: bỏ equal đi là vẻ được :slightly_smiling_face:
[3/19/2019, 4:08:21 AM] [John]: #til git awards <http://git-awards.com/>
[3/19/2019, 4:08:52 AM] [anh bán chuối]: nice
[3/19/2019, 4:16:17 AM] [dat]: <https://www.wolframalpha.com/share/clip?f=d41d8cd98f00b204e9800998ecf8427eh320ogc1k&amp;mail=1>
[3/19/2019, 4:16:28 AM] [dat]: that ra cai em muon giong the nay :))
[3/19/2019, 4:20:15 AM] [dat]: 2^ #til exp(-((x-4)^2+(y-4)^2)^2/1000) + exp(-((x+4)^2+(y+4)^2)^2/1000)
[3/19/2019, 4:31:16 AM] [anh bán chuối]: haha :+1::skin-tone-6:
[3/19/2019, 7:53:12 AM] [dat]: #til bạn có thể đo nhịp tim bằng cách quan sát da (được rọi đèn) :o
[3/19/2019, 8:01:26 AM] [dat]: <http://news.mit.edu/2013/seeing-the-human-pulse-0620>
[3/19/2019, 8:01:35 AM] [dat]: :ie:
[3/19/2019, 8:02:56 AM] [sai]: #til postgresql pg_trgm
<https://www.postgresql.org/docs/current/pgtrgm.html>
[3/19/2019, 10:02:58 AM] [huy]: #til Clean your macbook's screen :fast-omg:
[3/19/2019, 10:22:33 AM] [typescriptpher]: #til Khi mà bạn phải patch đến linux kernel, là bạn làm gì đó supa sai roài...
[3/20/2019, 7:09:57 AM] [ledongthuc]: #til Hedge là một kỹ thuật trong giao dịch tài chính mà mà người ta đặt lệnh mua và bán cùng 1 thời điểm. Sau đó dựa vào chiều hướng của thị trường mà đóng 1 lệnh đang lỗ và giữ lệnh lời để kì vọng. Ideally.
Kỹ thuật này chỉ lời khi kì vọng lời &gt; lệnh lỗ bị đóng + chi phí giao dịch của 2 lệnh.
Câu hỏi đặt ra là tại sao phải đặt 2 lệnh để phí tiền giao dịch, trong khi ta có thể đợi xu hướng rồi đặt lệnh.
=&gt; Đó là tuỳ vào chiến thuật, vì đợi khi ta phát hiện thấy xu hướng giá tăng/giảm thì xu hướng chuẩn bị đổi chiều rồi :slightly_smiling_face: Nó sẽ quay lại bài toán là nên đặt lệnh theo xu hướng hay ngược xu hướng.
Vậy khi nào dùng kỹ thuật Hedge này, em ko biết =)) chưa thử chưa dám nói chắc. Nhưng chắc là sẽ trong những trường hợp mình muốn mua bảo hiểm cho quyết định của mình. Do mình chỉ đóng lệnh lỗ khi thấy trend thị trường rõ ràng nên khả năng backup cao hơn, nhưng đồng nghĩa là mình sẽ lời ít hơn.
Hedge này ko nên xài lúc nào. Do kì vọng của lệnh lời phải &gt; hơn lệnh lỗ + chi phí, nên thị trừng phải có trend đủ lớn, nếu thị trường giá cứ lình bình thì đi ăn :shit: lúc đó giam lệnh đau tim hoặc close 2 lệnh chịu lỗ phí giao dịch luôn.
Và cũng như bất cứ cái gì, rủi ro là khi vừa đóng lệnh lỗ, mình phát hiện lệnh lời của mình ko đúng và thị trường chạy ngược trend dự đoán của mình =&gt; lỗ 2 lệnh + 2 phí giao dịch
[3/20/2019, 7:23:24 AM] [ledongthuc]: à còn 1 cái risk nữa là đánh lệnh lớn quá thì chưa kịp làm gì, cháy mất cái tài khoản =)))))))))))))
[3/20/2019, 7:31:30 AM] [// english-ignore]: Hôm nào làm khoá giao dịch tài chính 101 lào
[3/20/2019, 7:31:33 AM] [// english-ignore]: :vayvay:
[3/20/2019, 7:33:02 AM] [ledongthuc]: :pac: em đâu biết gì đâu, chỉ bậy mắc công chơi thua xong chặt đầu em nữa
[3/20/2019, 7:35:14 AM] [unrealhoang]: Hedge đơn giản là lower position, lower risk thôi :D
[3/20/2019, 7:36:56 AM] [unrealhoang]: Mua bảo hiểm cũng là hedge đấy
[3/20/2019, 10:48:55 AM] [vthang]: Cũng hên xui ạ. Gặp 1 con thình lình đi ngang thì cũng hết hồn
[3/21/2019, 1:31:35 AM] []: welcome a Thuc
[3/21/2019, 1:31:45 AM] []: đến với thế giới sml
[3/21/2019, 4:25:21 AM] [King Tran]: #til brainfuck language <https://vi.wikipedia.org/wiki/Brainfuck>
[3/21/2019, 4:52:52 AM] [noob]: #funfact nhưng nó là một trong những ngôn ngữ làm tiêu bản để viết compiler
[3/23/2019, 12:38:22 AM] [typescriptpher]: Like the names: more future, future, more modern : )))
[3/23/2019, 1:18:08 AM] [minh.nguyen]: em đang chờ ruby bản mới nó bump version lên cái nữa xem sau MoreFuture sẽ là gì :omg: FarFarFuture chăng :omg:
[3/23/2019, 1:30:07 AM] [typescriptpher]: Cái vụ bump version thì anh thấy bá nhất vẫn là Kernel 5.0 :roflrofl:
[3/23/2019, 1:32:58 AM] [minh.nguyen]: vụ đó sao anh? :smile:
[3/23/2019, 3:11:22 AM] [typescriptpher]: ah, kernel là 4.20, lão Linus nói là tao hết ngón tay, ngón chân để đếm rồi, nên bump lên 5.0 = )))
[3/23/2019, 3:12:01 AM] [typescriptpher]: "I’d like to point out (yet again) that we don’t do feature-based releases, and that “5.0” doesn’t mean anything more than that the 4.x numbers started getting big enough that I ran out of fingers and toes.
LINUS TORVALDS"
[3/23/2019, 3:44:29 AM] [minh.nguyen]: :roflrofl:
[3/23/2019, 3:52:50 AM] [typescriptpher]: my idol :roflrofl:
[3/23/2019, 4:13:43 AM] [typescriptpher]: #til C++ concepts <https://en.wikipedia.org/wiki/Concepts_(C%2B%2B)>
[3/23/2019, 4:13:51 AM] [typescriptpher]: <http://www.stroustrup.com/good_concepts.pdf>
[3/23/2019, 4:13:56 AM] [typescriptpher]: <https://github.com/CppCon/CppCon2018/blob/master/Keynotes/concepts_the_future_of_generic_programming/concepts_the_future_of_generic_programming__bjarne_stroustrup__cppcon_2018.pdf>
[3/23/2019, 4:14:01 AM] [typescriptpher]: <https://www.youtube.com/watch?v=HddFGPTAmtU>
[3/23/2019, 4:16:26 AM] []: #til from someone on reddit nếu bạn dùng giấy thử nước hoa để làm kẹp sách thì mỗi cuốn sẽ có mùi thơm vcl và mỗi lần bạn ngửi lại mùi này thì sẽ được gợi nhớ về sách. :thinkold:
[3/23/2019, 4:17:44 AM] []: Ps: ra mall lượm free họ phát đầy :fast-omg:
[3/23/2019, 4:30:11 AM] [ledongthuc]: :think: nếu dùng để kẹp nách từng người thì sao nhỉ. 1 cách để gợi nhớ về những người mình quen
[3/23/2019, 4:32:43 AM] []: @ledongthuc mùi mà nhớ về ex thì chỉ muốn quên mà lại không quên nổi :think: tra tấn
[3/23/2019, 4:34:12 AM] [ledongthuc]: :think:
[3/23/2019, 5:38:12 AM] [ko luong thien]: Finger-based versioning
[3/23/2019, 5:38:28 AM] [ko luong thien]: Trên wiki hay arch wiki có 1 cáo article vụ này =))
[3/23/2019, 6:02:10 AM] [unrealhoang]: Concept như trait thôi nhỉ
[3/23/2019, 7:00:25 AM] [typescriptpher]: `trait` ở Rust thì function có implement `trait` dc ko
[3/23/2019, 7:00:41 AM] [typescriptpher]: ở go thì function có thể satisfy 1 cái `interface`
[3/23/2019, 7:01:00 AM] [typescriptpher]: (nhưng nó là implicit, ko phải explicit declare)
[3/23/2019, 7:02:01 AM] [unrealhoang]: Function của rust cũng là 1 cái implementation của trait
[3/23/2019, 7:02:36 AM] [unrealhoang]: `fn(A) -&gt; B`
[3/23/2019, 7:08:51 AM] [typescriptpher]: `concepts` trong C++ mạnh lắm, nó định nghĩa 1 mớ constraints trên type, kiểu 1 bản ngon hơn của `template`
```
template &lt;class T&gt;
concept bool EqualityComparable() {
return requires(T a, T b) {
{a == b} -&gt; Boolean; // Boolean is the concept defining a type usable in boolean context
{a != b} -&gt; Boolean;
};
}
```
[3/23/2019, 7:09:15 AM] [unrealhoang]: Uhm
[3/23/2019, 7:09:31 AM] [unrealhoang]: Static typing của template nhỉ
[3/23/2019, 7:09:44 AM] [unrealhoang]: Thay vì duck typing như hiện tại
[3/23/2019, 7:11:06 AM] [typescriptpher]: C++ template ko phải duck typing nhé
[3/23/2019, 7:43:40 AM] [unrealhoang]: @eyeball teach me, master
[3/23/2019, 7:54:41 AM] [unrealhoang]: Mùi nách ex
[3/23/2019, 7:54:46 AM] [unrealhoang]: :oh:
[3/23/2019, 7:58:50 AM] [typescriptpher]: duck type thực ra ko có định nghĩa một cách formal
[3/23/2019, 7:59:22 AM] [typescriptpher]: nhưng mà duck type sẽ thường được hiểu được check ở runtime, ví dụ một object/class A có đủ set các methods/properties ko
[3/23/2019, 8:01:43 AM] [typescriptpher]: template trong C++ thì được check ở compile time, mà compiler C++ nó dùng template để tạo một cái specialization của template đó khi được dùng, ví dụ em define 1 cái template `ICompatible&lt;T&gt;`, khi đó mỗi lần gọi `ICompatible&lt;Int&gt;`, `ICompatible&lt;string&gt;` nó lại sinh code cho từng kiểu riêng, cái này gọi là specialization
[3/23/2019, 8:02:41 AM] [unrealhoang]: À không cái đó em biết
[3/23/2019, 8:02:43 AM] [typescriptpher]: <http://www.jakubkonka.com/2017/09/02/type-traits-cpp.html> - có bài này khá hay phân biệt `concepts` với `templates`
[3/23/2019, 8:03:05 AM] [unrealhoang]: Ý duck typing là lúc compile generated template
[3/23/2019, 8:03:28 AM] [unrealhoang]: Compile lúc đó nếu gọi function type đó không có
[3/23/2019, 8:03:34 AM] [unrealhoang]: Thì nó hú lỗi
[3/23/2019, 8:04:06 AM] [typescriptpher]: ko, thằng C++ nó ko khôn dc thế đâu : ))
[3/23/2019, 8:04:20 AM] [typescriptpher]: nó coi `template` đúng là... template, nó cứ sinh code ra thôi
[3/23/2019, 8:05:22 AM] [unrealhoang]: Uh thì bước generate template không có compile
[3/23/2019, 8:06:24 AM] [unrealhoang]: *không có check
[3/23/2019, 8:07:36 AM] [unrealhoang]: Nhưng bước compile thì lỗi vì type không có hàm
[3/23/2019, 8:09:06 AM] [typescriptpher]: uh, cái đoạn copy code ra thì.. easy, khó là, nên nhớ `C++` nó có inheritance nhé, chọn cái "specialization" nào là cả vấn đề : ))
[3/23/2019, 8:09:27 AM] [typescriptpher]: vì C++ nó cho phép override nhé
[3/23/2019, 8:11:04 AM] [typescriptpher]: ví dụ:
```
template&lt;class T&gt; // (1)
void f(T)
template&lt;class T&gt; // (2)
void f(T*) // overload (1)
template&lt;&gt; // (3)
void f&lt;&gt;(int*)
int *p;
f(p)
```
[3/23/2019, 8:11:42 AM] [typescriptpher]: hỏi trong ví dụ a) ở trên nó call hàm (1), (2), hay (3)?
[3/23/2019, 8:12:06 AM] [typescriptpher]: giờ đổi chỗ lại xíu
[3/23/2019, 8:12:36 AM] [typescriptpher]: ```
// example (b)
template&lt;class T&gt; // (1)
void f(T)
template&lt;&gt; // (3)
void f&lt;&gt;(int*)
template&lt;class T&gt; // (2)
void f(T*) // overload (1)
int *p;
f(p)
```
[3/23/2019, 8:13:07 AM] [typescriptpher]: trong ví dụ b) này thì sao?
[3/23/2019, 8:19:41 AM] [unrealhoang]: Overload kinh quá
[3/23/2019, 8:20:20 AM] [unrealhoang]: Thôi để mấy bữa em học c++ đã
[3/23/2019, 8:20:31 AM] [unrealhoang]: Team cũng đang bắt học rồi
[3/23/2019, 8:20:37 AM] [unrealhoang]: :crying:
[3/23/2019, 8:24:32 AM] [unrealhoang]: <https://zygoloid.github.io/cppcontest2018.html>
[3/23/2019, 9:16:22 AM] []: @unrealhoang khẩu vị anh mặn thật :wth:
[3/23/2019, 10:20:31 AM] [// english-ignore]: Mà cái đó chỉ là giấy
[3/23/2019, 10:20:47 AM] [// english-ignore]: À ý là ra xịt tè le rồi đem về à
[3/24/2019, 1:55:13 AM] [unrealhoang]: :oh:
[3/24/2019, 1:59:09 AM] [Cậu Làm Vườn]: Giấy thử ấy, ra nó thấm sẵn rồi phát miễn phí. Collect về thôi. Nhưng mà đa số hơi nhỏ, không vừa làm bookmark.
Tự lấy nước hoa của mình xịt vô bookmark có vẻ êm hơn.
[3/24/2019, 2:07:01 AM] [// english-ignore]: Vậy à, thường anh thấy mình tự xịt rồi thử chứ nó thấm sẵn thì mùi nó bay hết rồi :-?
[3/24/2019, 6:39:43 AM] []: sao cac editor ko clone cai nay :haha:
[3/24/2019, 7:39:29 PM] [話せる森林]: #til một trang khá hay ho cho anh em nào làm việc ở Nhật. `<http://business-textbooks.com|business-textbooks.com>`. Trang này có khá nhiều kiến thức thường thức về công việc tại Nhật cũng như quan trọng nhất là giải nghĩ rất nhiều từ sử dụng trong công việc bằng hình ảnh và ví dụ dễ hiểu.
&gt; <https://business-textbooks.com/over-under-difference/#toc-5>
&gt; <https://business-textbooks.com/dimension-difference/>
[3/25/2019, 11:34:04 AM] [typescriptpher]: #til Chord, CAN, Tepastry, Pastry
[3/25/2019, 11:28:06 PM] []: #til sheets.new, docs.new, slides.new =&gt; Creating new Google Docs file
[3/26/2019, 3:32:00 AM] [trung]: #til Đổi tên biến có xuất hiện trong tất cả files trong projecte bằng :vim:
1. Cài đặt plugin `ctrlSf` tại `<https://github.com/dyng/ctrlsf.vim>`
2. Config (/vim/settings/ctrlsf.vim)
```
function! GetVisual()
let reg_save = getreg('"')
let regtype_save = getregtype('"')
let cb_save = &amp;clipboard
set clipboard&amp;
normal! ""gvy
let selection = getreg('"')
call setreg('"', reg_save, regtype_save)
let &amp;clipboard = cb_save
return selection
endfunction
let g:ctrlsf_auto_focus = {
\ 'at': 'done',
\ }
vnoremap ,sf :&lt;C-U&gt;execute "CtrlSF " . GetVisual()&lt;CR&gt;:%s/&lt;c-r&gt;=GetVisual()&lt;cr&gt;/new_pattern/g
```
3. Note
- Cẩn thận với đoạn text muốn replace.
- `valid` sẻ match vs `invalid`
[3/26/2019, 4:37:39 AM] [Cậu Làm Vườn]: #til Js tips: `for(;;)` can be used similarly to `while(true) { }`
[3/26/2019, 4:39:22 AM] [// english-ignore]: :oh: ai lại chọn `for(;;)`
[3/26/2019, 4:39:54 AM] [Cậu Làm Vườn]: Emphasize `can be`. Does not mean you should :vayvay:
[3/26/2019, 4:41:06 AM] [// english-ignore]: every loop statement can be replaced by `for`
[3/26/2019, 4:41:13 AM] [// english-ignore]: that's the rule of this universe
[3/26/2019, 5:17:10 AM] [noob]: phải là ngược lại mới đúng, tất cả loop được dịch ra while, chính là goto :vayvay:
[3/26/2019, 6:06:02 AM] [tay vịn của anh bán chuối - cty A tìm FE]: Api Response của Facebook với google thường có mấy cái này nè
[3/26/2019, 6:19:25 AM] [unrealhoang]: @kcj.pop.com_rbvn để tiết kiệm kí tự nhé
[3/26/2019, 6:20:38 AM] [// english-ignore]: ._.
[3/26/2019, 4:24:52 PM] [huy]: #til Có 3 mô hình để định giá cho dịch vụ mà bạn sẽ build, và nên suy nghĩ chuyện định giá ngay từ ngày đầu
<https://bookmark.jft.rocks/#How%20to%20price%20your%20side-project%20-%20Tigran%20Hakobyan%27s%20personal%20blog>
[3/27/2019, 11:19:33 AM] [// english-ignore]: #til <https://en.wikipedia.org/wiki/Herbivore_men>
[3/27/2019, 11:55:17 PM] [Cậu Làm Vườn]: tiếng Diệc Lam người ta gọi đó là lãnh cảm :vayvay:
[3/27/2019, 11:56:55 PM] [dan]: Asexual :thinking_face:
[3/28/2019, 4:08:57 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: #til <https://stackoverflow.com/questions/2946051/changing-case-in-vim> :oh:
[3/28/2019, 11:26:27 PM] []: #til
<https://2.pik.vn/2019e2c1c298-040d-4ad8-92c1-0abeb42a1d07.png>
[3/28/2019, 11:26:43 PM] []: `<https://www.urbandictionary.com/define.php?term=Brexiting>`
[3/29/2019, 11:35:55 PM] []: #til <https://en.wikipedia.org/wiki/Cryptographic_nonce>
[3/30/2019, 4:41:36 AM] []: <https://youtu.be/T58lGKREubo> resonance :o
[3/31/2019, 4:23:45 AM] [Cậu Làm Vườn]: #til `&lt;base&gt;` html tag
[4/1/2019, 12:21:21 AM] [ledongthuc]: #til phòng bự + không có đồ đạc = call echo kinh dị :cry:
[4/1/2019, 12:25:23 AM] [// english-ignore]: gián tiếp khoe nhà bự
[4/1/2019, 12:30:06 AM] [ledongthuc]: :thinkcry: nhà bự nhưng không phải nhà mình
[4/1/2019, 9:11:02 AM] [話せる森林]: Đến phòng bự lại không phải của mình :33:
[4/2/2019, 2:51:44 AM] []: #til one-way bearing
<https://www.youtube.com/watch?v=QjR7dimpSJA>
[4/2/2019, 2:59:13 AM] [ledongthuc]: rất nể mấy người thiết kế mấy cái cơ khí này mà dạng chi tiết nhỏ
[4/2/2019, 2:59:30 AM] [ledongthuc]: :adore: hay thật
[4/2/2019, 3:22:42 AM] []: @ledongthuc <https://www.youtube.com/watch?v=97t7Xj_iBv0> :stuck_out_tongue:
[4/2/2019, 5:35:57 AM] [John]: theo mình biết thì bên nhật có trend này &amp; nhà mình cũng zậy :smile:
[4/2/2019, 10:59:45 PM] [trexnix]: #til Learn Flexbox CSS by playing this game <http://flexboxfroggy.com|flexboxfroggy.com>
[4/3/2019, 7:24:07 PM] [ko luong thien]: #til <https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Fonts/Variable_Fonts_Guide>
[4/3/2019, 10:07:02 PM] [tay vịn của anh bán chuối - cty A tìm FE]: dài thế. tldr đi cưng
[4/4/2019, 3:26:08 AM] [// english-ignore]: <https://twitter.com/Mandy_Kerr/status/1113704711507419137?s=19> chắc cũng liên quan
[4/4/2019, 3:30:46 AM] [ko luong thien]: Bundle 1 family font vào 1 file font
[4/4/2019, 5:05:15 PM] [huy]: #til Microinteractions <https://www.ebayinc.com/stories/blogs/tech/how-ebay-uses-microinteractions-to-delight-customers-in-china/>
[4/4/2019, 11:08:55 PM] []: #til <https://codeberg.org>
[4/4/2019, 11:14:06 PM] [ko luong thien]: &gt; with the objective to give the Open-Source code that is running our world a safe and friendly home, and to ensure that free code remains free and secure forever.
I think I have read several organizations with the same objective..
[4/4/2019, 11:29:23 PM] []: Actually I was looking for this
<https://github.com/Freeyourgadget/Gadgetbridge>
[4/4/2019, 11:29:48 PM] []: And the link in F-Droid lead to codeberg link
<https://codeberg.org/Freeyourgadget/Gadgetbridge>
[4/4/2019, 11:32:30 PM] [ko luong thien]: :+1:
[4/4/2019, 11:43:44 PM] [huy]: trông như một bản clone github, cái này là gì vậy
[4/6/2019, 7:57:54 AM] []: #til “alpha” wolf is a myth :think:
[4/6/2019, 8:23:26 PM] [typescriptpher]: #til JerryScript <https://github.com/pando-project/jerryscript>, where is TomScript?
[4/7/2019, 2:54:08 AM] [ko luong thien]: #til <https://en.wikipedia.org/wiki/Utilitarianism>
[4/7/2019, 2:59:57 AM] [// english-ignore]: #yil <https://en.wikipedia.org/wiki/Ophiocordyceps_sinensis> đông trùng hạ thảo
[4/7/2019, 7:18:55 AM] [// english-ignore]: <https://vi.wikipedia.org/wiki/Cordyceps>
[4/7/2019, 8:58:27 AM] []: #til jeremy bentham is the founder of utilitarianism
[4/9/2019, 7:41:59 AM] [noob]: #til quang minh chính đại vs quang minh lỗi lạc :exploding_head:
[4/9/2019, 7:48:02 AM] [ko luong thien]: need more info
[4/9/2019, 8:52:48 AM] [// english-ignore]: ^ same
[4/9/2019, 9:06:27 AM] [__.__Sectumsempra__.__]: :til-en: <https://github.com/drathier/stack-overflow-import>
[4/10/2019, 9:49:56 AM] []: #til alt-right :think: <https://en.wikipedia.org/wiki/Alt-right>
America is full of political jargons that scarcely exist anywhere else :think:
[4/10/2019, 9:51:22 AM] [ko luong thien]: I live in a ~paradise~ world that "alt-right" is the key next to right ctrl
[4/10/2019, 9:53:49 AM] []: :think:
[4/10/2019, 9:59:00 AM] []: honestly ive never seen any "alt-rightists" outside of america
[4/10/2019, 11:14:24 PM] [dat]: alt-right is still "left", with respect to right control though
[4/12/2019, 4:17:47 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til Lobotomized Owls
[4/12/2019, 4:20:17 AM] [// english-ignore]: <https://css-tricks.com/lobotomized-owls/> là cái này à :-?
[4/12/2019, 4:20:50 AM] [tay vịn của anh bán chuối - cty A tìm FE]: Uhm
[4/12/2019, 4:21:05 AM] [tay vịn của anh bán chuối - cty A tìm FE]: * + *
[4/12/2019, 4:22:51 AM] [// english-ignore]: nó để làm gì rứa?
[4/12/2019, 4:23:47 AM] [ko luong thien]: I dont understand why people need to have spacing outside of their public component
[4/12/2019, 4:24:12 AM] [ko luong thien]: Spacing should only be defined by the consumers.. at the end place, where the component is actually used
[4/12/2019, 4:24:26 AM] [ko luong thien]: A spacing should never be a part of a component
[4/12/2019, 4:24:45 AM] [ko luong thien]: It's a responsibility of the consumers
[4/12/2019, 4:28:10 AM] [// english-ignore]: Có những cái liên quan dễ sợ, hôm qua vừa đọc xong <https://styled-system.com/guides/spacing>
[4/13/2019, 1:07:52 AM] [tay vịn của anh bán chuối - cty A tìm FE]: đồng ý với Thiện vụ spacing, thấy flutter handle vụ spacing này ngon
[4/14/2019, 2:57:48 AM] [typescriptpher]: #til <https://en.wikipedia.org/wiki/Las_Vegas_algorithm>
[4/14/2019, 7:54:14 AM] [// english-ignore]: #til <http://calver.org/>
[4/14/2019, 10:24:54 PM] [manhdv]: # (Why/How/What) on Earth (question)?
[4/15/2019, 1:35:48 AM] [John]: Ngay cả với google cũng có những ngôi mộ như thế này.
- <https://killedbygoogle.com>
[4/15/2019, 1:41:01 AM] [ko luong thien]: đúng ra thì vì là Google nên mới có thể có mộ thế này
[4/15/2019, 1:41:10 AM] [ko luong thien]: những cty khác fail thì chết cả cty :disappointed:
[4/15/2019, 1:41:32 AM] [ko luong thien]: cho nên có 1 cái thỉnh thoảng cũng phải thừa nhận là những giant như này cũng giúp đẩy công nghệ đi tới
[4/15/2019, 1:41:36 AM] [ko luong thien]: họ có thể chết nhiều hơn mình
[4/15/2019, 1:41:47 AM] [ko luong thien]: startup khó mà chết nhiều, nhưng chết thì mới học được nhiều
[4/15/2019, 1:44:45 AM] [John]: oh, trong này chắc cũng có nhiều cái được tách ra &amp; join vô các project khác chứ ko phải "khai tử" hoàn toàn như list trên.
[4/15/2019, 1:55:00 AM] [ko luong thien]: :+1: Inbox and Gmail for example
[4/15/2019, 1:55:18 AM] [unrealhoang]: list kill by M$ chắc là nhiều
[4/15/2019, 1:55:22 AM] [unrealhoang]: RIP Skype
[4/15/2019, 1:55:34 AM] [ko luong thien]: nếu bạn hứng thú với bài này thì có 1 cái article rất hay, nó bàn về việc rewrite product. Nhiều cái rewrite turn out là kill product cũ cho sự phát triển của product mới
[4/15/2019, 1:55:36 AM] [ko luong thien]: để search thử
[4/15/2019, 1:55:50 AM] [ko luong thien]: Skype còn sống mà :arggg: chỉ mất hồn thôi :okay:
[4/15/2019, 1:56:13 AM] [John]: &amp; bug nhiều thoy
[4/15/2019, 1:56:24 AM] []: Skype is not for business, it's for t33nag3r
[4/15/2019, 1:56:36 AM] [unrealhoang]: ngày xưa độc tôn ở mảng VoIP
[4/15/2019, 1:56:46 AM] [unrealhoang]: vậy mà về tay M$
[4/15/2019, 1:56:50 AM] [unrealhoang]: :sosad:
[4/15/2019, 1:56:53 AM] [unrealhoang]: RIP
[4/15/2019, 3:43:28 AM] [ko luong thien]: #til working with keyCode and Char is more complicated than I thought :okay: <https://stackoverflow.com/questions/1772179/get-character-value-from-keycode-in-javascript-then-trim>
[4/15/2019, 3:45:38 AM] [// english-ignore]: <https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key> nhớ chuẩn giờ là `e.key`
[4/15/2019, 3:46:52 AM] [ko luong thien]: Yub `key` is good, nhưng type của nó là `String` nên hơi khó phân biệt
[4/15/2019, 3:47:11 AM] [ko luong thien]: ví dụ `Enter` và `a` là valid value, nhưng `ab` technically là valid value, nhưng thực tế thì không
[4/15/2019, 3:47:36 AM] [// english-ignore]: keyCode là number nên dễ hơn à :thinkhard:
[4/15/2019, 3:48:14 AM] [ko luong thien]: yub, 1 number chỉ có thể map về 1 key
[4/15/2019, 3:48:25 AM] [ko luong thien]: còn 1 cái string có thể map về 1 key hoặc k có key nào
[4/15/2019, 3:48:45 AM] [ko luong thien]: có cái nào để convert qua lại giữa key và keyCode k nhỉ
[4/15/2019, 3:49:22 AM] [// english-ignore]: k hiểu lắm, sao lại có `ab`ở đây
[4/15/2019, 3:49:30 AM] [ko luong thien]: typing story :okay:
[4/15/2019, 3:49:42 AM] [ko luong thien]: chuyện dài dòng lắm, để publish rồi em đưa ví dụ cho
[4/15/2019, 3:49:45 AM] [// english-ignore]: <https://www.npmjs.com/package/keycode>
[4/15/2019, 3:49:57 AM] [// english-ignore]: there must be a npm package for that
[4/15/2019, 3:53:44 AM] [ko luong thien]: yub
[4/16/2019, 12:18:14 AM] [unrealhoang]: #til <https://blog.anoff.io/2018-07-31-diagrams-with-plantuml/>
[4/16/2019, 12:38:09 AM] []: plantuml muôn năm
[4/16/2019, 7:29:26 PM] []: mermaid có vẻ đẹp hơn plantuml
[4/16/2019, 9:26:08 PM] []: #til: Bài học rút ra khi có sếp tồi.
- Biết phải làm sao tránh làm 1 người sếp tồi.
- Biết được cảm nhận của nhân viên.
- Đôi khi làm mình ngu đi.
- Rèn luyện tâm trí để thoát khỏi cái ngu.
- Rèn luyện tính chịu đựng tốt hơn.
[4/16/2019, 9:27:15 PM] [huy]: thực ra chỉ cần quit là xong thôi mà
[4/16/2019, 9:28:51 PM] []: thực tế là e đã quit :rip:
nhưng cũng phải rút ra bài học.
[4/16/2019, 9:31:16 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: thực ra cũng là bài học để nếu sau này mình có là leader sẽ ko rơi vào tính huống đó, view mỗi người khác nhau nên ko chắc là mình sẽ ko tạo ra cảm giác đó cho member sau này
[4/16/2019, 9:34:38 PM] []: dạ chuẩn luôn anh :adore:
[4/16/2019, 9:35:17 PM] [kinoubenkyou]: có thể cụ thể hơn ở mục 1, 4, 5 để mình tham khảo hem
[4/16/2019, 9:53:09 PM] []: Cụ thể thì mình chưa biết rõ sao với từng case.
Mình biết phải làm gì thôi.
mục 1: Biết phải làm sao tránh làm 1 người sếp tồi. =&gt; Cần học để làm sao trở thành người sếp tốt.
Người sếp tốt sẽ có Mình từng làm ở vai trò lead và gặp được sếp tốt.những yếu tố:
```
- Biết đánh giá năng lực từng thành viên trong team. Ghi nhận nỗ lực của nhân viên.
- Biết tạo cơ hội cho nhân viên được thể hiện mình và khích lệ họ.
- Giỏi về kỹ thuật ( nếu có thì càng tốt)
- Chỉ cho mình biết điều mình sai và cần phải chỉnh sửa
- Hài hước ( nếu có thì càng tốt )
- Thừa nhận sai lầm của mình và khắc phục không đổ lỗi.
- Nói chuyện thuyết phục và suy nghĩ mạch lạc, không vòng vòng. Không nói 2 lời. Đúng là đúng sai là sai. Hứa là làm.
- Tôn trọng style của nhân viên.
```
mục 4: Rèn luyện tâm trí để thoát khỏi cái ngu.
Với mình thì:
```
- Gặp những người giỏi hơn.
- Thừa nhận mình ngu dốt.
- Tập dần dần để bớt ngu.
```
mục 5: Rèn luyện tính chịu đựng tốt hơn
Với mình thì
```
- Ngủ đủ giấc vì ngủ thiếu dễ gây bực dọc và cáu bẳn.
- Ăn nhiều sữa chua trái cây để trí óc tốt hơn.
- Tập yoga
- Trong những khi làm việc cùng sếp tồi mà có khó chịu thì chưa bật ngay mà chạy ra ngoài nhà vệ sinh. Sau đó cảm thông cho họ.
```
[4/16/2019, 10:09:07 PM] []: Nói chung là khá dài dòng. Nếu chịu đọc trên google thì còn nhiều bài hướng dẫn. :smile: Bạn @kinoubenkyou có thể tham khảo trên đó.
Bạn có thể chia sẻ bài học của bạn ko?
[4/16/2019, 10:17:13 PM] [kinoubenkyou]: Mình thì may mắn chưa qua tay sếp nào mình cảm thấy là tệ, có thể do số năm đi làm của mình còn ít quá (mình chuyển ngành khá trễ). Cũng vì vậy mình muốn tham khảo cụ thể.
Thank bạn nhiều vì đã chia sẽ nhé.
[4/17/2019, 9:13:57 AM] []: #til: Dark them for slack ubuntu 18.08
At the very bottom `/usr/lib/slack/resources/app.asar.unpacked/src/static/ssb-interop.js`
add
```
// First make sure the wrapper app is loaded
document.addEventListener("DOMContentLoaded", function() {
$.ajax({
url:
"<https://raw.githubusercontent.com/laCour/slack-night-mode/master/css/raw/black.css>",
success: function(css) {
$("&lt;style&gt;&lt;/style&gt;")
.appendTo("head")
.html(css);
}
});
});
```
Refer:
- <https://mallowigi.github.io/slack-one-dark-theme/>
- <https://www.reddit.com/r/Slack/comments/94yrv7/dark_theme/>
[4/17/2019, 9:15:06 AM] [huy]: Ai dùng web có thể cài Stylus rồi copy đoạn CSS kia bỏ vô
[4/17/2019, 9:17:36 AM] []: E thấy slack dùng LESS
[4/17/2019, 9:27:00 AM] []: Bổ sung thêm cách khác - được thánh jft demo cho xem.
Link : <https://www.howtogeek.com/fyi/how-to-change-slack%E2%80%99s-annoying-purple-sidebar-color/>
[4/18/2019, 2:41:03 AM] [typescriptpher]: #til Windows Remote Desktop is awesome
[4/18/2019, 4:20:20 AM] []: #til mice on the ISS <https://youtu.be/q7lgj3aZ8dU>
[4/18/2019, 5:32:11 AM] [hieu.huynh]: YES!
[4/18/2019, 5:32:47 AM] [hieu.huynh]: ý là nào giờ anh em hay nói windoze lởm khởm trong việc development coding này nọ, khi compare với linux/mac etc…
[4/18/2019, 5:33:15 AM] [hieu.huynh]: nhưng nói đi thì cũng phải nói lại, là bọn engineer của M$ cũng làm ra nhiều thứ hay ho &amp; thú vị phếch :smile:
[4/18/2019, 5:34:08 AM] [hieu.huynh]: mấy cái sys internal tool của windows ngon lắm, remote desktop, quản lý disk etc,…. toàn ngon &amp; ít lỗi
[4/18/2019, 7:31:01 AM] [typescriptpher]: ngon nhất là mớ driver : ))
[4/18/2019, 9:06:11 PM] []: #til `:norm`
[4/19/2019, 3:10:28 AM] [dan]: context pls :think:
[4/19/2019, 10:09:01 PM] [// english-ignore]: #til about Konstantin Tsiolkovsky <https://en.m.wikipedia.org/wiki/Konstantin_Tsiolkovsky>
[4/19/2019, 10:19:04 PM] []: &gt; Tsiolkovsky spent most of his life in a log house on the outskirts of Kaluga, about 200 km (120 mi) southwest of Moscow. A recluse by nature, his unusual habits made him seem bizarre to his fellow townsfolk.
Khi bạn giỏi quá rồi, bạn không còn trong thế giới của những người anh em nữa :notbad:
[4/19/2019, 10:34:26 PM] [// english-ignore]: Cc @harrisnguyen :vayvay:
[4/19/2019, 11:42:03 PM] [Cậu Làm Vườn]: Qua nói rồi, nữa qua đi cất cái chồi trên quả đồi cho gần thiên nhiên vũ trụ :vayvay:
[4/20/2019, 9:56:07 AM] []: #til: 3 file descriptor numbers
```
STDIN.fileno # =&gt; 0
STDOUT.fileno # =&gt; 1
STDERR.fileno # =&gt; 2
```
[4/20/2019, 8:42:30 PM] []: *chòi
[4/20/2019, 9:03:29 PM] [Cậu Làm Vườn]: :okay:
[4/21/2019, 3:35:09 AM] [typescriptpher]: #til List paper của Jeff Dean <https://ai.google/research/people/jeff/>
[4/26/2019, 1:38:19 AM] [huynh.cam]: Today I truly appreciate handoff phone call. :apple: :computer: :toilet:
[4/30/2019, 1:35:27 AM] [typescriptpher]: #til <https://en.wikipedia.org/wiki/AOS_and_SOA> AOS vs SOA
[4/30/2019, 6:18:08 AM] []: #til <http://www.cureffi.org/2019/04/29/financial-modeling-in-rare-disease/>
[4/30/2019, 7:13:05 AM] [ko luong thien]: #til Writing plugins for JS's transpiler is meta programing in JS :exploding_head:
[4/30/2019, 7:05:05 PM] [typescriptpher]: ???
[5/1/2019, 12:48:49 AM] [dan]: ???
[5/1/2019, 6:06:09 AM] [ko luong thien]: #til Mod and Remainder are not the same thing thanks to Clojure's `doc`
[5/1/2019, 6:06:47 AM] [ko luong thien]: %insert change my mind meme%
[5/1/2019, 6:07:00 AM] [Cậu Làm Vườn]: Mấy nay chợ nào cũng có thiện...
[5/1/2019, 6:07:25 AM] [ko luong thien]: didn't you know that's a ~sight~ sign?
[5/1/2019, 6:07:56 AM] [Cậu Làm Vườn]: Sign?
[5/1/2019, 6:08:14 AM] [ko luong thien]: :okay: sorry
[5/1/2019, 6:08:50 AM] [Cậu Làm Vườn]: :iseewhatudid:
[5/1/2019, 6:11:10 AM] [huynh.cam]: thiện làm xong adruino.design bị đuổi rồi à?
[5/1/2019, 6:11:57 AM] [ko luong thien]: ANDUIN.DESIGN
[5/1/2019, 6:12:14 AM] [ko luong thien]: <https://github.com/anduintransaction/design> like chưa anh
[5/1/2019, 6:14:26 AM] [huynh.cam]: chưa
[5/1/2019, 6:14:33 AM] [huynh.cam]: cơ mà mình là developer mà
[5/1/2019, 6:14:46 AM] [huynh.cam]: design liên quan gì tới mềnh đâu :okay:
[5/1/2019, 6:18:56 AM] [unrealhoang]: clojure rồi à :adore:
[5/1/2019, 6:24:57 AM] [dan]: Metaprogramming trong js mà viết ở mức độ transpiler thì hơi overkill
[5/1/2019, 6:33:05 AM] [minh.nguyen]: không responsive trên màn hình điện thoại và 4k :sosad:
[5/1/2019, 6:47:32 AM] [Cậu Làm Vườn]: 4k thì cứ `max-width` mà phang tới :think: Scale ra full xấu lặm.
Còn vụ mobile thì shame @thien :bell:
[5/1/2019, 7:05:59 AM] [ko luong thien]: Anh em đòi hỏi nhiều vcl
[5/1/2019, 7:06:31 AM] [ko luong thien]: Thank to @ubolonton
[5/1/2019, 9:25:16 AM] [unrealhoang]: then why not rust
[5/1/2019, 9:25:19 AM] [unrealhoang]: :fast-omg:
[5/1/2019, 9:26:23 AM] [ko luong thien]: ClojureScript &gt; Rust + WASM?
[5/1/2019, 9:28:08 AM] [ko luong thien]: @unrealhoang với nghe bảo 1 lần trong đời nên biết lisp
[5/1/2019, 9:28:42 AM] [unrealhoang]: cũng đúng
[5/1/2019, 9:28:55 AM] [unrealhoang]: clojure là đỉnh cao của language design rồi
[5/1/2019, 9:29:37 AM] [ko luong thien]: chứ rust thì sao..
[5/1/2019, 9:31:00 AM] [unrealhoang]: rust thì nó mở mang theo 1 hướng khác
[5/1/2019, 9:35:43 AM] [ko luong thien]: hướng gì á
[5/1/2019, 9:35:48 AM] [ko luong thien]: cho nutshell
[5/1/2019, 9:40:06 AM] [unrealhoang]: system programming
[5/1/2019, 9:40:21 AM] [unrealhoang]: học để biết thêm lower level mọi thứ nó work thế nào
[5/1/2019, 9:41:11 AM] [ko luong thien]: :+1: not this year then
[5/1/2019, 9:41:18 AM] [ko luong thien]: Clojure nó generic hơn hở anh?
[5/1/2019, 9:41:30 AM] [ko luong thien]: kiểu.. more for application còn rust more for system?
[5/1/2019, 9:41:37 AM] [unrealhoang]: yep
[5/1/2019, 9:42:09 AM] [ko luong thien]: love ya
[5/1/2019, 9:42:40 AM] [unrealhoang]: học cả 2 thứ cùng lúc cũng đc mà
[5/1/2019, 9:42:41 AM] [unrealhoang]: :))
[5/1/2019, 9:42:59 AM] [ko luong thien]: next project then
[5/2/2019, 6:08:09 AM] [typescriptpher]: #til <https://en.wikipedia.org/wiki/Margaret_Hamilton_(scientist)>
```
Along with Anthony Oettinger or Barry Boehm, Margaret H. Hamilton is one of the people credited with naming the discipline of "software engineering"."According to Hamilton:
During this time at MIT, she wanted to give their software "legitimacy", just like with other engineering disciplines, so that it (and those building it) would be given its due respect; and, as a result she made up the term "software engineering" to distinguish it from other kinds of engineering.
```
[5/3/2019, 9:18:06 AM] [ko luong thien]: #til <https://gbayer.com/development/moving-files-from-one-git-repository-to-another-preserving-history/>
[5/3/2019, 3:23:31 PM] [dan]: #til table inheritance in psql and temporal tables
[5/4/2019, 1:41:40 AM] [typescriptpher]: #til <https://llvm.org/docs/Passes.html> LLVM Passes
[5/9/2019, 12:06:09 AM] [huy]: #til So many webuild-er are fucking rich. SO FUCKKKKKKKKING RICHHHHHHHHHHH
[5/9/2019, 12:23:49 AM] [huynh.cam]: Rich is relative
[5/9/2019, 1:46:41 AM] [ko luong thien]: #til Google's coordinating between public and internal review/contribute of open source projects <https://github.com/google/closure-compiler/pull/3359>
[5/9/2019, 6:48:40 PM] [meowwwwwwwwwwwwwwww]: #til
```
let a;
const obj = {a: 1, b: 2}
({a} = obj)
```
[5/9/2019, 8:42:59 PM] []: #til <https://www.infoq.com/articles/build-a-container-golang>
[5/11/2019, 9:50:01 AM] [typescriptpher]: #til Okapi BM25 <https://en.wikipedia.org/wiki/Okapi_BM25>
[5/13/2019, 3:31:52 AM] [// english-ignore]: #til lươn là cá :okay:
[5/13/2019, 3:33:14 AM] []: *Electric-type Pokémon
<https://bulbapedia.bulbagarden.net/wiki/Eelektross_(Pok%C3%A9mon)>
[5/13/2019, 4:03:27 AM] [ledongthuc]: #til Thân hình trụ, da trần, vây lưng nối liền với vây hậu môn
[5/13/2019, 4:06:57 AM] [// english-ignore]: #til lươn is a pokemon too
[5/13/2019, 4:08:00 AM] [ledongthuc]: Khi còn nhỏ, tất cả các con đều là con cái. Khi trưởng thành 1 số con chuyển thành con đực. Và khi thành con đực rồi thì 1 số con vẫn có thể trở lại thành con cái
[5/13/2019, 4:08:37 AM] [// english-ignore]: Đang nói lươn hay con pokemon ở trên vậy :open_mouth:
[5/13/2019, 4:08:54 AM] [ledongthuc]: lươn :cggt:
[5/13/2019, 4:09:10 AM] [// english-ignore]: Thể loại gì đồng bóng vỡi chưởng :disappointed:
[5/13/2019, 4:09:54 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: cháo lươn rất ngon, ngày xưa đg bên hông kênh thị nghè lúc chưa cải tạo có 1 quán lẩu lươn rất ngon, đặc biệt toàn các “chị” phục vụ vai u thịt bắp còn gọi là buê đuê
[5/13/2019, 4:10:45 AM] [// english-ignore]: lẩu buê đuê Thị Nghè nhở :vayvay:
[5/13/2019, 7:57:45 AM] [話せる森林]: Ở Hà Nội ăn lươn ngon là đến Đê La Thành có quán miến lươn giòn
[5/14/2019, 8:32:21 AM] [unrealhoang]: #til
<https://stackoverflow.com/questions/2008398/is-it-possible-to-print-out-the-size-of-a-c-class-at-compile-time/2008577>
[5/15/2019, 12:24:54 AM] [Khanh]: #til
<http://www.elitehosts.com/blog/php-ftp-passive-ftp-server-behind-nat-nightmare/>
[5/15/2019, 1:54:35 AM] [hasagi]: hay
[5/16/2019, 10:26:02 PM] [alias Trung.Le, as tle]: #til AWS Certificate has DNS validation. Step 1: create a temporary certificate with same domain name to learn which CNAME record is needed, Step 2: Add that CNAME record in DNS, Step 3: Add the intended certificate this time either with CFormation or directly with AWS CLI. Step 4: Remove the temporary certificate
[5/17/2019, 8:21:35 PM] [ko luong thien]: #til When writing internal documentation, prefer "our users" over "the users"
[5/23/2019, 8:19:02 AM] []: #til <https://www.lhh.com/our-knowledge/2019/transformation-insights-no-5/death-by-mediocre-leadership-how-bad-leaders-are-sucking-the-life-out-of-your-company>
[5/24/2019, 1:24:20 AM] [ledongthuc]: Credit Default Swap (CDS) là một dạng bảo hiểm trong trường hợp các công cụ tài chính gốc bị mất khả năng thanh toán. Công cụ tài chính có thể là cổ phiếu, trái phiếu, share, fund, nhà cửa, cho vay nặng lãi. Nó là một công cụ đẩy 1 phần rủi ro vỡ nợ cho người bán CDS và mình phải trả 1 khoản phí cho việc này.
Nói cho đơn giản thì như vầy:
- Cty Huawei phát hành trái phiếu nhằm mục đích vay nợ từ người mua trái phiếu và sẽ trả định kỳ.
- Bạn mua trái phiếu của cty Huawei như 1 kiểu cho vay có nhận lãi
- Bạn cảm giác Huawei trong tương lai gần sẽ phá sản và mất khả năng chi trả. Dẫn tới trái phiếu bạn mua trở thành tờ giấy vụn. Bạn lên sàn và thấy có người bán chứng chỉ CDS của trái phiếu Huawei, bảo hiểm trong trường hợp trái phiếu của Huawei thành tờ giấy vụn/rớt giá thì bạn sẽ dc nhận 1 khoảng tiền.
- Vậy là định kì, bạn sẽ phải trả phí cho chứng chỉ CDS bạn đang giữ. Một ngày nào đó, 1 dòng twitter nào đó được viết dẫn tới cty Huawei không còn khả năng chi trả cho trái phiếu của bạn; bạn sẽ thấy CDS của bạn tăng giá.
Về lý thuyết, bạn có thể mua CDS của một bond/share/fund/bất động sản mà không cần phải có bond/share/fund/bất động sản gốc đó. Như kiểu bạn mua xong rồi trù người ta phá sản.
Bonus 1:
Như trường hợp của Hy Lạp vào giai đoạn trước 2008, thời điểm nước này rơi vào khủng hoảng nợ và xếp hạng tín nhiệm liên tiếp bị hạ thấp, giới đầu cơ đã cược rằng Hy Lạp sẽ vỡ nợ nên ồ ạt mua các hợp đồng CDS. Với giá CDS bị đẩy lên cao khiến lãi suất trái phiếu nước này phát hành cũng phải tăng cao tương ứng để có thể bán được trái phiếu; và mức cao nhất là khi vay nợ, Chính phủ Hy Lạp phải trả lãi đến 48,6% với trái phiếu kỳ hạn 10 năm vào tháng 3/2012 - đỉnh điểm trong giai đoạn rủi ro vỡ nợ của nước này lên mức cao nhất =&gt; bòm, banh xác Hy Lạp.
Bonus 2:
Ở mỹ những năm 2018, Giấc mơ nước mỹ và nhu cầu mua nhà tăng cao. Nhiều ngân hàng nở rộ việc mọi người vay tiền mua nhà, mua xe, vay tiêu dùng, xây dựng và thế chấp tài sản để ăn tiền cổ tức.
Nhưng có rất nhiều hợp đồng thực chất là dưới chuẩn, tức là người vay không đủ khả năng chi trả và ngân hàng thời điểm này khá thoáng trong việc kiểm tra tài sản thế chấp. Việc này dẫn tới các ngân hàng muốn ăn kèo chắc ăn, họ mua các bảo hiểm CDS cho các khoảng vay này từ các bên thứ ba (ngân hàng khác, quỹ đầu tư, bảo hiểm, tín dụng) để đẩy rủi ro bớt sang bên ấy. Bên thứ ba sẽ có thể bảo hiểm 1 phần, hoặc bảo hiểm toàn phần trong trường hợp bên vay tiền mất khả năng chi trả và nợ xấu xảy ra. Bản chất lúc này, Ngân hàng vẫn ăn tiền interest từ vay, và đóng phí bảo hiểm CDS để backup, bên phát hành CDS sẽ ăn tiền phí định kì từ ngân hàng.
Vấn đề xảy ra là trong tài chính, cái mợ gì cũng có thể buôn bán được, ngay cả hợp đồng CDS. Và thế là giá trị của các hợp đồng CDS dc rao bán trên sàn như 1 công cụ tài chính. Và để bảo hiểm cho CDS bị vỡ nợ, chúng ta có CDS của các CDS, CDS của CDS của CDS, rất là inception
Và rồi chuyện gì tới nó tới. Các khoảng nợ xấu xảy ra, người đi vay không có khả năng chi trả. Các công ty phát hành CDS (ngân hàng, quỹ đầu tư, bảo hiểm, tín dụng) phải bỏ 1 số tiền lớn để thanh toán các khoản nợ xấu. Việc này dẫn tới các tổ chức ấy trên đà không có khả năng chi trả và phá sản. Và như domino, 1 loạt các CDS trở thành nợ xấu kéo theo các CDS của CDS thành nợ xấu. Và càng nhiều nợ xấu, càng nhiều người mua CDS để backup -&gt; càng làm các công ty phát hành không có khả năng chi trả.
=&gt; Bòm, banh cả lũ. Khủng hoảng kinh tế 2008 dc góm thành bởi yếu tố này.
[5/24/2019, 1:25:34 AM] [huy]: Too complex, Too long = Will not read
[5/24/2019, 1:27:49 AM] [ledongthuc]: :okay: vậy để gom lại
#til Credit Default Swap (CDS) là một dạng hợp đồng bảo hiểm, cho phép nhà đầu tư đẩy risk sang cho người phát hành CDS. Và nó có thể được giao dịch như các công cụ tài chính khác.
[5/24/2019, 1:33:10 AM] [typescriptpher]: sảy ra -&gt; xảy ra
[5/24/2019, 1:51:53 AM] [hasagi]: hay
[5/24/2019, 1:54:31 AM] []: *Ở mỹ những năm 2008?
[5/24/2019, 1:55:41 AM] [ledongthuc]: à viết nhầm :okay: mà hết edit dc rồi, thôi ráng chịu vậy =)))))
[5/24/2019, 2:18:53 AM] [kinoubenkyou]: cái CDS này có để cập trong phim The Big Short thì phải
<https://www.imdb.com/title/tt1596363/>
[5/24/2019, 2:19:34 AM] [ledongthuc]: :thinking_face: có vẻ phim hay, để cuối tuần ngồi coi thử
[5/24/2019, 5:24:38 PM] [Entropy]: nãy mới đọc thấy nghi nghi rồi, thank bác anw
[5/26/2019, 1:43:38 AM] [huynh.cam]: #til multi-core vs many-core
* Multi-core: A system with 2-8 cores and particularly does not implement parallel architecture (either at HW or SW)
* Many-core: A system with hundreds or thousands of cores and implements parallel architecture (HW and SW).
[5/26/2019, 3:20:58 AM] [ko luong thien]: #til <https://fonts.adobe.com> Great alternative to Google Fonts
[5/26/2019, 5:08:44 AM] []: Origin of p9999 :oh: <https://twitter.com/tacertain/status/1132391299733000193?s=21>
[5/26/2019, 5:44:37 AM] [vunv]: Content xịn vãi
[5/26/2019, 8:04:28 AM] [huy]: Only if you are CC member. Google Fonts still great for non member
[5/26/2019, 4:10:44 PM] [ko luong thien]: huytd outdated quá :(
[5/26/2019, 4:11:36 PM] [ko luong thien]: Adobe Fonts nó có plan free, anh accesd được font xịn nhưng limited weight (ví dụ 400 hoặc 700) trong khi CC member access full range
[5/26/2019, 4:11:40 PM] [ko luong thien]: Lêu lêu
[5/26/2019, 4:59:24 PM] [huy]: Ko care.
[5/26/2019, 5:13:37 PM] [Huy]: phim hay đó
[5/26/2019, 5:13:46 PM] [Huy]: The Big Short, Inside Job
[5/26/2019, 5:14:02 PM] [Huy]: 2 phim về khủng hoảng tài chính thế giới 2007-2008
[5/26/2019, 5:15:48 PM] [Huy]: từ 2017 <https://web.hypothes.is/blog/annotation-is-now-a-web-standard/>
[5/26/2019, 5:40:41 PM] [ko luong thien]: Bad attitude vãi :okay:
[5/26/2019, 10:33:56 PM] [quannt]: <https://send.firefox.com/>
[5/26/2019, 10:57:22 PM] [meowwwwwwwwwwwwwwww]: #til
<https://tools.ietf.org/html/rfc6648>
[5/26/2019, 11:32:31 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: #til: `systemd cat name.service` `systemd edit --full name.service`
[5/27/2019, 12:01:31 AM] [hieu.huynh]: ngon
[5/27/2019, 12:01:33 AM] [hieu.huynh]: :shake:
[5/27/2019, 12:01:47 AM] [hieu.huynh]: nào giờ em toàn phải coi status của unit
[5/27/2019, 12:01:59 AM] [hieu.huynh]: xong trong cái status, có path, rồi vim cái path đó
[5/27/2019, 12:02:01 AM] [hieu.huynh]: gà ….
[5/27/2019, 12:02:05 AM] [hieu.huynh]: :baby_chick:
[5/27/2019, 12:04:16 AM] []: hồi trước crisis có Big 5, sau crisis chỉ còn Big 4, đố a @ledongthuc biết thằng nào rớt ra khỏi nhóm? :wink:
[5/27/2019, 12:13:45 AM] [ledongthuc]: @anhtrantuan anh nhớ khúc đó là merge ấy, ko hẳn là rớt mất 1 thằng
[5/27/2019, 12:14:48 AM] [ledongthuc]: Price Waterhouse merge Coopers &amp; Lybrand =&gt; PricewaterhouseCoopers google bảo thế. Còn nội tình đứa nào nuốt đứa nào thì anh ko biết
[5/27/2019, 7:23:02 AM] []: a tìm đọc vụ Arthur Anderson với cty Enron ak
[5/27/2019, 7:24:07 AM] []: <https://www.youtube.com/watch?v=H2f7FunDuTU>
[5/27/2019, 7:24:34 AM] []: so-called originator of 2008 financial crisis :))
[5/27/2019, 9:56:45 AM] [typescriptpher]: #til <http://www.cs.tau.ac.il/~zwick/Adv-Alg-2015/Matrix-Graph-Algorithms.pdf> Thực hiện các thuật toán trên Graph bằng phép toán trên ma trận :3 Dạo này quay lại học toán nhiều thấy quay về tuổi thơ ghê :3 :3
[5/27/2019, 6:33:04 PM] []: #til <https://en.wikipedia.org/wiki/Southern_rock>
[5/28/2019, 3:24:48 AM] [Cậu Làm Vườn]: #til Anterior Pelvic Tilt
^ If you sit a lot, you might have this...
[5/28/2019, 3:28:15 AM] [Cậu Làm Vườn]: among the fixes to this problem are to strengthen glute (read: ass) and abs muscle
[5/28/2019, 7:16:28 AM] [huy]: #til why korean sucks at english <https://www.reddit.com/r/korea/comments/3zn16c/why_are_koreans_so_bad_at_english/cynn6ap?utm_source=share&amp;utm_medium=web2x>
[5/28/2019, 7:16:46 AM] [huy]: <https://gyazo.com/b5f2445091ba1adf3f989f0194afcc7a>
[5/28/2019, 5:29:07 PM] [Entropy]: Nhật thì một phần là nó khó phát âm tiếng anh hơn các nước khác :smile:
[5/28/2019, 5:30:21 PM] [unrealhoang]: Phần đó nhỏ lắm
[5/28/2019, 5:30:37 PM] [unrealhoang]: Đa số tại người ta không cần học
[5/28/2019, 6:07:34 PM] []: Chuẩn luôn. Mình có cảm giác người Nhật họ không muốn học tiếng Anh thôi.
[5/28/2019, 7:45:15 PM] [Khanh]: một phần nữa là cái gì nó cũng cố gắng phiên âm ra katakana .. xong rồi đọc quen theo katakana. lúc nói tiếng Anh cứ phải xử lý để chuyển sang giọng Anh chứ ko đc nói Katakana nên có thể họ xử lý chậm hơn hoặc cho não bò sát tự nói Katakana luôn ko kiểm soát kịp…
[5/29/2019, 12:55:42 AM] [huynh.cam]: :notbad: <https://www.giaoduc.edu.vn/nen-dung-tu-thap-nien-khong-dung-thap-ky.htm>
[5/29/2019, 1:03:07 AM] [ledongthuc]: vậy thiên niên kỷ và thế kỷ có nên đổi thành thiên niên niên và thế niên không ta ?
Hay hai từ kỷ ấy là mang nghĩ khác :thinking_face: không thấy wiki phiên âm tiếng hán của 2 cái kỷ ấy để so sánh
[5/29/2019, 1:07:57 AM] [// english-ignore]: #til kỉ = 12 năm
[5/29/2019, 1:15:46 AM] [ledongthuc]: :thinking_face:
[5/29/2019, 1:17:30 AM] [ledongthuc]: hoặc nếu chỉ dùng chữ kỷ để chỉ `period` thì `thập kỷ` vẫn đúng. Chưa rõ sẽ phải đọc sao, thế giới bước vào *thiên niên niên* mới, mọi người để hướng tới hoà bình :peach:
[5/29/2019, 1:18:48 AM] [ledongthuc]: *thế niên* này, chúng ta đã đạt được những thành tựu gì trong văn hoá và xã hội?
[5/29/2019, 1:23:02 AM] [// english-ignore]: tùy ng tùy thời :think: nghe "thập kỷ" = "khoảng thời gian 10 năm" cũng được
[5/29/2019, 1:25:07 AM] [ledongthuc]: Từ các cách lý giải trên, cho thấy: Nếu dùng “thập kỷ” (hay “thập kỉ”) để chỉ thời gian khoảng 10 (mười) năm, là không chuẩn xác, dễ hiểu lầm nhiều nghĩa, nhiều khoảng thời gian khác nhau, có thể là 10 năm, có thể là 120 năm, lại cũng có thể là... 100 triệu năm!
Vì vậy, để tránh hiểu lầm về sự nhiều nghĩa, không xác định rõ về mặt thời gian của từ “thập kỷ”, ta nên dùng từ “thập niên” để chỉ thời gian 10 (mười) năm, hoặc khoảng thời gian 10 (mười) năm. “Dùng “thập niên” như vậy vừa chính xác, đơn nghĩa, rõ ràng, dễ hiểu, giữ đúng nguyên nghĩa từ Hán Việt, lại vừa theo đúng nguyên tắc cấu tạo từ của tiếng Việt. Đây là cách dùng đúng nhất. Trong nhiều văn cảnh, dùng “thập niên” còn hay hơn, uyển chuyển, hàm súc hơn dùng số từ “chục năm” (thuần Việt) rất nhiều.
[5/29/2019, 1:25:27 AM] [ledongthuc]: đấy là bác ấy đề nghị thế, chứ mình từ nào cũng như nhau :omg: :omg: :omg: :omg:
[5/29/2019, 1:27:30 AM] [ledongthuc]: nói chứ, về căn bản thì nếu ủng hộ mọi người xài từ chính xác hơn thì cũng tốt. Chỉ là đang cân nhắc 2 từ liên quan có nên khuyến khích đổi ko thôi. Thiên niên niên và thế niên, nghe yêu phết :heart:
[5/29/2019, 1:30:23 AM] [// english-ignore]: ^ không phổ biến, vote ban
[5/29/2019, 1:30:52 AM] [// english-ignore]: nếu ai cũng hiểu "thập kì" = 10 năm thì cũng có làm sao
[5/29/2019, 1:31:12 AM] [// english-ignore]: ngôn ngữ là tiến hóa theo thời gian và quảng đại quần chúng mà
[5/29/2019, 1:31:46 AM] [ledongthuc]: :cry: đọc nghe hay vậy mà ban, thiên niên niên, địa niên niên
[5/29/2019, 1:32:37 AM] [Cậu Làm Vườn]: Người nghe có hiểu ý mình nói không -&gt; Vậy thì cái nào cũng được :parrot:
[5/29/2019, 1:33:24 AM] [// english-ignore]: giờ k hiểu thì từ từ hiểu
[5/29/2019, 1:33:35 AM] [// english-ignore]: hồi đầu có chữ "an yên" không biết đâu ra
[5/29/2019, 1:33:39 AM] [// english-ignore]: rồi "an nhiên" nữa
<https://en.wiktionary.org/wiki/an_nhi%C3%AAn> hồi đầu tưởng đứa nào phát âm lộn
[5/29/2019, 1:35:42 AM] [ledongthuc]: an nhiên thì có nghe qua, còn an yên thì mới biết :vayvay:
[5/30/2019, 9:26:58 PM] [typescriptpher]: #til Spring data is awesome
[5/31/2019, 3:55:12 AM] [ZeroX]: #til Google sử dụng search term trước để cải thiện search result cho search term sau. Bằng chứng là ban đầu em search "AST" thì không tìm thấy cái mình cần trong result list. Thay search term thành "abstract" thì lập tức nó suggest "abstract syntax tree" là cái em cần lên đầu list. Mở tab ẩn danh vào google gõ "abstract" thì nó lại suggest 1 cái kết quả khác lên đầu.
[5/31/2019, 11:40:09 PM] [Huy]: Google nó lưu tất cả các search activity luôn đó
[5/31/2019, 11:40:19 PM] [Huy]: Including voice search or voice commands
[5/31/2019, 11:40:39 PM] [Huy]: vô kiếm trong personal settings rồi tải data về sẽ thấy
[5/31/2019, 11:40:56 PM] [Huy]: Tất cả các search hay history trên Youtube các thứ cũng có
[5/31/2019, 11:41:20 PM] [Huy]: Về mặt Privacy thì mình nghĩ Google collect nhiều data hơn
[5/31/2019, 11:41:35 PM] [Huy]: Nhưng chắc ko bị exposed hay dễ khai thác như fb
[5/31/2019, 11:45:39 PM] [ledongthuc]: “em chỉ muốn giúp anh có trải nghiệm tốt hơn thôi mà” - Google chan said
[6/2/2019, 12:50:27 AM] [ko luong thien]: #til Difference between "Filter" and "Search":
&gt; *Filtering* takes an existing full list, and removes items based on criteria that match/don't match.
&gt; *Search* takes a blank slate and adds to it based on criteria that match/don't match.
[6/2/2019, 12:50:32 AM] [ko luong thien]: <https://ux.stackexchange.com/questions/4752/search-vs-filter-what-is-the-difference>
[6/2/2019, 12:52:08 AM] [ko luong thien]: Also there is the matter of ordering. Search is supposed to have "best" result(s), while Filter is not supposed to re-order results at all
[6/2/2019, 3:16:47 AM] [unrealhoang]: #til electron should have been positive charge <https://xkcd.com/567/>
[6/2/2019, 11:59:28 PM] [huy]: #til It doesn't matter how long you are planning to work, remember to plan the breaking time every 20 to 30 min
[6/3/2019, 12:02:30 AM] []: pomodoro?
[6/3/2019, 12:04:11 AM] [huy]: ko hẳn, a làm việc theo task (kanban) nên a schedule giờ nghỉ tùy theo size của task
[6/3/2019, 12:04:22 AM] [huy]: có task chỉ làm 5 phút thì gôm thành 15 phút nghỉ 1 lần
[6/3/2019, 12:04:28 AM] [huy]: có task phức tạp hơn thì 45 phút nghỉ 1 lần
[6/3/2019, 12:04:40 AM] [ledongthuc]: How much for warming up?
[6/3/2019, 12:04:41 AM] [huy]: nhưng ideally là 30 phút
[6/3/2019, 12:04:47 AM] [huy]: 5 min for warming up
[6/3/2019, 12:05:14 AM] [huy]: với cách để giảm wảm up là note đó
[6/3/2019, 12:05:25 AM] [ledongthuc]: :trollface: ít hơn mình dự đoán
[6/3/2019, 12:05:27 AM] [ledongthuc]: Tốt
[6/3/2019, 12:05:29 AM] [ledongthuc]: =)))
[6/3/2019, 12:05:58 AM] [ledongthuc]: Tưởng break mỗi 20' và warm hết 10' đọc báo
[6/3/2019, 12:06:03 AM] [huy]: :roflrofl:
[6/3/2019, 12:06:24 AM] [huy]: cũng có
[6/3/2019, 12:06:44 AM] [ledongthuc]: :pac: toy đoán không sai
[6/4/2019, 12:45:58 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: <https://docs.mongodb.com/v3.4/core/replica-set-delayed-member/>
&gt; Delayed members:
&gt; - Must be priority 0 members. Set the priority to 0 to prevent a delayed member from becoming primary.
&gt; - Should be hidden members. Always prevent applications from seeing and querying delayed members.
&gt; - `do` vote in elections for primary, if `members[n].votes` is set to 1.
[6/4/2019, 12:51:10 AM] []: Đọc thấy nhiều báo nói ko nên ngồi liên tục trên 30p nên em setup đt count down 30' là đứng dậy đi làm gì đó. Với lại em uống nước nhiều nên lợi cái là ko ngồi lì lâu được :kappa: .
[6/4/2019, 1:03:56 AM] [typescriptpher]: klq cơ mà bản 4.0 MongoDB đổi cơ chế license rồi đúng ko e? Bản 3 còn support đến bao h nhỉ?
[6/4/2019, 1:05:38 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: đổi rồi anh, em ko nhớ chi tiết lắm nhưng đại khái anh xài bản OSS của nó đi bán dịch vụ thì anh phải trả phí cho nó, ví dụ mấy thằng mongo-as-a-service như Compose (nên AWS mới có cái DocumentDB)
[6/4/2019, 1:09:37 AM] [typescriptpher]: uah, cái DocumentDB chỉ cần conpatible với MongoDB protocol :))) Bên trong tụi aws nó xài postgres để cài
[6/4/2019, 1:15:31 AM] [typescriptpher]: #til <https://wiki.postgresql.org/wiki/Foreign_data_wrappers> Xài fdw có thể nối đến file, hdfs, database khác (mysql, cassandra, mongodb), thậm chí cả... facebook, twitter, mà vẫn coi như là 1 table bên trong postgres : )
[6/4/2019, 1:19:08 AM] [ledongthuc]: em nhớ hình như nó chỉ hỗ trợ read. nhưng cũng là 1 option hay để chỉ quan tâm đến 1 cách để access thôi :+1:
[6/4/2019, 1:22:35 AM] [typescriptpher]: Từ 9.3 write thoải mái rồi em : )
Cách cài dễ nhất là dùng multicorn, 1 lib Python: <https://multicorn.org/implementing-a-fdw/>
[6/4/2019, 1:25:36 AM] [typescriptpher]: Hồi xưa anh viết cái `hn_fdw` với `reddit_hdw`, đọc hacker news với reddit từ psql, cảm giác like a boss :vayvay:
[6/4/2019, 1:28:34 AM] [ledongthuc]: hồi xưa em chỉ thử test đọc file csv thôi :smile: do hồi ấy chưa write dc nên cũng ko để ý lắm. Chủ yếu load lên xong cache lại thôi
[6/4/2019, 1:53:34 AM] []: <https://www.slideshare.net/mobile/ElizabethFrost4/postgres-plays-pokemon> này thì fdw :v
[6/4/2019, 2:30:58 AM] [huy]: e làm a nhớ tới cái này <https://twitter.com/zacharydanger/status/651823868311572480>
[6/4/2019, 2:31:00 AM] [huy]: :kappa:
[6/4/2019, 5:04:47 AM] [// english-ignore]: #til <https://en.wikipedia.org/wiki/Gamelan> nhạc cổ truyền Indo
[6/4/2019, 7:21:51 PM] []: #til: <https://speakerdeck.com/k_tsj/pattern-matching-new-feature-in-ruby-2-dot-7>
[6/5/2019, 4:39:49 AM] [huynh.cam]: #til Memcached protocol supports UDP connections :oh:
<https://corporate.tuenti.com/en/dev/blog/using-udp-in-memcached>
[6/5/2019, 4:58:55 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: <https://blog.cloudflare.com/memcrashed-major-amplification-attacks-from-port-11211/>
[6/5/2019, 7:56:16 PM] [huynh.cam]: :notbad:
[6/5/2019, 7:57:54 PM] [huynh.cam]: Cơ mà đọc có vẻ thấy vấn đề đâu phải do memcached nhỉ
[6/6/2019, 1:44:39 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :okay: sao ko thấy noti ta
uhm, ko phải vấn đề của memcached, bản chất cũng do protocol và anh nào lại mở port memcached ra public
memcached cũng chỉ bị lợi dụng để response data về cho 1 fake ip, và overload bw của target
[6/6/2019, 5:40:18 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til
<https://twitter.com/_developit/status/1136277281608032257?s=21>
[6/6/2019, 7:56:56 AM] [typescriptpher]: cái redis protocol đúng là heavy influenced by cái memcache luôn á : )))
[6/6/2019, 9:43:44 AM] []: #til: 4 style declarations Cascade algorithm : origin, merge, inheritance, specifycity
```
// this rule win
div #myParag {
color: blue;
}
div.big p {
color: green;
}
```
[6/6/2019, 9:45:54 AM] [huy]: cái đoạn code thì hiểu đc vì id bao giờ cũng có specificity rất cao, nhưng còn cái origin và merge là sao em ko hiểu bác?
[6/6/2019, 9:47:14 AM] []: Dạ không có gì cao siêu đâu bác.
- origin hiểu đơn giản là rule nào khai báo sau cùng thì nó win.
- merge là 2 rule cùng 1 target element nhưng khác property.
[6/6/2019, 9:47:43 AM] [huy]: oh, thế cái merge đó nó ưu tiên như nào
[6/6/2019, 9:50:49 AM] []: Như bác khai báo như sau:
```
p {
color: blue;
}
p {
font-site: 20px;
}
```
Thì nó sẽ merge thành 1 rule.
[6/6/2019, 9:55:19 AM] []: Chưa rõ case bác nói merge ưu tiên như nào là sao?
[6/6/2019, 10:04:43 AM] [huy]: à merge là merge như thế à
[6/6/2019, 10:04:46 AM] [huy]: vậy em hiểu rồi bác
[6/6/2019, 10:04:46 AM] [huy]: :smile:
[6/6/2019, 12:19:56 PM] [huy]: #til Expectations, not outcomes, govern the happiness of your perceived reality.
[6/9/2019, 12:18:53 AM] [Cậu Làm Vườn]: #til emulsion and emulsifer in culinary (mayonaise, vinaigrette are examples of emulsion)
Emulsion is the process of mixing two liquids that normally can't be combined.
Emulsifier is used to stabalize the mixture so it won't seperate
Example:
Mayonaise is an emulsion of lemon juice (or vinegar) and oil. Egg yolk is added as emulsifer.
Salad dressing is often made by mixing oil, water and herbs, with Dijon mustard as emulsifier
[6/9/2019, 12:19:29 AM] [Cậu Làm Vườn]: #todaytItry to make aioli and fail
[6/9/2019, 3:54:29 AM] [// english-ignore]: #til aioli
[6/9/2019, 7:56:32 AM] [SFzxc]: #til, #ruby in IRB, the underscore holds the return value for the last command, it works in the Rails console, too
```
x = 3
a = _
a # 3
```
[6/11/2019, 10:49:55 PM] []: #til Functional Programming vs Object Oriented Programming
Bài viết này tác giả đưa ra định nghĩa tối giản cho OO là Polymorphism và FP là Referential Transparency. Và kết luận là *There is no FP vs OO*, mà một hệ thống tốt nên là một hệ thống có cả 2 tính chất đặc trưng và hữu ích nhất của cả OO và FP: Polymorphism và Referential Transparency.
Benefits: Maximize flexibility, maintainability, testability, simplicity and robustness.
Đó giờ làm Ruby, chưa get hands dirty với FP bao giờ, chắc học Elixir, mở rộng thế giới quan vậy.
Link bài viết của Uncle Bob.
<http://blog.cleancoder.com/uncle-bob/2018/04/13/FPvsOO.html>
[6/11/2019, 11:12:59 PM] [// english-ignore]: &gt; Referential Transparency – no reassignment of values.
định nghĩa lạ vậy :think:
[6/12/2019, 1:18:50 AM] [ko luong thien]: This is why we chose Scala I think :think:
When designing a design system:
- OOP is good for defining (and enforcing) API
- FP is good for interaction and business logic
[6/12/2019, 2:30:17 AM] [Cậu Làm Vườn]: So, thịt ba chỉ is good :think:
[6/12/2019, 4:02:03 AM] []: hãy học haskell
[6/12/2019, 4:02:06 AM] []: :omg:
[6/12/2019, 4:05:06 AM] [ko luong thien]: &gt; Types become not only a form of guarantee, but a language for expressing the construction of programs.
I like this :think:
[6/12/2019, 4:09:39 AM] [ko luong thien]: #til <https://www.artstation.com/> thank to @kinoubenkyou
[6/12/2019, 4:15:31 AM] []: thật ra nói nghiêm túc thì Referential Transparency định nghĩa như trên ko đúng lắm
[6/12/2019, 4:16:00 AM] []: cơ mà nói cho đơn giản dễ hiểu thì gọi là bỏ `=` đi cũng đc
[6/12/2019, 4:58:27 AM] []: #til: Với ubuntu 18 không được xóa file libgnutls.so.30 trong thư mục /usr/local/lib/ và /usr/lib/x86_64-linux-gnu. Nếu xóa sẽ không boot grub được.
Cách khắc phục
- vào chế độ Try ubuntu qua usb boot không cài đặt ubuntu.
- vào partition đã cài ubuntu
- vào folder /usr/lib/x86_64-linux-gnu và `cp libgnutls.so libgnutls.so.30`. Tương tự với /usr/local/lib/
[6/13/2019, 1:58:04 AM] []: #til - Manifesto for Software Craftsmanship - <http://manifesto.softwarecraftsmanship.org/>
[6/13/2019, 1:59:18 AM] []: <http://manifesto.softwarecraftsmanship.org/#/en/reading>
List một số resources, sách chất quá
[6/13/2019, 3:02:22 AM] [khanhtc]: #til 5$ per order
<https://www.kickstarter.com/projects/894418279/i-will-turn-your-pictures-into-a-yellow-cartoon-st>
[6/13/2019, 8:40:22 AM] [話せる森林]: #til Nhật Bản Hàn Quốc và Trung Quốc không dùng được Google Map offline.
[6/13/2019, 8:03:59 PM] [Khanh]: data-maps ở Nhật hình như google mua lại của zenrin.. chắc hợp đồng giới hạn sử dụng online thôi.
[6/13/2019, 9:49:07 PM] [話せる森林]: Nghĩa là app nào làm Location base service muốn offline map sẽ phải chú ý anh nhỉ.
[6/14/2019, 8:30:43 AM] [huy]: #til
[6/14/2019, 8:31:20 AM] [huy]: #til NodeJS ko cùi bắp, 100% of the time, nếu có performance issue xảy ra, chỉ có code và người code cùi bắp, NodeJS is the best :triumph:
[6/15/2019, 12:04:25 AM] [// english-ignore]: #til License Zero
<https://licensezero.com/>
[6/16/2019, 5:09:46 AM] [Cậu Làm Vườn]: #til Alan Turing was gay :ie:
[6/16/2019, 5:10:09 AM] [unrealhoang]: :crying:
[6/16/2019, 5:10:46 AM] [unrealhoang]: Làm ngành mà không đọc về tổ nghiệp, đáng trách
[6/16/2019, 5:11:00 AM] [Cậu Làm Vườn]: :okay:
[6/16/2019, 5:12:17 AM] [Cậu Làm Vườn]: It must have been harsh to be gay in the 40s though. He was truly before his time in multiple ways.
[6/16/2019, 5:14:09 AM] [unrealhoang]: That’s why he can focus, maybe
[6/16/2019, 5:14:13 AM] [unrealhoang]: Jk
[6/16/2019, 5:14:17 AM] [unrealhoang]: :roflrofl:
[6/16/2019, 5:15:05 AM] [ko luong thien]: Đáng trách :arggg:
[6/16/2019, 5:22:31 AM] [vinh]: <https://www.imdb.com/title/tt2084970/>
Coi phim này ghiền quá trời :adore:
[6/16/2019, 6:01:43 AM] [// english-ignore]: Tụt quần xin lỗi đi :arggg:
[6/16/2019, 6:18:29 AM] [xentence]: đáng trách quá
[6/16/2019, 7:49:48 AM] [SFzxc]: gay nhưng vẫn có vợ đẹp :omg:
[6/16/2019, 9:13:55 AM] [huy]: Và cuối đời chết vì thuốc chữa gay của chính quyền :crying:
[6/16/2019, 11:59:43 AM] [huy]: #til rust is the best, nodejs is :shit:
[6/16/2019, 1:43:54 PM] [ko luong thien]: Traitorrrrrrrrr
[6/16/2019, 2:07:49 PM] [huy]: chỉ vì muốn tốt cho product của chúng ta
[6/16/2019, 4:53:03 PM] [typescriptpher]: #til xslt 3.0 is awesome <https://www.xml.com/articles/2017/02/14/why-you-should-be-using-xslt-30/>
[6/17/2019, 11:08:51 PM] []: #til To having VSCode theme per workspace:
&gt; You can have a different theme per workspace/folder by adjusting the workbench.colorTheme in the workspace settings.
<https://stackoverflow.com/questions/52514491/different-theme-per-window-in-visual-studio-code>
[6/17/2019, 11:09:36 PM] [huy]: ^ you can script that in Emacs
[6/17/2019, 11:14:04 PM] []: Me use vim || VSCode :iseewhatudid:. VSCode most of the time for now.
[6/17/2019, 11:15:11 PM] [huy]: you should use Emacs more
[6/17/2019, 11:15:20 PM] [huy]: go to #rustlang or <#C1FCYNU92|editorswar>
[6/17/2019, 11:17:09 PM] []: Nice :boy: :iseewhatudid:
[6/17/2019, 11:31:04 PM] [huy]: #til When you really want to buy a gadget but not allowed to, go to Reddit, they'll help you give it up :cry:
[6/17/2019, 11:37:47 PM] [ko luong thien]: Why "not allowed" though?
[6/17/2019, 11:38:03 PM] [ko luong thien]: Financially not allowed or morally not allowed..
[6/18/2019, 1:16:43 AM] [huy]: financially
[6/18/2019, 1:16:48 AM] [huy]: not approved
[6/18/2019, 1:16:54 AM] [huy]: by life-direct manager
[6/18/2019, 1:55:25 AM] [thai]: `life-direct manager` :troll:
[6/18/2019, 1:56:15 AM] [ko luong thien]: good husband then :+1:
[6/18/2019, 2:23:31 AM] [ZeroX]: What if vscode and emacs had a baby :think:
[6/18/2019, 8:25:51 AM] [huy]: No need for that. Emacs is great enough. There is also a bloated spacemacs which is good out of the box as well
[6/18/2019, 8:54:59 AM] [ko luong thien]: #til Future Perfect Continous
&gt; I *will have been writing* emails for one hour tomorow by 5 p.m.
[6/18/2019, 8:55:20 AM] [ko luong thien]: I'm not even sure that I have seen this kind of tense in real life but technically it exists
[6/18/2019, 3:37:05 PM] [ZeroX]: If Emacs is great enough, why people keep switching back to vscode?
[6/18/2019, 4:27:08 PM] [huy]: it's hard to explain
[6/18/2019, 4:27:14 PM] [huy]: but I'm with Emacs now
[6/18/2019, 4:27:17 PM] [huy]: vscode is the past
[6/18/2019, 4:27:19 PM] [huy]: don't mention the past
[6/18/2019, 4:27:24 PM] [huy]: let the past pass
[6/18/2019, 8:12:33 PM] []: Ngữ cảnh này bình thường mà em.
- Tầm 5 giờ chiều mai bà đang làm gì?
- Lúc đó chắc đang chạy xe từ CTY về nhà.
[6/18/2019, 8:14:36 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: #til terraform workaround `if-statements` `ebs_iops = "${var.ebs_volume_type == "io1" ? var.ebs_iops : "0"}"` :sexy:
[6/18/2019, 8:16:49 PM] [anh bán chuối]: 0.12 có if chưa ?
[6/18/2019, 8:18:27 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: hình như có rồi, mà chưa lên vì
1. chờ 1 thời gian xem có bug biếc gì ko
2. tui ko syntax mới của nó :okay:
[6/18/2019, 8:19:48 PM] [hieu.huynh]: cái này xài ngon :raised_hands: condition là true/false cũng dc, em đang xài y vậy :smile:
```
output "listener_https_arn" {
value = "${var.enable_https ? aws_lb_listener.https[0].arn : var.enable_https}"
description = "The ARN of the ALB listener HTTPS 443"
}
```
[6/18/2019, 8:21:42 PM] [Cậu Làm Vườn]: Hey, can you pick me up a little bit earlier tomorrow? I know we settled for 5pm, but my schedule change a little and I will have been waiting in the airport for 2 hours by then.
[6/18/2019, 8:21:51 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: bt a chỉ xài check true/false để bật tắt, ko biết có vụ `==`
[6/18/2019, 8:21:59 PM] [Cậu Làm Vườn]: It's kinda rare indeed. And there's probably another (better) way to convey the same message.
[6/18/2019, 8:22:52 PM] [Cậu Làm Vườn]: Something that start before a specific time in the future and still continue happenning by then.
[6/18/2019, 8:40:52 PM] [typescriptpher]: #til <https://pandoc.org/demos.html> Pandoc siu xịn, rảnh rảnh viết mấy cái templates để sinh latex, books, blog, etc từ `org-mode` luôn :3
[6/18/2019, 8:42:21 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :okay: bữa quyển rust, em thử convert từ md sang pdf để đọc trên kindle, fix hết bug render pdf đc rồi thì layout của mấy cái bảng lại bị vỡ, bỏ luôn.
[6/18/2019, 8:42:40 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: xài `pandoc`
[6/18/2019, 8:59:53 PM] [typescriptpher]: Đọc trên kindle em convert sang `mobi` ấy, rồi dùng cái send to kindle hoặc gửi email
[6/18/2019, 9:06:17 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: tìm ko ra mobi nên bữa thử convert lẹ sang pdf thôi anh :smile:
[6/18/2019, 9:06:30 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: có thằng convert sẵn … mà sang epub
[6/18/2019, 9:46:15 PM] [typescriptpher]: em search epub to mobi, có mấy tool online ổn phết :))
[6/18/2019, 9:46:32 PM] [typescriptpher]: ko thì pandoc convert ngon mà :))
[6/19/2019, 3:35:23 AM] [// english-ignore]: Thì tương lai hoàn thành tiếp diễn :smirk:
[6/20/2019, 6:46:02 PM] [Cậu Làm Vườn]: #til Direct Listing
[6/20/2019, 6:46:03 PM] [Cậu Làm Vườn]: <http://fortune.com/2019/06/20/slack-stock-ipo-dpo-direct-listing/>
[6/20/2019, 6:49:23 PM] [Cậu Làm Vườn]: Differences to IPO:
- No new shares are issued.
- No underwriter (less fee, but no safety net)
- Price is determined completely by the market demand
- No lockup period (internal investor can sell their shares right away)
[6/20/2019, 6:56:18 PM] [anh bán chuối]: Investors sẽ dump lên đầu @snacky haha
[6/20/2019, 7:48:23 PM] [huy]: :okay:
[6/23/2019, 10:45:49 PM] [ko luong thien]: #til <https://en.wikipedia.org/wiki/Gentrification>
[6/23/2019, 10:52:32 PM] [// english-ignore]: H/t @harrisnguyen :man-bowing:
[6/23/2019, 10:52:59 PM] [ko luong thien]: H/t @harrisnguyen the man of strange words
[6/24/2019, 3:36:33 AM] []: #til: About JS
- Function contructor, prototype and the 'this' keyword
- Object Literal and 'this' keyword
- Fake Namespaces
- Immediatedly Invoked Function Expresstion(IIFE)
[6/24/2019, 3:55:49 AM] [// english-ignore]: Fake namespaces?
[6/24/2019, 4:43:25 AM] [Cậu Làm Vườn]: Fake namespaces?
[6/24/2019, 6:38:06 AM] [tay vịn của anh bán chuối - cty A tìm FE]: :thinking_face: use case của IIFE bây giờ là gì nhỉ
[6/24/2019, 6:38:21 AM] [tay vịn của anh bán chuối - cty A tìm FE]: Mấy năm rồi ko xài
[6/24/2019, 8:43:33 AM] []: @duc: hiện tại case e xài cơ bản là tạo ra execution context để tránh conflict với global scope.
[6/24/2019, 8:44:56 AM] [// english-ignore]: ^ <https://wesbos.com/es6-block-scope-iife/>
[6/26/2019, 10:15:27 PM] [ko luong thien]: #til the magnificent of `/` in web routing :adore: thanks to @thaod
[6/26/2019, 10:45:25 PM] [Cậu Làm Vườn]: Mô?
[6/26/2019, 10:45:38 PM] [Cậu Làm Vườn]: Có thread không?
[6/26/2019, 10:49:29 PM] []: Web routing hồi nào :33:. Chỉ là resolving relative urls thôi mà.
[6/26/2019, 10:50:56 PM] []: @harrisnguyen <https://www.w3.org/TR/html401/struct/links.html#resolving-relative-uris>
[6/26/2019, 10:53:08 PM] [ko luong thien]: à không sau đó em mò thêm các thứ
[6/26/2019, 10:53:50 PM] [Cậu Làm Vườn]: Hãy là một #til-er có tâm nà
[6/26/2019, 10:54:17 PM] []: Đúng dồi, share thêm đi @thien
[6/26/2019, 10:54:37 PM] [huy]: Deleted vì til ko có tâm
[6/26/2019, 10:54:48 PM] [huy]: Muốn bị delete ko?
[6/26/2019, 11:10:40 PM] [ko luong thien]: .. nãy đang gõ thì đi họp..
[6/26/2019, 11:15:57 PM] [ko luong thien]: câu chuyện lúc đầu là em cần link từ "<http://xyz.xyz/foo/bar|xyz.xyz/foo/bar>" đến "<http://xyz.xyz/baz|xyz.xyz/baz>", mà theo em nhớ thì không nên (hay không thể?) làm relative link (như kiểu "../baz") nên em hỏi chị @thaod, chị Thảo mới leak ra là xài "/baz"
sau đó mò típ từ cái link trên qua tới express js thì #til là `/abc/` và `/abc` khác nhau xa vời vợi nhưng hầu hết các dịch vụ nó normalize cái đó cho mình, cho nên nếu gỡ cái normalize đó ra thì 90% là expected nhưng 10% kia là thú vị
sau đó mới nhận ra là cái đó nó cũng apply cho root routing, tức là `<http://xyz.xyz|xyz.xyz>` và `<http://xyz.xyz/|xyz.xyz/>` có thể là 2 thứ khác nhau
[6/26/2019, 11:16:27 PM] [ko luong thien]: nói chung cái #til này là beginner stuff mà :okay: chủ yếu đang ôn phỏng vấn nên cần quay lại..
[6/27/2019, 12:49:22 AM] [manhdv]: van ko hieu thien noi gi :neutral_face:
[6/28/2019, 2:40:39 PM] [Huy]: Ý thiện nói là cái <http://xyz.xyz|xyz.xyz> và <http://xyz.xyz/|xyz.xyz/> nhìn giống nhau nhưng thực ra không phải
[7/1/2019, 2:40:28 AM] [ko luong thien]: #til props vs attribute in Web API thanks to @harrisnguyen <https://javascript.info/dom-attributes-and-properties>
[7/1/2019, 3:24:04 AM] [vinh]: cái `/` này lúc đầu viết mấy cái location cho nginx cũng lộn miết :disappointed:
[7/1/2019, 11:52:39 PM] [ledongthuc]: #til DuckDuckGo có browser app riêng trên android
[7/2/2019, 12:50:46 AM] [// english-ignore]: Hãy dùng Firefox Focus :thinkhard:
[7/2/2019, 1:26:39 AM] [話せる森林]: #til Trải nghiệm VSCode LiveShare rất thích. Tạo tài khoản đăng nhập trên server xong về nhà ngồi remote vào code xong deploy thẳng luôn rất nhanh và thú vị. Lúc mạng chậm thì bấm ctrl+z sẽ hay bị lỗi.
[7/2/2019, 1:46:40 AM] []: #til: Library và Framework
- Jquery là library còn Vue, React, Angular, là framework
- `Hollywood Principle` or `Inversion of Control`
- Imperative and Declarative Programing
[7/2/2019, 1:49:52 AM] [vunv]: react là library mà nhỉ :think:
[7/2/2019, 2:03:56 AM] [ko luong thien]: react là library nhưng behaviour cứ như framework :vayvay:
[7/2/2019, 2:06:30 AM] [ko luong thien]: để rõ ý hơn: react nên được xem là library dựa vào 2 thứ:
1) react tự nhận là library
2) bản chất của react (reactjs to be exact) là cung cấp 1 function (ReactDOM.render) có input (DOM instructions e.g. JSX) và output (a DOM manager)
Cơ mà cái input của function này thì nó đề ra rất nhiều khía cạnh, và thường thì có thể cao hơn cả scope của những framework khác. Ở khía cạnh này thì react (without react dom) nó gần với framework hơn.
[7/2/2019, 2:07:11 AM] [ko luong thien]: có 1 cái rule of thumb khá vui, là framework is exclusive but libraries can be used together
[7/2/2019, 2:07:45 AM] [vunv]: #til
[7/2/2019, 2:33:16 AM] []: ```bản chất của react (reactjs to be exact) là cung cấp 1 function (ReactDOM.render) có input (DOM instructions e.g. JSX) và output (a DOM manager)```
=&gt; Có thể giải thích rõ hơn được ko bạn ? Nó liên quan đến như thế nào của việc phân loại React vào library ?
[7/2/2019, 2:38:20 AM] [ko luong thien]: @haond cái phần bạn quote ở trên là phần mà mình bảo là react nó nghiêng về framework :smile: tức là nó hướng người dùng làm việc (work) theo 1 cái cách (frame) mà nó cho là tốt, ví dụ JSX, lifecycle, render props, HOC. In other words, nó có khá nhiều "best practices"
[7/2/2019, 2:38:39 AM] [ko luong thien]: còn việc nó nghiêng về library thì là do nó cung cấp 1 function, có input output rõ ràng.
[7/2/2019, 2:38:54 AM] [ko luong thien]: cá nhân mình k quan trọng nó là library hay framework lắm :smile: mình chỉ quan trọng nó có document hay không thôi..
[7/2/2019, 2:43:00 AM] []: @thien: haha, đã edited. Mình cũng ko quan trọng về vụ này lắm. Mình đánh giá nó ở framework nhiều hơn là library.
[7/2/2019, 3:45:13 AM] []: #til: TypeScript in Emacs <http://redgreenrepeat.com/2018/05/04/typescript-in-emacs/>
[7/2/2019, 1:59:44 PM] [huy]: #til Với babel 7, xài `.babelrc` thì babel sẽ chỉ transform những file trong local project, muốn transform luôn những package trong node_modules thì phải xài `babel.config.js`
[7/3/2019, 11:55:58 PM] []: #til `rspec bisect`
[7/4/2019, 12:09:24 AM] [anh bán chuối]: ko xài mac ah, trên mac ko biết performance có tốt ko
[7/4/2019, 1:43:16 AM] [話せる森林]: Em đang tích iền mua chắc tháng sau nữa thì đủ.
[7/4/2019, 3:43:03 AM] [vthang]: #til Akka is Scala’s implementation of an Actor concurrency model made popular in part by Erlang
[7/4/2019, 8:20:40 PM] []: #til <https://dev.mysql.com/doc/refman/5.5/en/fulltext-natural-language.html>
[7/5/2019, 12:50:26 AM] []: #til <https://why-upgrade.depesz.com>
[7/5/2019, 1:15:53 AM] [hieu.huynh]: cty vẫn đang chạy MySQL 5.5 à?
[7/5/2019, 1:16:19 AM] [hieu.huynh]: góc phải có chỗ chọn version đó, tìm version mới (hoặc đúng version đang xài ra đọc cho đúng)
[7/5/2019, 1:20:31 AM] []: 5.7
[7/5/2019, 1:20:35 AM] []: :okay:
[7/7/2019, 9:25:05 AM] [ko luong thien]: #til `There is always a github repo for that` thanks to @nguyenquangminh
[7/7/2019, 11:26:50 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: #til: Tới giờ mới biết `127.0.0.53` -&gt; `127.0.0.0/8` <https://serverfault.com/a/402940> (vô tình đọc đc 1 issue về systemd-resolve với 127.0.0.53) :okay:
[7/8/2019, 12:45:52 AM] [ZeroX]: #til 3.5 SATA HDD need more power so the SATA to usb cable is useless in this case :arggg:
[7/9/2019, 4:57:27 PM] [ZeroX]: #til `sudo apt autoremove` is evil!!!
[7/9/2019, 5:45:45 PM] [Cậu Làm Vườn]: ^ can you elaborate?
[7/9/2019, 6:04:33 PM] [ZeroX]: autoremove can undesiredly remove packages that are still in use. For example, every single app that are not installed via apt. Lightdm or other display manager and their related packages could also be deleted by this command.
Proof <https://www.google.com/search?q=auto+remove+boot+hang>
[7/9/2019, 11:23:27 PM] [ko luong thien]: ?
[7/9/2019, 11:24:58 PM] [huy]: ?
[7/9/2019, 11:26:10 PM] []: :smile:, Tự xóa rầu
[7/9/2019, 11:27:00 PM] []: #til, One thing I’ve realized is some kindle books on Amazon JP are much cheaper than on Amazon Global :disappointed:
<https://i.gyazo.com/eb8eb83eda0cd171cd916c2f55546a67.png>
<https://i.gyazo.com/88eb1de181480d00296822988909d445.png>
[7/9/2019, 11:32:18 PM] []: Hay mình xài chức năng loan books của Kindle ta? Có đồng chí nào xài thử chưa nhở, vì mềnh mua sách bên Amazon JP, tận dụng giá tốt rồi chuyển sách từ account Amazon JP sang <http://Amazon.com|Amazon.com>
<https://www.amazon.com/gp/help/customer/display.html?nodeId=200549320>
[7/9/2019, 11:38:35 PM] [thai]: “làm thái” là làm gì ấy nhỉ :thinkold:
[7/9/2019, 11:38:55 PM] [huy]: nuru
[7/9/2019, 11:41:46 PM] [ko luong thien]: I see
[7/9/2019, 11:47:04 PM] []: Đã test, ứ đc :))
[7/9/2019, 11:58:15 PM] [anh bán chuối]: @mquy
[7/10/2019, 12:40:14 AM] [Khanh]: : ))
[7/10/2019, 12:40:28 AM] [Internet Explorer 7.0]: :smoke:
[7/10/2019, 12:40:39 AM] [Khanh]: cảm giác như bọn Nhật có trợ giá sách
[7/10/2019, 3:52:02 AM] [noob]: <https://twitter.com/0xinfection/status/1148267196306427904?s=12>
[7/10/2019, 12:55:43 PM] []: <https://www.sciencedirect.com/science/article/abs/pii/S0950584918302210>
[7/10/2019, 7:50:57 PM] []: #til <https://github.com/s0md3v/AwesomeXSS>
[7/11/2019, 12:47:03 AM] [huy]: #til Redux/useReducer: Kinh nghiệm khi viết reducer, là đối với default case, nên throw error thay vì trả về state mặc định, lý do là: để dễ debug khi lỡ dispatch sai action type thì còn biết.
[7/11/2019, 12:51:40 AM] [tay vịn của anh bán chuối - cty A tìm FE]: thím có nhiêu cái reducer :think:
[7/11/2019, 12:51:47 AM] [tay vịn của anh bán chuối - cty A tìm FE]: dự là 1
[7/11/2019, 12:52:04 AM] [huy]: uhm 1
[7/11/2019, 12:52:09 AM] [tay vịn của anh bán chuối - cty A tìm FE]: ok fine
[7/11/2019, 12:52:17 AM] [huy]: nhiều thì sao
[7/11/2019, 12:52:40 AM] [huy]: nghĩ cũng tương tự thôi
[7/11/2019, 12:52:46 AM] [tay vịn của anh bán chuối - cty A tìm FE]: thử đi
[7/11/2019, 12:52:54 AM] [huy]: case nào combine nhiều reducer thì combine, drain hết thì nên throw
[7/11/2019, 1:28:56 AM] [tuandh]: thì cuối cùng cũng chỉ có 1 reducer root thôi mà
[7/11/2019, 3:08:54 AM] [ledongthuc]: #til bio-engineering <https://en.wikipedia.org/wiki/Biological_engineering>
```
is the application of principles of biology and the tools of engineering to create usable, tangible, economically viable products
```
Sản phẩm làm ra: bộ phận giả cho người khuyết tật; phân tích, xử lý tín hiệu cơ thể
=&gt; Ngành này mục tiêu là:
- Mô phỏng/thay thế/tăng cường lại cơ chế sinh học bằng công nghệ
- Sửa đổi/kiểm soát/phân tích hệ thống sinh học.
[7/11/2019, 3:35:58 AM] [ko luong thien]: cứ throw error hết đi
[7/11/2019, 3:36:03 AM] [ko luong thien]: error &gt; nuốt
[7/11/2019, 3:36:17 AM] [ko luong thien]: còn muốn mạnh tay nữa thì chơi ở mức độ language nào :v
[7/11/2019, 3:36:28 AM] [ko luong thien]: reducer mà match thiếu case thì auto fail compile
[7/11/2019, 7:59:48 AM] [huy]: Rust đó
[7/11/2019, 3:56:02 PM] [ptgamr]: neu dung TypeScript thi co cai Exhaustive Type Checking, cung check dc
[7/11/2019, 5:28:30 PM] [huy]: Cơ mà trong case của reducer
[7/11/2019, 5:28:33 PM] [huy]: thì có vẻ ko work
[7/11/2019, 5:28:41 PM] [huy]: vì nó có biết mình sẽ có bao nhiêu cái action đâu
[7/11/2019, 5:29:09 PM] [huy]: à trừ khi dùng union type
[7/11/2019, 8:05:12 PM] []: #til:
<https://www.educba.com/typescript-vs-es6/>
<https://hackernoon.com/i-finally-understand-static-vs-dynamic-typing-and-you-will-too-ad0c2bd0acc7>
[7/12/2019, 1:07:49 AM] [tuandh]: 1 actiontype có thể có nhiều action gọi tới nó
[7/12/2019, 1:34:39 PM] [huy]: #til <http://Tinhte.VN|Tinhte.VN> dùng Next.js / styled-jsx. Nguồn: tay trong
[7/12/2019, 1:37:21 PM] [ko luong thien]: disclaimer là 1 year ago
[7/12/2019, 4:57:18 PM] [huy]: #til `Backbone.Layout.el`
[7/12/2019, 10:27:59 PM] []: #til: resolution
- 72 ppi ( pixels per inch ) display images for desktop
- 300 dpi ( dots per inch ) print materials (books, magazines,...)
- ppi: resolution of images is number of squares / ( 1 inch * 1 inch )
- dpi: resolution of images is number of circles / ( 1 inch * 1 inch )
[7/13/2019, 1:01:46 AM] [ko luong thien]: #til parenthetical statements
[7/13/2019, 5:20:49 AM] [dat]: #til <https://twitter.com/oasace/status/1149181539000864769>
[7/13/2019, 8:18:05 PM] [// english-ignore]: #til `git pull --autostash`
<https://mobile.twitter.com/TejasKumar_/status/1149700419129618433>
[7/13/2019, 9:06:10 PM] []: the frustration is real :roflrofl:
[7/14/2019, 7:29:48 PM] [thuanpt]: --[no-]autostash option is only valid with --rebase.
[7/15/2019, 12:29:35 AM] [huy]: #til Python's `memory_profiler`
```
$ python -m memory_profiler memoryview/copy.py
Content length: 10240000, content to write length 10238976
Filename: memoryview/copy.py
Mem usage Increment Line Contents
======================================
@profile
9.883 MB 0.000 MB def read_random():
9.887 MB 0.004 MB with open("/dev/urandom", "rb") as source:
19.656 MB 9.770 MB content = source.read(1024 * 10000)
29.422 MB 9.766 MB content_to_write = content[1024:]
29.422 MB 0.000 MB print("Content length: %d, content to write length %d" %
29.434 MB 0.012 MB (len(content), len(content_to_write)))
29.434 MB 0.000 MB with open("/dev/null", "wb") as target:
29.434 MB 0.000 MB target.write(content_to_write)
```
[7/16/2019, 4:27:21 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: #til `Cache your sessions. Don't piss off your users` <https://dormando.livejournal.com/495593.html> :oh: -&gt; `dormando` top contribute for memcached
[7/16/2019, 9:33:00 PM] [話せる森林]: #til <http://translate.google.com/toolkit|translate.google.com/toolkit>
[7/17/2019, 11:05:35 PM] [anh bán chuối]: #til all gem install from git are having .git directory in bundle path, and it can be 700M+ for wkhtmltopdf-binary gem :disappointed:
[7/18/2019, 2:33:46 AM] [minh.nguyen]: Rule of thumb: don’t install from git
[7/18/2019, 5:50:31 AM] [anh bán chuối]: Yeah. Anh publish len ruby gem luon. Còn private gem from git thì install xong xoá thư mục git đi
[7/21/2019, 7:33:07 PM] [話せる森林]: #til git for-each-ref —format=‘%(commiterdate) %09 %(authorname) %09 %(refname)’ | sort -k5n -k2M -k3n -k4n
[7/21/2019, 7:34:35 PM] [話せる森林]: Cụ thể là học được trong git có for-each-ref và cách format chúng. Ví dụ bằng câu lệnh liệt kê tất cả các branch và người đầu tiên tạo ra chúng.
[7/21/2019, 10:35:17 PM] [Khanh]: use case là tìm commit đầu tiên của branch-feature để get hết commit trong branch đem đi release à em.
[7/23/2019, 11:19:13 PM] [huy]: #til Nhà ở Mẽo khác nhà ở VN cái cơ bản nhất: Không có hầm cầu. Vì thế, nước thải, chất thải được dẫn hết vào 1 đường ống duy nhất, dẫn thẳng ra đường ống cống của thành phố.
[7/23/2019, 11:26:05 PM] [huynh.cam]: :facepalm:
[7/23/2019, 11:33:44 PM] [tay vịn của anh bán chuối - cty A tìm FE]: @thien tìm keyword nổ bể phốt xem chơi cho biết
[7/24/2019, 12:39:33 AM] [thai]: thắc mắc đường ống cống của thành phố dẫn ra đâu
[7/24/2019, 12:40:11 AM] [huy]: dẫn tới trung tâm xử lý nước thải
[7/24/2019, 1:08:06 AM] [ko luong thien]: sao nguy hiểm vl thế
[7/24/2019, 1:09:36 AM] [huy]: như thê có gì mà nguy hiểm
[7/24/2019, 1:41:04 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: #til <https://www.freedesktop.org/software/systemd/man/systemd.timer.html>
[7/24/2019, 2:52:10 AM] []: dùng để làm gì á anh
[7/24/2019, 3:01:57 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: xài như cron á, mà systemd style
[7/24/2019, 8:38:12 AM] []: À dạ
[7/24/2019, 8:38:20 AM] []: Systemd cái gì cũng có
[7/24/2019, 8:38:24 AM] []: :trollface:
[7/24/2019, 11:38:18 PM] [ko luong thien]: #til
```
// assume that our user is focusing on an &lt;input /&gt;
button.onMouseDown = (event) =&gt; {
event.preventDefault();
// do something with that &lt;input /&gt; without losing
// user's focus on it. For example:
input.value = input.value + 1;
}
```
[7/24/2019, 11:47:29 PM] [Cậu Làm Vườn]: To elaborate, click event happens like this (sort of): mousedown -&gt; focus -&gt; mouseup -&gt; click. So if you call `preventDefault` right in mousedown, it's gonna skip the focus.
[7/26/2019, 6:31:52 AM] [ledongthuc]: #til
2 hay nhiều cá thể hoà hợp là khi:
```
- the adult in me meets the adult in you.
- the child in me meets the child in you.
- the naughty in me meets the naughty in you.
```
<https://psiloveyou.xyz/true-love-framework-the-story-of-a-failed-research-study-5b4262a11dc0>
[7/26/2019, 6:40:53 AM] [// english-ignore]: .xyz domains makes me wonder the reliability of its content
[7/26/2019, 6:45:39 AM] [ledongthuc]: có thể ko đúng hết với mình, nhưng nếu học dc gì thì học thôi.
[7/26/2019, 9:50:19 AM] [hasagi]: My company is <https://be.xyz>
[7/26/2019, 9:50:22 AM] [hasagi]: :disappointed:
[7/26/2019, 10:35:47 AM] [ledongthuc]: :thinking_face: really!!! thường domain đó toàn mấy trang quảng cáo, hoặc sex
[7/26/2019, 10:41:31 AM] [hasagi]: bởi
[7/26/2019, 10:41:33 AM] [hasagi]: =))
[7/27/2019, 8:04:36 AM] [ledongthuc]: #til camera của Mi 8 pro chống rung tốt quá. Vừa chạy vừa quay mà ko bị rung tí nào :shake:
[7/27/2019, 5:34:30 PM] [Cậu Làm Vườn]: #til ...
<https://www.typescriptlang.org/docs/handbook/modules.html#export--and-import--require>
[7/27/2019, 5:35:27 PM] [Cậu Làm Vườn]: `import zip = require("./ZipCodeValidator");` &lt;--- this is valid in TS
[7/28/2019, 8:21:16 PM] []: <https://triplebyte.com/blog/how-to-interview-engineers> - Nhiều điều thú vị và hữu ích về việc phỏng vấn software engineers
[7/30/2019, 2:39:51 AM] [hieu.huynh]: #til “Another flaw in the human character is that everybody wants to build and nobody wants to do maintenance.” - Kurt Vonnegut
[7/30/2019, 11:20:20 PM] [huy]: #til Pok3r: `L_Win + R_Alt + Spacebar`: Make the bottom right corner as arrow keys.
[7/31/2019, 5:40:02 AM] [Cậu Làm Vườn]: #til mì hai con tôm có từ trước năm 75
[7/31/2019, 5:41:03 AM] [Cậu Làm Vườn]: <https://news.zing.vn/vua-mi-tom-miliket-ton-tai-bang-hai-con-tom-post675323.html>
[7/31/2019, 5:43:31 AM] [Cậu Làm Vườn]: nhắc đây tự nhiên nhớ chuyện hồi bé, lần đầu đòi ăn mì gói, chắc đâu tầm 4-5 năm tuổi gì đó
[7/31/2019, 5:43:55 AM] [Cậu Làm Vườn]: lúc mẹ bưng tô mì ra không thấy tôm đâu hụt hẫng ghê gớm
[7/31/2019, 5:46:54 AM] [// english-ignore]: dạo này chỉ ăn mì Omachi, hoặc Hảo Hảo
[7/31/2019, 5:47:43 AM] [huynh.cam]: Ở Phin có bán omachi nữa hả
[7/31/2019, 5:49:23 AM] [// english-ignore]: Có tiệm bên này nhập qua. 0.6-0.7€ một gói thì phải. Không thì mì Hờn Quất 1-2€
[8/1/2019, 4:20:30 PM] [huy]: #til `git log -S "string"`: Search toàn bộ git history, tìm ra thời điểm một string được thêm vào/xóa đi
[8/1/2019, 8:24:09 PM] [meowwwwwwwwwwwwwwww]: #til `OPTIMIZE TABLE`<https://www.thegeekstuff.com/2016/04/mysql-optimize-table>
[8/1/2019, 11:23:49 PM] [// english-ignore]: <https://www.merriam-webster.com/words-at-play/butt-words> :lacmong:
[8/4/2019, 9:14:59 PM] [tb]: #til *Enterprise Integration Patterns* <https://stackoverflow.com/a/11540451>
[8/5/2019, 12:45:59 PM] [huy]: #tir: “Write for your audience” means, in part, gambling on what they know. (cc @thien)
[8/5/2019, 12:47:20 PM] [ko luong thien]: ref nào
[8/5/2019, 12:51:31 PM] [huy]: <https://www.nytimes.com/2017/11/25/opinion/sunday/how-to-get-your-mind-to-read.html?action=click&amp;module=RelatedLinks&amp;pgtype=Article>
[8/7/2019, 7:10:05 AM] [tucq88]: lâu quá ko vào, có xịt đít ko =))
[8/7/2019, 7:30:34 AM] [huy]: Có 2 loại luôn :))
[8/7/2019, 3:45:05 PM] [huy]: #til There's no tool, digital or physical, could help you focus on your task, except your fucking self. -- Jack Huy
[8/7/2019, 6:24:29 PM] [ko luong thien]: Có mùi pomoday bị drop ròi
[8/7/2019, 7:49:06 PM] [unrealhoang]: có vẻ thế
[8/7/2019, 8:05:37 PM] [ko luong thien]: cc investor @arvernorix
[8/7/2019, 9:57:16 PM] [huy]: tầm bậy tầm bạ
[8/7/2019, 11:36:21 PM] []: #til - Make the changes easy (it’s hard) and then make the easy change.
Nay thấm thía luôn, when working with legacy code.
[8/8/2019, 1:47:14 AM] []: :))
[8/8/2019, 4:14:16 PM] [huy]: #til `font-feature-settings: "tnum";`
[8/9/2019, 7:17:20 PM] [Cậu Làm Vườn]: #til I had the wrong assumption on how messages are encrypted in SSL connection
<https://twitter.com/b0rk/status/1159820455534125056>
[8/9/2019, 7:21:09 PM] [unrealhoang]: học lớp intro to cryptography của dan boneh đi <https://www.coursera.org/learn/crypto>
[8/9/2019, 7:21:47 PM] [Cậu Làm Vườn]: :adore:
[8/9/2019, 7:22:18 PM] [unrealhoang]: course này không quá nặng nề
[8/9/2019, 7:22:27 PM] [unrealhoang]: đa số là introductory
[8/9/2019, 8:13:41 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: rất nhiều người hiểu sai, mình từng pv nhiều bạn câu này và hầu như đều trả lời sai gần hết, chỉ có đúng duy nhất 1 bạn trả lời đúng.
[8/10/2019, 12:46:41 PM] [// english-ignore]: #til Carabiner <https://en.wikipedia.org/wiki/Carabiner>
[8/11/2019, 12:28:14 AM] []: #til As a rule of thumb, if you feel the need to comment on something inside a method, you should take this code and put it in a new method. Even a single line can should be split off into a separate method, if it requires explanations. And if the method has a descriptive name, nobody will need to look at the code to see what it does.
Quyển Refactoring này viết khá dễ hiểu.
[8/11/2019, 2:45:46 PM] [Huy]: @xluffy cái này là câu pv cho vị trí làm an ninh mạng hả bác
[8/11/2019, 3:22:41 PM] [Huy]: móa, cái bài dài vãi hóa ra chỉ là vì dốt từ vựng nên lười đọc sách
[8/11/2019, 3:22:42 PM] [Huy]: =))
[8/11/2019, 3:24:18 PM] [Huy]: cái này e thấy bản chất vẫn là "tuổi nhỏ làm việc nhỏ" thôi
[8/11/2019, 3:24:34 PM] [Huy]: ví dụ e thường coi phim hay đọc sách thêm để học tiếng Anh
[8/11/2019, 3:24:45 PM] [Huy]: chứ không phải ngược lại, học từ vựng để đọc được sách
[8/11/2019, 3:24:58 PM] [Huy]: có thể vì mình không phải là dân native
[8/11/2019, 3:25:52 PM] [Huy]: nhưng e cũng thấy nhiều trường hợp thành công như bài nói, học từ vựng trước rồi sẽ đọc sách tốt hơn
[8/11/2019, 3:26:18 PM] [Huy]: ví dụ người ta học + thi Toefl hay GMAT
[8/11/2019, 3:26:34 PM] [Huy]: đa số việc phải làm vẫn là học từ mới
[8/11/2019, 5:50:44 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: devops bác, câu này cơ bản mà, vị trí nào hỏi cũng đc, mình nghĩ trg nào cũng dạy môn Bảo mật thông tin cơ bản.
[8/12/2019, 5:17:28 AM] []: Hồi xưa thấy hợp lí nhưng sau này thấy ko còn chính xác nữa
[8/12/2019, 5:17:52 AM] []: Vẫn có trường hợp cần
[8/12/2019, 5:18:29 AM] []: Tại nếu extract ra thì có thể nó ko còn cùng mức abstraction dẫn tới đọc khó hiểu hơn
[8/12/2019, 9:08:24 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til <https://www.youtube.com/watch?v=XFOgjrqqdkE>
[8/12/2019, 10:00:18 PM] [huynh.cam]: #til tree shaking in JavaScript world means dead code elimination :face_with_rolling_eyes:
[8/12/2019, 10:55:03 PM] [huy]: don't make such assumption
[8/12/2019, 10:55:17 PM] [huy]: it's one of the techniques for dead code elimination in JS bundlers
[8/12/2019, 10:55:23 PM] [huy]: doesn't mean it's a mapped term
[8/12/2019, 10:59:04 PM] [huynh.cam]: what does it do other than dead code elimination?
[8/12/2019, 11:00:20 PM] [huynh.cam]: a name that doesn't imply what it does is a bad name IMO
[8/12/2019, 11:02:50 PM] [huy]: I donno
[8/12/2019, 11:04:00 PM] [qq]: the name does tell what it does on the abstract syntax tree, dead code elimination is an application.
[8/12/2019, 11:04:27 PM] [huynh.cam]: tree trimming?
[8/12/2019, 11:04:53 PM] [huynh.cam]: dead code elimination is an established term
[8/12/2019, 11:05:10 PM] [huynh.cam]: <https://en.wikipedia.org/wiki/Dead_code_elimination>
[8/12/2019, 11:06:45 PM] [qq]: <https://we-build-vn.slack.com/archives/C16AY670U/p1565676267053300?thread_ts=1565672418.051600&amp;cid=C16AY670U>
tree pruning I think
[8/12/2019, 11:07:35 PM] [huynh.cam]: better than tree shaking :shrug:
[8/12/2019, 11:08:50 PM] [huynh.cam]: mà thôi mình hơi khó tính rồi :grin:
[8/12/2019, 11:21:21 PM] [huy]: wait
[8/12/2019, 11:21:24 PM] [huy]: mà e tưởng tree shaking
[8/12/2019, 11:21:26 PM] [huy]: là term chung
[8/12/2019, 11:21:29 PM] [huy]: đâu phải riêng mỗi bên js
[8/12/2019, 11:23:25 PM] [noob]: Hai cái này khác nhau mà
[8/12/2019, 11:24:01 PM] [noob]: Tree shaking là khái niệm do anh của @harrisnguyen đẻ ra, lúc đầu bị chửi quá trời :roflrofl:
[8/12/2019, 11:44:18 PM] [huynh.cam]: khác nhau chỗ nào vại?
[8/13/2019, 12:08:28 AM] [noob]: một bên là gom lại rồi xóa, một bên xóa trước khi gom lại :think:
[8/13/2019, 12:44:58 AM] [huynh.cam]: cách implement khác nhau ko làm cho tụi nó khác nhau
[8/13/2019, 12:45:19 AM] [huynh.cam]: nếu argue tree shaking là 1 *technique* để làm dead code elimination thì mình đồng ý
[8/13/2019, 12:46:41 AM] [Cậu Làm Vườn]: ^ Điểm này em thấy phần đông là agree á anh.
[8/13/2019, 12:48:03 AM] [huynh.cam]: but still, bad name :shrug:
[8/13/2019, 12:50:11 AM] [Cậu Làm Vườn]: Bài của anh trai em :omg:
<https://medium.com/@Rich_Harris/tree-shaking-versus-dead-code-elimination-d3765df85c80>
[8/13/2019, 12:51:21 AM] [Cậu Làm Vườn]: <https://twitter.com/rauschma/status/678835068165595136>
[8/13/2019, 12:52:26 AM] [Cậu Làm Vườn]: TLDR; Lúc Rich Harris popularize cái term đó là nó cũng đã là established term trong cộng đồng rồi (especially in Dart community back then)
[8/13/2019, 12:53:59 AM] [Cậu Làm Vườn]: &gt; I thought about using the ‘live code inclusion’ phrase with Rollup, but it seemed that I’d just be adding even more confusion seeing as tree-shaking is an existing concept. Maybe that was the wrong decision?
[8/13/2019, 12:55:22 AM] [huynh.cam]: ủa mà vd một đoạn code JS vầy
```
import Foo from "foo"
Foo.bar()
```
[8/13/2019, 12:55:51 AM] [huynh.cam]: trong Foo còn các hàm khác như `.bar1`, `.bar2`, ...
[8/13/2019, 12:56:05 AM] [huynh.cam]: thì nó sẽ _shake_ luôn các hàm đó à?
[8/13/2019, 12:56:34 AM] [huynh.cam]: (nếu `.bar` ko xài các hàm đó)
[8/13/2019, 12:57:11 AM] [noob]: về lý thuyết là vậy, mỗi bundlers nó sẽ có cách làm khác nhau, support tới mức đó hoặc ko
[8/13/2019, 12:57:18 AM] [huy]: uhm
[8/13/2019, 12:58:51 AM] [huynh.cam]: interesting
[8/13/2019, 1:16:52 AM] [huy]: #til "Vũ trụ VSCode" -- coined by @nhducit
[8/13/2019, 5:06:04 AM] [ledongthuc]: #til cà phê pha bằng sữa oat uống cũng ngon ghê :smoke:
[8/13/2019, 5:07:57 AM] [// english-ignore]: The best nhé, uống nó phê phê cháy cháy
[8/13/2019, 5:08:08 AM] [// english-ignore]: Căn bản là k bị tào tháo rượt so với sữa bò
[8/13/2019, 5:08:29 AM] [ledongthuc]: :clap: đúng đúng ^
[8/13/2019, 5:09:04 AM] [// english-ignore]: Oatly là ngon nhất :two_hearts:
[8/13/2019, 5:42:45 AM] [Cậu Làm Vườn]: How about almond milk? :think:
[8/13/2019, 5:46:21 AM] [// english-ignore]: Mùi hơi kì :-? như mùi sơn móng tay đó
[8/13/2019, 5:51:35 AM] [ledongthuc]: hồi xưa có thử với sữa đậu nành, thấy cũng không hợp bằng oat
[8/13/2019, 5:55:42 AM] [// english-ignore]: oat làm sữa thì được, chứ làm mấy cái khác hơi ghê
[8/13/2019, 5:55:45 AM] [// english-ignore]: à cháo cũng ngon
[8/13/2019, 5:55:48 AM] [// english-ignore]: kem ghê lắm
[8/13/2019, 5:57:27 AM] [ledongthuc]: @kcj.pop.com_rbvn ăn nhiều món dị quá :shake:
[8/13/2019, 5:57:31 AM] [ledongthuc]: kem oat
[8/13/2019, 5:58:14 AM] [// english-ignore]: thì nó bán mà ._. mua ăn thử thôi
[8/13/2019, 8:42:41 AM] [SFzxc]: em thì rang với đường nâu xong bốc ăn :omg:
[8/13/2019, 8:52:19 PM] [ledongthuc]: #til AWS marketplace deploy bằng cơm :shake:
[8/13/2019, 8:56:13 PM] [hieu.huynh]: link? :think:
[8/13/2019, 8:57:51 PM] [ledongthuc]: mail và file excel dc ko :shake:
[8/13/2019, 8:59:02 PM] [ledongthuc]: đang phải ngồi gõ 1 mớ trong excel file + package system gửi cho họ đây
[8/13/2019, 9:12:13 PM] [hieu.huynh]: :oh:
[8/13/2019, 9:13:27 PM] [ledongthuc]: :shake: và mớ field đang phải ngồi điền
[8/13/2019, 9:13:49 PM] [ledongthuc]: điền xong sẽ package hệ thống gửi bên họ + viết cloudformation để setup
[8/13/2019, 9:14:04 PM] [ledongthuc]: hoặc chỉ họ cách setup, họ viết cloudformation dùm
[8/13/2019, 9:15:13 PM] [ledongthuc]: :duncare:
[8/13/2019, 9:15:20 PM] [ledongthuc]: cuộc đời này thật thú dzị
[8/13/2019, 9:22:04 PM] [hieu.huynh]: :roflrofl: thủ công mỹ nghệ vậy
[8/14/2019, 1:15:01 AM] [ledongthuc]: #til Github actions xài cũng có vẻ vui nhỉ :smile: đang thử build cái flow CI/CD của cty trên này
[8/14/2019, 1:54:55 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :roflrofl:nãy giờ tưởng oat là goat :))) nghĩ bụng thịt dê cũng ngon mà :vayvay:
[8/14/2019, 3:47:42 AM] [// english-ignore]: #til `xmllint` <https://stuartb.dev/validate-xml-on-a-mac/>
[8/14/2019, 8:26:26 AM] [ko luong thien]: :ie: but #til how to do parallax scrolling using CSS only (perspective &amp; z coordinate) thank to @quybeans
<https://developers.google.com/web/updates/2016/12/performant-parallaxing>
[8/14/2019, 8:06:13 PM] [Cậu Làm Vườn]: Nay rằm tháng 7, #til how to make chè trôi nước
[8/14/2019, 9:38:16 PM] [// english-ignore]: Thôn nữ miền Tây là đây chứ đâu :adore:
[8/15/2019, 12:06:40 AM] [// english-ignore]: #til <https://en.wikipedia.org/wiki/Strange_loop>
&gt; A quine in software programming is a program that produces a new version of itself without any input from the outside. A similar concept is metamorphic code.
[8/15/2019, 12:45:02 AM] [Cậu Làm Vườn]: Thôn nữ da hơi đen, râu hơi rậm :kappa:
[8/15/2019, 12:45:40 AM] [// english-ignore]: Hình or didn't happen
[8/15/2019, 12:46:48 AM] [huy]: #til It's ok to leave some shit in your code, as long as you don't forget to return and pay it back <https://github.com/zalopay-oss/effective-engineer/blob/master/08-build-quality-with-pragmatism.md#repay-technical-debt>
[8/15/2019, 1:14:44 AM] [ko luong thien]: :ie: but #til name a color by its intention (e.g. `primary`) instead of its literal value (e.g. `blue`) or usages (e.g. `border-color`)
[8/15/2019, 1:19:07 AM] [unrealhoang]: how about the intention is to be blue? i.e. `blue-corner` :roflrofl:
[8/15/2019, 10:53:23 PM] [huy]: :ie: but #til: Opera dùng nhân chromium :scream:
[8/15/2019, 10:54:12 PM] [unrealhoang]: :ie: but :ie: dùng nhân chromium
[8/15/2019, 10:54:46 PM] [huy]: :notbad:
[8/15/2019, 10:55:15 PM] [huy]: in the next 30 years, yes
[8/15/2019, 11:04:18 PM] [hieu.huynh]: :raised_hands:
[8/15/2019, 11:04:32 PM] [hieu.huynh]: chromium rules the world
[8/15/2019, 11:05:00 PM] [unrealhoang]: and become the next ie
[8/15/2019, 11:05:06 PM] [unrealhoang]: rip web
[8/17/2019, 8:18:36 AM] [ko luong thien]: #til DUPLO is compatible with LEGO
[8/17/2019, 11:37:24 PM] [dat]: you either die a hero
[8/18/2019, 12:51:00 AM] [// english-ignore]: #til the history of WASD keys <https://en.m.wikipedia.org/wiki/Arrow_keys#WASD_keys> và anh Dennis Fong 42t mà nhìn trẻ dễ sợ
[8/18/2019, 2:09:43 AM] [ko luong thien]: #til <https://2ality.com/2018/02/numeric-separators.html>
[8/20/2019, 12:05:46 AM] [ko luong thien]: #til `e.g., foo` is grammatically correct, `e.g. foo` is not
[8/20/2019, 12:12:46 AM] [// english-ignore]: <https://en.wiktionary.org/wiki/e.g>.
&gt; In US English, "e.g." sometimes will be followed by a comma. However, usually it is not, and it is never followed by a comma in other English-speaking parts.
[8/20/2019, 12:25:31 AM] [nghĩ koi]: #til Markdown can be used for diff highlights
<https://dev.to/yechielk/these-lifehacks-will-change-the-way-you-write-markdown-3651>
[8/22/2019, 1:01:56 AM] [// english-ignore]: #til multipart/related <https://stackoverflow.com/questions/39960417/whats-the-difference-between-multipart-related-and-multipart-form-data-and>
Ngoài ra còn cả nùi multipart khác <https://docs.microsoft.com/en-us/previous-versions/exchange-server/exchange-10/ms527355(v=exchg.10)>
[8/22/2019, 7:07:13 AM] [Cậu Làm Vườn]: may never ever use this but #til css `prefers-reduced-motion`
[8/22/2019, 7:37:54 PM] [dthtien]: #til `<https://www.rubymap.com>`
[8/23/2019, 12:03:30 AM] [Mon]: #til `shame.css`. thank @thien
[8/23/2019, 12:09:32 AM] [// english-ignore]: @thien có bao nhiêu đệ nằm vùng trong này vậy?
[8/23/2019, 10:03:55 AM] [ko luong thien]: Sụyt
[8/25/2019, 3:12:12 AM] [// english-ignore]: #til "motorway" is the British way of saying "đường cao tốc" :cold_sweat: <https://www.thefreedictionary.com/motorway>
[8/25/2019, 4:48:46 PM] [ko luong thien]: #til <https://www.typescriptlang.org/docs/handbook/classes.html#constructor-functions>
[8/26/2019, 1:22:16 AM] [ZeroX]: Did you know about this too?
<https://www.youtube.com/watch?v=wfMtDGfHWpA>
[8/26/2019, 8:06:48 PM] []: #til Internal ELBs are resolveable publicly by anyone, they’ll just provide the private IP addresses the elb is listening on
[8/27/2019, 9:10:31 AM] [ko luong thien]: I should have known this sooner :okay: <https://www.nngroup.com/articles/drop-down-menus/>
[8/27/2019, 10:24:08 AM] [huy]: now we're here talking about research based UX
[8/27/2019, 10:26:05 AM] [ko luong thien]: ?
[8/27/2019, 10:38:42 AM] [huy]: remember when we talk about choosing font based on metrics and based on user's feeling?
[8/27/2019, 10:40:44 AM] [ko luong thien]: they are similar, aren’t they? The researches explicitly stated that they prefer “to rely on what users actually do, rather than what they say they do”
[8/27/2019, 10:41:12 AM] [ko luong thien]: I mean.. what’s the difference you are tryin to show me here?
[8/27/2019, 10:57:33 AM] [huy]: I mean, fuk you
[8/27/2019, 10:58:32 AM] [ko luong thien]: ..
[8/27/2019, 9:46:13 PM] []: Not cool, bro @snacky :face_with_rolling_eyes:
[8/27/2019, 10:38:09 PM] [huy]: yeah, troi dao nay nong qua
[8/27/2019, 10:38:10 PM] [huy]: :disappointed:
[8/27/2019, 10:56:34 PM] [ko luong thien]: Đề nghị anh xin lỗi công khai để phục hồi danh dự :triumph:
[8/27/2019, 11:43:12 PM] [huy]: #til procrastination is something comes from latin, "pro" mean "forward", and "crastinatus" which mean "till next day"
[8/29/2019, 3:01:54 AM] [anh]: Theo hán nôm thì liêu là người cùng làm với mình một việc gì đó, hoặc cũng có nghĩa là tốt đẹp, `quan liêu` = người cùng làm quan với mình, `đồng liêu` = đồng nghiệp <https://hvdic.thivien.net/hv/liêu> <https://hvdic.thivien.net/whv/%E5%AE%98%E5%83%9A>
[8/29/2019, 3:47:04 AM] [// english-ignore]: "Lang Liêu" là người cùng làm chồng với mình?
[8/29/2019, 3:47:24 AM] [// english-ignore]: "cô liêu" là người cùng làm cô với mình?
[8/29/2019, 3:58:18 AM] [// english-ignore]: :bow: đang troll mà gặp Thức thì nghỉ troll ngay
[8/30/2019, 12:15:55 AM] [// english-ignore]: Giờ mới biết tên chính thức của cái ý tưởng trong clip này `<https://www.youtube.com/watch?v=czgOWmtGVGs>`
Holocene calendar <https://en.wikipedia.org/wiki/Holocene_calendar>
[9/5/2019, 5:32:06 PM] [huy]: #til <https://developer.mozilla.org/en-US/docs/Web/HTML/Element/progress>
[9/6/2019, 10:51:21 AM] [huy]: #til JavaScript's `Intl`
[9/9/2019, 2:11:17 AM] [ko luong thien]: #til <https://en.wikipedia.org/wiki/Sieve_of_Eratosthenes>
[9/9/2019, 3:12:19 AM] [dat]: Netscape
[9/9/2019, 8:37:59 AM] [ko luong thien]: hồi đó k được đi học đm'
[9/9/2019, 10:08:48 AM] [ko luong thien]: #til <https://github.com/vlang/v> nhớ @mquy quá noob ơi
[9/9/2019, 10:58:57 AM] [dat]: mà sao anh gặp vậy :))
[9/9/2019, 11:06:21 AM] [// english-ignore]: #til con sên này ăn luôn đồng bọn yếu thế :shake:
<https://en.m.wikipedia.org/wiki/Spanish_slug>
[9/9/2019, 6:35:52 PM] [manhdv]: đừng buồn thien ơi vẫn còn tui nữa :sosad:
[9/9/2019, 9:31:14 PM] [ko luong thien]: @taurandat leetcode easy mode
[9/11/2019, 1:16:57 PM] [huy]: #til A single value (number, string, boolean,...) can be considered as a valid JSON string
[9/11/2019, 8:07:04 PM] []: #til YAML is not that simple
<https://learnxinyminutes.com/docs/yaml/>
[9/13/2019, 2:25:35 AM] [// english-ignore]: #til Doppelgänger: người song trùng
[9/13/2019, 2:41:12 AM] [Entropy]: #til linux keybinding = pain :disappointed: <http://xahlee.info/kbd/linux_vs_windows_vs_mac_best_keybinding.html>
[9/13/2019, 3:45:08 AM] [dat]: tên con Gengar trong Pokemon có nguồn gốc từ từ này nè :3
[9/13/2019, 3:52:01 AM] [// english-ignore]: <https://twitter.com/GlobalEcoGuy/status/1164732075301146624?s=19>
Amazon không sản sinh ra 20% oxy như lời đồn
[9/13/2019, 3:52:37 AM] [// english-ignore]: :thumbsup::ghost:
[9/20/2019, 8:00:18 PM] []: #til <https://en.wikipedia.org/wiki/CE_marking>
[9/20/2019, 8:01:02 PM] []: Mi band 4 (China version - có mic, NFC) không có CE mark và rẻ hơn bản Global (ko Mic, ko NFC) 200-300k :think:
[9/20/2019, 11:10:13 PM] [ko luong thien]: #til <https://developer.mozilla.org/en-US/docs/Web/Security/Subresource_Integrity>
[9/21/2019, 1:42:26 AM] [ko luong thien]: #til Conditional and dynamic styles
&gt; While the state in front-end applications started getting more and more advanced, CSS was still static. We were only able to apply sets of styles conditionally — if a button was primary, we would probably apply the class “primary” and define its styles in a separate CSS file to apply how it’s going to look like on the screen. Having a couple of predefined button variations was manageable, but what if we want to have a variety of buttons, like specific ones tailored for Twitter, Facebook, Pinterest and who knows what else? What we really want to do is simply pass a color and define states with CSS like hover, focus, disabled etc. This is called dynamic styling because we’re no longer switching between predefined styles — we don’t know what’s coming next. Inline styles might come to mind for tackling this problem, but they don’t support pseudo-classes, attribute selectors, media queries, or the like.
[9/21/2019, 1:42:38 AM] [ko luong thien]: @arvernorix <@UM5UD8XQV> <https://github.com/axieinfinity/festival/blob/master/component_props.md> &lt;~ nos la cais nafy nef
[9/21/2019, 2:02:45 AM] [ko luong thien]: #til `&lt;img sizes="..."&gt;` works in all major browsers :neutral_face:
[9/21/2019, 3:29:47 AM] [ko luong thien]: Actually it’s not really the same..
[9/21/2019, 3:45:55 AM] [trung]: `srcSet` cũng thế, chỉ có đứa nào dở người mới đi xóa code của anh thôi
[9/21/2019, 3:47:03 AM] [trung]: đứa nào viết về cái conditional với dynamic styles vậy
[9/21/2019, 3:47:15 AM] [trung]: &gt; Inline styles might come to mind for tackling this problem, but they don’t support pseudo-classes, attribute selectors, media queries, or the like.
cái này super important nhé
[9/21/2019, 3:49:05 AM] [ko luong thien]: @arvernorix 1 trong mấy cái này <https://github.com/axieinfinity/festival/issues/14>
[9/21/2019, 3:50:12 AM] [ko luong thien]: so với last discussion với @quybeans thì #til CSS Blocks với Stylable. Goal bọn nó là bring type system to CSS
[9/21/2019, 3:56:58 AM] [trung]: point của em là gì
[9/21/2019, 3:57:04 AM] [trung]: em muốn làm gì
[9/21/2019, 3:58:07 AM] [ko luong thien]: em muốn coi bi giờ CSS có cái gì zui, và tụi nó khác nhau gì
[9/21/2019, 3:58:23 AM] [trung]: học CSS animation trc đi kìa
[9/21/2019, 3:59:05 AM] [ko luong thien]: cái trên nhiều $$$ hơn :omg:
[9/21/2019, 3:59:33 AM] [ko luong thien]: đùa chứ flow with the work thôi :okay:
[9/21/2019, 4:00:03 AM] [trung]: Thiện toàn làm mấy cái tào lao
[9/21/2019, 4:00:24 AM] [trung]: phí phạm thời gian cty E
[9/21/2019, 4:00:36 AM] [ko luong thien]: đang cuối tuần mà :arggg:
[9/23/2019, 1:01:38 AM] [// english-ignore]: #til
_repatriate_ (v) to bring or send back (a person, especially a prisoner of war, a refugee, etc.) to his or her country or land of citizenship.
_repatriation_ (n) sự hồi hương
[9/24/2019, 10:26:43 AM] [unrealhoang]: #til <https://mathwithbaddrawings.com/2013/06/16/ultimate-tic-tac-toe/> :scream:
[9/25/2019, 1:57:53 AM] [vinhphu3000]: <https://www.spinnaker.io/>
[9/25/2019, 1:57:59 AM] [vinhphu3000]: hôm nay thấy cái này hay
[9/25/2019, 1:58:06 AM] [vinhphu3000]: có anh/em nào sữ dụng thử qua chưa
[9/25/2019, 2:00:43 AM] [dat]: de viet bot cho choi tro nay :))
[9/25/2019, 2:02:04 AM] []: có test thử mà phức tạp quá nên ko thử nữa
[9/25/2019, 2:40:50 AM] [vinhphu3000]: mình đọc trong Business Insider thấy là google đang sponsor cho cái này, và nó là next big thing !?
[9/25/2019, 4:10:31 AM] [minh.nguyen]: #til <http://learnvimscriptthehardway.stevelosh.com/chapters/05.html>
[9/25/2019, 11:15:02 AM] []: :)) bị dụ dễ vậy
[9/25/2019, 11:15:20 AM] []: Cái đó mà next big thing gì
[9/26/2019, 12:18:55 AM] [n]: #til use `bt` or `bt all` (LLDB) in Xcode console to quickly print full stack trace. Better version than `Thread.callStackSymbols` :open_mouth:
[9/28/2019, 11:51:44 PM] [ko luong thien]: #til JS’s `valueOf`, `toString` and `[Symbol.toPrimitive]
<https://javascript.info/object-toprimitive#tostring-valueof>
[10/10/2019, 3:49:05 PM] [huy]: #til `vim <https://page-url-here.com/>` for example `vim <https://thefullsnack.com/>`
[10/10/2019, 9:48:44 PM] [unrealhoang]: Nice example :roflrofl:
[10/10/2019, 10:19:23 PM] [huy]: best for pr
[10/15/2019, 12:13:08 AM] [ko luong thien]: #til themself is the valid singular of themselves
[10/15/2019, 12:13:49 AM] [unrealhoang]: also: singular they
[10/15/2019, 12:15:20 AM] []: meaning I can use `they is ...` and `they does ...`? :think:
[10/17/2019, 3:13:54 AM] [// english-ignore]: ^ if preferring to a person whose gender you don't know yet , maybe yes :think:
[10/17/2019, 3:14:15 AM] [// english-ignore]: a better version = using their name
[10/17/2019, 3:14:46 AM] [// english-ignore]: #til <https://en.wikipedia.org/wiki/ISO_week_date> in ISO week date, weekday number starts from 1 with Mon = 1, ..., Sun = 7
[10/17/2019, 3:14:50 AM] [ko luong thien]: Ân nói rất đúng :v
[10/17/2019, 3:15:52 AM] [// english-ignore]: Thiện nói không sai :v
[10/17/2019, 5:48:40 PM] [huy]: #til Khi bạn thấy hết động lực để tiếp tục làm cái side project của mình, thì hãy ngồi refactor code của nó :thinkmid:
[10/17/2019, 6:34:19 PM] []: đập ra viết lại bằng language/framework khác :troll:
[10/17/2019, 6:50:31 PM] []: Tình trạng chung của 90% side projects: đến mùa quýt tác giả mới đủ động lực để hoàn chỉnh đc :))
[10/17/2019, 7:28:08 PM] []: refactor code là một chuyến đi không có điểm đến :doubt:
[10/17/2019, 8:09:22 PM] [Cậu Làm Vườn]: Tức là lúc trước khi refactor còn cảm giác muốn níu kéo. Ngồi refactor xong thì quyết định bỏ luôn, không còn gì tiếc núi. Nó giúp ta đạt được trạng thái peace of mind.
[10/17/2019, 9:23:46 PM] [// english-ignore]: "tiếc núi" :thinkhard:
[10/17/2019, 9:32:57 PM] [Cậu Làm Vườn]: :okay:
[10/17/2019, 10:39:30 PM] [typescriptpher]: #til khi 20 cái PR gần nhất của bạn bắt đầu bằng "Fix ...", tức là product của bạn đã production ready
[10/17/2019, 10:40:00 PM] [unrealhoang]: such wisdom
[10/17/2019, 10:46:17 PM] [typescriptpher]: :truestory:
[10/17/2019, 10:46:30 PM] [typescriptpher]: ủa chưa có cái emo đó ah :roflrofl:
[10/17/2019, 10:53:42 PM] [huy]: :omg:
[10/17/2019, 11:10:08 PM] [unrealhoang]: `cal`
[10/17/2019, 11:10:24 PM] [unrealhoang]: thanks @snacky
[10/17/2019, 11:10:55 PM] [ledongthuc]: thanks @snacky
[10/17/2019, 11:13:37 PM] [huy]: đờ heo, ae ko biết cái này à
[10/17/2019, 11:14:41 PM] [Scott Dang]: #til :pray: :sosad:
[10/17/2019, 11:16:02 PM] [ledongthuc]: đâu phải ai cũng ở Silicon Valley, cái nôi của công nghệ để biết hết đâu :sosad:
[10/17/2019, 11:19:56 PM] [unrealhoang]: nobody knows everything, that’s why we have #til :doubt:
[10/17/2019, 11:22:08 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: toàn dùng để check cal trên server :v
[10/17/2019, 11:23:00 PM] []: thanks anh @snacky
[10/17/2019, 11:24:06 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: ```
cal -3
```
[10/17/2019, 11:28:56 PM] [// english-ignore]: `cal 2019`
[10/17/2019, 11:28:56 PM] [huy]: 1. `cal 2020`
2. copy all
3. in ra làm lịch
4. đem bán
[10/17/2019, 11:29:03 PM] [huy]: @kcj.pop.com_rbvn kém
[10/17/2019, 11:29:23 PM] [// english-ignore]: kém giè
[10/17/2019, 11:29:46 PM] [huy]: 4 steps to profit
[10/17/2019, 11:30:19 PM] [// english-ignore]: làm đi ._. mị chờ
[10/17/2019, 11:30:33 PM] [huy]: :ogm
[10/17/2019, 11:31:11 PM] [huy]: vậy mới quái
[10/17/2019, 11:31:44 PM] [// english-ignore]: mà thiệt, đang xài mac, tại sao click vô cái ngày trên top bar nó không xổ cái lịch ra như trong gnome linux. Mac sucks
[10/17/2019, 11:34:08 PM] [huy]: có nà <https://www.mowglii.com/itsycal/>
[10/17/2019, 11:35:53 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: &gt; mà thiệt, đang xài mac, tại sao click vô cái ngày trên top bar nó không xổ cái lịch ra như trong gnome linux. Mac sucks
yah, hơi bị ghét cái này của mac, phải bật calendar app lên mới xem đc :neutral_face:
[10/17/2019, 11:43:56 PM] []: fantasical 2
[10/17/2019, 11:45:12 PM] [stronglong]: ra nhanh quá thì bản sau ko có gì mới :))))
[10/17/2019, 11:45:19 PM] [stronglong]: như snap windows đó
[10/17/2019, 11:46:19 PM] [stronglong]: hồi beta catalina ém hàng bảo là có mà giờ có đâuu :slightly_smiling_face:
[10/17/2019, 11:52:49 PM] [hieu.huynh]: ```
-bash: cal: command not found
```
:doubt:
[10/18/2019, 12:00:16 AM] [hieu.huynh]: mấy distro minimal mới bây giờ, drop hết mấy gói package này rồi :byeanim:
[10/18/2019, 12:01:10 AM] [hieu.huynh]: btw, công nhận cái datetime trên top bar của mac dở òm
[10/18/2019, 2:29:26 AM] [dat]: #til <https://blog.jcoglan.com/2017/09/19/the-patience-diff-algorithm/>
[10/18/2019, 2:29:59 AM] [dat]: <https://github.com/janestreet/patdiff>
[10/20/2019, 1:02:51 AM] [dat]: #til the placeholder lyrics for the opening verse of Yesterday: “Scrambled eggs/Oh my baby how I love your legs/Not as much as I love scrambled eggs” -&gt; “Yesterday/All my troubles seemed so far away/Now it looks as though they’re here to stay”
<https://en.wikipedia.org/wiki/Yesterday_(Beatles_song)>
[10/20/2019, 2:13:40 AM] [ko luong thien]: thank to @kcj.pop.com_rbvn, #til `20$20` is a valid format of currency (it means 20.00 unit)
[10/20/2019, 2:29:30 PM] [huy]: #til Parse JS Date (`YYYY-MM-DD`) in your local timezone:
```
new Date(`${str}T00:00:00`)
```
[10/20/2019, 2:34:45 PM] [huy]: Reason: By default, the timezone of Date.parse is GMT
[10/23/2019, 12:54:22 PM] [ko luong thien]: #til <https://en.wikipedia.org/wiki/Responsibility_assignment_matrix>
[10/23/2019, 12:59:12 PM] [// english-ignore]: `<https://www.youtube.com/watch?v=Yy2RIZ-14FM>` 3h sáng rồi :zzz:
[10/27/2019, 6:52:58 PM] [tay vịn của anh bán chuối - cty A tìm FE]: #til JS doesn’t have official icon
[10/27/2019, 6:54:27 PM] [ko luong thien]: It doesn't even have a proper date time formattingstandard for f*ck sake :okay:
[10/27/2019, 6:55:03 PM] [tay vịn của anh bán chuối - cty A tìm FE]: :okay:
[10/27/2019, 10:41:19 PM] [tay vịn của anh bán chuối - cty A tìm FE]: #til muộn mằn = muộn màng
[10/28/2019, 1:15:34 PM] [huynh.cam]: #til vì sao bút chì không có chì nhưng vẫn gọi là bút chì
<http://www.todayifoundout.com/index.php/2010/11/why-pencil-lead-is-called-lead/>
[10/28/2019, 1:19:35 PM] [huy]: :timer_clock: *Saved you a 5 minutes because of the horrible page layout/ads/writing:*
- Graphite: The thing that pencil's leads are made from
- When graphite was first discovered, people think it was a form of lead, so they called it: black lead
- That's why
[10/28/2019, 7:18:45 PM] []: Thank caption. Graphite in Vietnamese is "than chì"
[10/28/2019, 11:58:23 PM] [// english-ignore]: thank translation
[10/29/2019, 3:47:52 AM] [typescriptpher]: #til vue-cli có option useTaobaoRegistry, sẽ trỏ npm registry đến thẳng Taobao
[10/31/2019, 4:20:42 AM] [hasagi]: =))
[10/31/2019, 10:13:09 AM] [Duy Phuong]: <https://viblo.asia/p/co-ban-ve-web-workers-ORNZqwpL50n>
[10/31/2019, 10:14:04 AM] [Duy Phuong]: giờ mới được khai sáng về Web API
[11/1/2019, 12:25:22 AM] []: #til “now page”
&gt; So a website with a link that says “now” goes to a page that tells you what this person is focused on at this point in their life. For short, we call it a “now page”.
<https://nownownow.com/about>
[11/3/2019, 5:12:55 PM] []: hi @trungdq88! :troll:
[11/6/2019, 7:24:50 PM] [n]: #macos #til Use `SecItemImport` to extract the `SecIdentityRef` from p12 file without importing to the KeyChian. Ref: <https://forums.developer.apple.com/thread/31711>
[11/8/2019, 10:17:21 AM] [dat]: #til Mac sux <https://stackoverflow.com/questions/7383426/cloning-a-git-repo-and-it-already-has-a-dirty-working-directory-whaaaaa>
[11/9/2019, 12:48:13 AM] [Cậu Làm Vườn]: #til Gmail has keyboard shortcut...
[11/9/2019, 12:50:09 AM] [huy]: #til Not only `+` can be use to create aliased email, you can also use `.`, for example `h.u.y.t.d`, `<http://h.uy.td|h.uy.td>`, `<http://huy.td|huy.td>`,... are the same as `huytd` (Gmail only)
[11/9/2019, 1:03:06 AM] [Cậu Làm Vườn]: Có thể bạn biết rồi: khi đăng kí dịch vụ bằng email ở đâu đó, có thể tag thêm info vào phía sau `+`
1. Biết được cái automatic system nào đó lấy được mail của bạn qua nguồn nào
2. Set một cái filter để nó auto label incoming email.
Ex: <mailto:snacky+newsletter@gmail.com|snacky+newsletter@gmail.com>, <mailto:snacky+personalservice@gmail.com|snacky+personalservice@gmail.com>, <mailto:snacky+youtube@gmail.com|snacky+youtube@gmail.com>
[11/9/2019, 8:31:21 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til <https://twitter.com/dan_abramov/status/1192898770842931209?s=20>
[11/12/2019, 12:52:53 AM] [ledongthuc]: <https://www.priceintelligently.com/blog/arr>
Annual Recurring Revenue (ARR)
- subscriptions value of contract one year period
- Only valid with agreement 1 year or more
- excludes subscription consumption
- excludes variable fees
[11/12/2019, 12:57:54 AM] [ko luong thien]: bài này hay quá mà @ledongthuc share trong thread nên mình mang ra đây <http://boringtechnology.club>
[11/12/2019, 12:59:17 AM] [ledongthuc]: hồi xưa có share cho @nhducit một lần rồi.
Nhưng Đức diếm làm của riêng, không share lại cho mọi người đấy
[11/12/2019, 12:59:32 AM] [ko luong thien]: thất vọng về @nhducit :arggg:
[11/12/2019, 12:59:52 AM] [unrealhoang]: but but but, can you at least choose secured technology?
[11/12/2019, 1:07:57 AM] [tay vịn của anh bán chuối - cty A tìm FE]: tưởng cái này cũ rồi
[11/12/2019, 1:08:00 AM] [tay vịn của anh bán chuối - cty A tìm FE]: :think:
[11/12/2019, 1:09:08 AM] [tay vịn của anh bán chuối - cty A tìm FE]: nhưng ở đây là webuild, chúng ra chỉ nói về trending tech thôi, vì cần show off để kiếm việc mới chứ :roflrofl:
[11/12/2019, 1:58:27 AM] [unrealhoang]: đúng rồi
[11/12/2019, 1:58:35 AM] [unrealhoang]: như HN chỉ có tech hay ho
[11/12/2019, 1:58:43 AM] [unrealhoang]: làm gì còn ai nói về ruby hay rails hay nodejs
[11/12/2019, 1:58:44 AM] [unrealhoang]: :roflrofl:
[11/12/2019, 2:18:46 AM] [// english-ignore]: <https://andygrove.io/2019/11/rust-2020-rust-needs-to-be-boring/> bữa thấy có link trong bài này
[11/12/2019, 2:19:12 AM] [// english-ignore]: JS không phải là boring tech còn gì, 1995 muốn gì nữa
[11/13/2019, 8:44:44 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til
```Since on iPadOS User Agent in Safari is same as on MacOS Catalina```
[11/13/2019, 8:46:13 AM] [huy]: :shake:
[11/15/2019, 12:05:37 AM] [unrealhoang]: rip, rải CV đi anh ei :vayvay:
[11/15/2019, 12:05:49 AM] [anh bán chuối]: cc @d.hoang =))
[11/15/2019, 12:06:29 AM] [anh bán chuối]: thất nghiệp rồi @unrealhoang
chuẩn bị tuyển ruby ở Saigon nè, ai join ko :))
[11/15/2019, 12:07:31 AM] [unrealhoang]: remote từ jp đc ko :disappointed:
[11/15/2019, 12:08:34 AM] [anh bán chuối]: dc luôn :)) nói nghiêm túc :v
[11/15/2019, 12:09:01 AM] [unrealhoang]: :shake: :adore:
[11/15/2019, 12:11:34 AM] [_hoang_nguyen_]: anh Long cty riêng hả?
[11/15/2019, 12:12:43 AM] [anh bán chuối]: ko, đi làm thuê code dạo thôi :disappointed: cc cái vụ share hình slack =))
[11/15/2019, 12:22:17 AM] [hieu.huynh]: móa, thấy ghê vây
[11/15/2019, 12:22:21 AM] [hieu.huynh]: :shake:
[11/15/2019, 12:43:21 AM] [thai]: Từ giờ gởi về rồi up lại chứ hết dám share
[11/15/2019, 12:51:14 AM] [__.__Sectumsempra__.__]: Share qua public channel mới có noti thì phải :think:
[11/15/2019, 5:26:40 AM] [ko luong thien]: #til <https://developer.mozilla.org/en-US/docs/Web/HTML/Element/slot> tks @quannt
[11/15/2019, 5:30:27 AM] [ko luong thien]: #til <https://github.com/ant-design/ant-design/blob/master/components/style/color/colorPalette.less>
[11/15/2019, 10:15:12 AM] [huy]: polictics? :police_car:
[11/15/2019, 10:17:56 AM] [ko luong thien]: không trời ạ
[11/15/2019, 10:18:02 AM] [ko luong thien]: care for detail thôi
[11/15/2019, 10:18:24 AM] [ko luong thien]: nhưng mà cũng có thể :vayvay:
[11/15/2019, 10:18:53 AM] [ko luong thien]: nhưng thực sự là tụi nó khác nhau :okay:
[11/15/2019, 6:01:17 PM] [dat]: nhìn hình thì thấy khác nhau mà
[11/16/2019, 1:16:01 AM] []: *taipei :thinkhard:
[11/16/2019, 2:52:42 AM] [typescriptpher]: #til Chuyện cổ tích là cái loại chuyện mà con vua luôn cưới được gái đẹp.
[11/16/2019, 3:00:42 AM] [ko luong thien]: chỗ này là “truyện” hay “chuyện” nhỉ :think:
[11/16/2019, 3:00:45 AM] [ko luong thien]: @taurandat ei
[11/16/2019, 3:15:16 AM] [dat]: *truyện
[11/16/2019, 3:23:53 AM] [typescriptpher]: đứng riêng thì là Truyện, còn ch là trong "câu chuyện"
[11/16/2019, 3:24:20 AM] [typescriptpher]: my bad, dạo này học nhiều tiếng mẫu quốc quá tẩu hoả nhập ma :roflrofl:
[11/16/2019, 3:40:56 AM] []: Cái đó thực tế cũng vậy mà, đại gia hoàng tử lúc nào mà chẳng cưới được gái đẹp :omg:
[11/16/2019, 7:17:01 PM] [n]: #til <https://adamwathan.me/css-utility-classes-and-separation-of-concerns/>
[11/16/2019, 8:21:46 PM] [Cậu Làm Vườn]: Welcome to the club :vayvay:
[11/16/2019, 9:36:14 PM] [ko luong thien]: spoiler: với utility classes anh còn có thể có statically typed styling á anh :vayvay:
[11/17/2019, 4:10:23 AM] [Cậu Làm Vườn]: Biết Thiện e thẹn nên mình sẽ làm giúp thao tác cuối là share link :vayvay:
<https://typed.tw/>
[11/17/2019, 8:13:13 AM] [ledongthuc]: :trollface: chứ nếu đứa nông dân cưới đứa nông dân thì sẽ được xếp vào truyện `hiện thực xã hội phê phán` rồi
[11/18/2019, 5:14:05 AM] [// english-ignore]: #til curtsy (n) an act of civility, respect, or reverence made mainly by women and consisting of a slight lowering of the body with bending of the knees
[11/20/2019, 12:50:07 AM] [quannt]: khac ma
[11/20/2019, 12:50:17 AM] [quannt]: traditional va simplified
[11/22/2019, 7:50:13 PM] [n]: #til Before iOS/macOS app gets crashed or force quit, the system will send the `SIGTERM` signal. We can observe it for `graceful termination`. Ex: Revert Proxy config, save data, or do critical tasks. Ref: <https://stackoverflow.com/questions/49132097/how-to-detect-force-close-on-mac-os-x-app>
[11/22/2019, 10:23:55 PM] [huy]: Does it apply for 5s power button hold?
[11/22/2019, 11:52:12 PM] [huynh.cam]: :thinkold:
[11/23/2019, 12:26:37 AM] []: <https://twitter.com/turnoff_us/status/710736561676132352/photo/1>
[11/23/2019, 6:26:34 PM] [n]: Bad news is that Matt - former Apple - elaborate that it’s extremely unsafe to handle those system signals. <https://twitter.com/mattie/status/1198424988006649857>
[11/24/2019, 7:20:46 AM] [xentence]: #til you can browse p*rnh*b or *videos by using .es domain :notbad:
[11/24/2019, 7:21:12 AM] [xentence]: or .fr , etc...
[11/24/2019, 7:25:48 AM] [xentence]: *in vietnam :grabpopcorn:
[11/26/2019, 7:07:29 PM] [tay vịn của anh bán chuối - cty A tìm FE]: #til <https://github.com/paulirish/git-open>
[11/26/2019, 7:07:38 PM] [tay vịn của anh bán chuối - cty A tìm FE]: <https://user-images.githubusercontent.com/39191/33507513-f60041ae-d6a9-11e7-985c-ab296d6a5b0f.gif>
[11/26/2019, 7:21:12 PM] [n]: `gitit` cũng ok á :smile:
[11/26/2019, 7:37:31 PM] [unrealhoang]: `hub` ngon hơn
[11/26/2019, 7:37:51 PM] [unrealhoang]: <https://hub.github.com/>
[12/4/2019, 12:25:19 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til
<https://www.cloudflare.com/learning/cdn/glossary/edge-server/>
<https://www.cloudflare.com/learning/serverless/glossary/what-is-edge-computing/>
[12/4/2019, 12:38:23 AM] [giangnh]: #til `npx prettier`
[12/6/2019, 2:35:40 AM] [Cậu Làm Vườn]: #til Module Concatenation in webpack
- What it is: an optimization enabled by webpack *by default* in production mode
- What it's for: it helps code to execute faster (by concatenate the scopes of all modules into a single closure)
- What's the cacth?: the optimization bails out in some cases, for example, with non ES6 module like `lodash`
[12/6/2019, 2:36:35 AM] [Cậu Làm Vườn]: -&gt; which means that even if you can achieve tree shaking in `lodash` with the help of babel plugin, you will still lose the benefit of this optimization -&gt; use `lodash-es` instead if you can
[12/6/2019, 2:37:12 AM] [Cậu Làm Vườn]: Details:
<https://webpack.js.org/plugins/module-concatenation-plugin/>
[12/6/2019, 2:51:58 AM] [noob]: thêm vào ý trên: cách thức concatenation của webpack, parcel và rollup
[12/8/2019, 3:14:07 AM] [// english-ignore]: #til juggernaut <https://en.wikipedia.org/wiki/Juggernaut>
[12/9/2019, 7:46:50 PM] [Nhà Quê]: <http://tamlyhoctoipham.com/dopamine-trong-tinh-yeu-va-cong-viec?fbclid=IwAR17bvzVnkQ75hlNCGazE28LIzHKu1DJK-nUsRy9WJhqGATopET-64qEhDA>
[12/11/2019, 5:38:45 AM] [// english-ignore]: #til Elvis operator `?:` :man_dancing:
[12/12/2019, 12:23:28 AM] [// english-ignore]: #til magenta isn't a real color <https://imgur.com/gallery/mnSqcju> :exploding_head:
[12/18/2019, 7:38:23 AM] [meowwwwwwwwwwwwwwww]: #til
```+new Date()```
[12/18/2019, 11:43:53 AM] [huy]: There's also a Firefox Enterprise Edition, which has a bunch of security enforcements, tracking, monitoring, key logging,... and all are controlled by corporate, which used to monitor their employees as well
[12/18/2019, 11:45:24 AM] [huy]: but once you clicked on it, you've been doomed
[12/18/2019, 11:45:36 AM] [huy]: so, yeah, fuck firefox
[12/18/2019, 11:45:55 AM] []: :omg:
[12/18/2019, 11:46:06 AM] [huy]: write your own network stack and browser, for the sake of your privacy
[12/18/2019, 11:47:42 AM] []: Nhân vụ privacy, e đã chuyển hết search engine về DuckDuckGo, ko còn ad gì nữa
[12/18/2019, 11:53:49 AM] [huy]: duckduckgo is also a scam
[12/18/2019, 11:54:08 AM] [huy]: use <http://startpage.com|startpage.com>
[12/18/2019, 12:00:51 PM] []: ^ Nó có ad a ơi
[12/18/2019, 12:28:44 PM] [huy]: ủa mà sao cái UI của e khác của a
[12/18/2019, 3:46:10 PM] [Cậu Làm Vườn]: Me, a Ublock Origin user: What is ads? :kappa:
[12/18/2019, 3:49:09 PM] [huy]: :kappa:
[12/18/2019, 6:57:45 PM] [bdragon]: sao huytd search ra đầu tiên được zị :thien:
[12/18/2019, 6:57:56 PM] [bdragon]: a search thử 2-3 keyword toàn nằm xa xa
[12/18/2019, 8:22:53 PM] [huy]: cài adblock vô e
[12/19/2019, 8:58:48 PM] []: #til There is an explain page for xkcd :oh:
<https://www.explainxkcd.com/wiki/index.php/844:_Good_Code>
[12/25/2019, 11:22:33 PM] [chua dc luong thien]: #til we can use PDF files as images in iOS apps
[12/25/2019, 11:23:21 PM] [ko luong thien]: same for mac
[12/25/2019, 11:23:28 PM] [ko luong thien]: apple done a really good job integrating things
[12/25/2019, 11:23:44 PM] [ko luong thien]: you can drag and drop a lot of things to a pdf for example, using the native Preview app
[12/25/2019, 11:28:41 PM] [chua dc luong thien]: love apple :adore:
[12/26/2019, 12:05:05 AM] [n]: thường thì mình xài pdf asset để iOS app tự nó scale cho từng device. Size nhỏ hơn, và khỏi phải add 1x, 2x, 3x, 4x ….
[12/26/2019, 12:07:31 AM] [ko luong thien]: ủa :okay: vãi nãy hiểu nhầm, tưởng đang bảo lúc xài mấy cái app..
[12/26/2019, 12:12:17 AM] [chua dc luong thien]: ah đang nói lúc dev :vayvay:
[12/26/2019, 12:12:50 AM] [chua dc luong thien]: ^^^ nếu so với svg thì sao nhỉ?
[12/26/2019, 12:16:09 AM] [n]: theo mình biết thì trong Xcode Asset nó ko support SVG. Có 2 cách để xài là
1. 3rd-party để đọc SVG và render trên UIImageView -&gt; Cách này phức tạp vì phải tính toán size
2. Custom Symbol Image bằng SVG: Apple có doc ở đây <https://developer.apple.com/documentation/xcode/creating_custom_symbol_images_for_your_app>
[12/26/2019, 12:16:26 AM] [n]: mình thì mình chọn export 1x PDF, là khỏe nhất :smile: Sketch nó có option export ra luôn
[12/26/2019, 12:16:45 AM] [chua dc luong thien]: :pepegood:
[12/26/2019, 10:15:15 PM] []: #til <https://github.com/ToxicFrog/Ligaturizer>
[12/27/2019, 1:43:25 AM] [alias Trung.Le, as tle]: TIL when to use behaviour vs protocol in Elixir
[12/27/2019, 2:09:03 AM] [Anh Ngọc]: Mình thấy:
- protocol như kiểu abstract method của abstract class
- behaviour như kiểu override abstract method :D
[12/27/2019, 8:42:17 AM] [alias Trung.Le, as tle]: TIL MapSet in Elixir
[12/28/2019, 2:07:36 AM] []: TIL in C++, A, B (string type) `A = A + B` != `A += B`
[12/30/2019, 8:20:51 AM] [dat]: #til ISO week system <https://www.youtube.com/watch?v=D3jxx8Yyw1c>
[12/30/2019, 10:51:10 AM] [ko luong thien]: #til Disjoint-set data structure :&lt;
[12/30/2019, 11:32:45 AM] [dat]: shall I say IE?
[12/30/2019, 11:33:45 AM] [dat]: tac gia cua CLRS bao thich nhat la DSU
[12/30/2019, 11:37:03 AM] [dat]: <https://www.quora.com/What-is-Professor-Thomas-Cormens-favorite-algorithm/answer/Thomas-Cormen-1|https://www.quora.com/What-is-Professor-Thomas-Cormens-favorite-algorithm/answer/Thomas-Cormen-1>
[12/30/2019, 8:23:23 PM] [ko luong thien]: not to me
[1/1/2020, 11:00:30 AM] [dangthaison91]: @nghiatran PDF để Apple scale thực ra là auto convert to PNG nên là size ảnh không được tối ưu lắm đâu.
SVG thì dùng Cyborg của Uber khá ngon.
[1/1/2020, 8:31:57 PM] [huy]: shame on you. and thank you :heart:
[1/2/2020, 2:29:05 AM] []: ```// Example program
#include &lt;iostream&gt;
#include &lt;string&gt;
int main()
{
std::string a;
std::string b;
std::string c;
a = "123";
b = "456";
c = a + b;
a += b;
if (a == c) {
std::cout &lt;&lt; "Equal";
} else {
std::cout &lt;&lt; "Not equal";
}
}```
[1/2/2020, 2:29:16 AM] []: Sao mình test thì nó ra `Equal` :thinking_face:
[1/2/2020, 2:59:04 AM] []: Dạ đúng là Equal mà, nhưng nó equal về mặt value. Cái a = a + b sẽ sinh ra 1 string mới được tạo bởi ghép 2 string a và b lại.
Cái a += b thì sẽ là concat cái string b vào sau string cũ là a
[1/2/2020, 9:47:16 AM] [ko luong thien]: #til <https://en.wikipedia.org/wiki/Ackermann_function#Inverse>
[1/2/2020, 10:55:05 PM] [ko luong thien]: #til <https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal> tks @hungton <@U0GDYMMD2>
[1/2/2020, 10:55:55 PM] [hungton]: vào MDN mình thường không đọc tiếp khi thấy cái này
&gt; *This is an experimental technology*
[1/2/2020, 10:59:37 PM] [hungton]: for better consideration
<https://caniuse.com/#feat=abortcontroller>
[1/2/2020, 11:03:14 PM] [ko luong thien]: klq cơ mà bọn nó có share data k nhỉ.. trc giờ mình tưởng MDN nó lấy source từ caniuse để hiện table đó á
[1/2/2020, 11:12:06 PM] [hungton]: <https://hacks.mozilla.org/2019/09/caniuse-and-mdn-compat-data-collaboration/>
[1/2/2020, 11:12:57 PM] [ko luong thien]: :+1:
[1/5/2020, 1:36:28 AM] [typescriptpher]: #til Watermelon project = green outside, red inside
[1/5/2020, 2:10:20 AM] [hungton]: #til <https://mathiasbynens.github.io/rel-noopener/>
[1/5/2020, 2:10:57 AM] [ko luong thien]: never too late to know this :all-the-things:
[1/5/2020, 3:39:30 AM] []: Shameless plug :shame:
<https://github.com/ng-hai/thesmallthings/blob/master/src/components/blog/mdx-components.js#L61>
[1/5/2020, 10:10:08 PM] [tay vịn của anh bán chuối - cty A tìm FE]: #til The Chicago Manual of Style <https://title.sh/>
[1/5/2020, 10:39:37 PM] [ko luong thien]: ^ <http://www.chicagomanualofstyle.org>
[1/8/2020, 5:47:35 AM] [ko luong thien]: #til <https://gitlab.gnome.org/GNOME/gnome-builder>
[1/11/2020, 5:27:47 AM] [ko luong thien]: #til <http://en.wikipedia.org/wiki/Contract_programming>
[1/15/2020, 4:55:35 AM] [ledongthuc]: #til có feature matrix nhìn dễ quá
<https://www.postgresql.org/about/featurematrix/>
[1/17/2020, 6:32:58 PM] [Cậu Làm Vườn]: #til branch prediction
<https://danluu.com/branch-prediction/>
[1/17/2020, 6:36:32 PM] [Cậu Làm Vườn]: best analogy
<https://stackoverflow.com/a/11227902>
[1/18/2020, 12:14:50 PM] [ledongthuc]: #til Platform bán nhà lớn nhất Thuỵ điển xài ROR, React và chạy trên aws
edit: <http://hemnet.se|hemnet.se>
edit 2: vài internal service đang thử viết Rust
edit 3: Đang tuyển :roflrofl: <https://jobba.hemnet.se/jobs/801020-platform-backend-developer>
[1/18/2020, 12:15:26 PM] [ko luong thien]: link anh ei
[1/18/2020, 12:16:34 PM] [ledongthuc]: ngồi nói chuyện với mấy ông dev bên đó thôi.
<http://hemnet.se|hemnet.se>
[1/18/2020, 12:24:37 PM] [ledongthuc]: :okay: btw, nhà townhouse mắc quá. Vậy mới thấy mấy người mua dc nhà bên SV người ta giàu cỡ nào
[1/18/2020, 12:28:35 PM] [ko luong thien]: true
[1/18/2020, 1:59:10 PM] [Huy]: Mua nhà ở Mỹ ko phải như VN
[1/18/2020, 1:59:18 PM] [Huy]: Cầm 1 cục tiền mặt mua 1 lần
[1/18/2020, 2:00:08 PM] [Huy]: do ở VN chưa có hệ thống tín dụng tốt thôi, chứ ở đây đa số mua nhà là trả 1/2 hoặc 1/3, phần còn lại trả dần theo tháng, có lãi. :man-shrugging::skin-tone-2:
[1/18/2020, 2:00:29 PM] [Huy]: Nhưng phải công nhận housing market ở California đang rất là fucked up
[1/18/2020, 5:34:54 PM] [Cậu Làm Vườn]: "The rent of land, therefore, considered as the price paid for the use of the land, is naturally a monopoly price. It is not at all proportioned to what the landlord may have laid out upon the improvement of the land, or to what he can afford to take; but to what the farmer can afford to give."
[1/18/2020, 10:43:37 PM] [ledongthuc]: @huyng nhưng mà cũng giàu mới mượn dc 2/3 tiền mua nhà mà. Chung cư thì không nói chứ nhà đất thì có tí hâm mộ thật :adore:
Bên ấy thường mỗi tháng phải trả lại cho bank tầm 2% không nhỉ? cc <@U0GECN1NH>
[1/18/2020, 11:53:22 PM] [// english-ignore]: Nhà đất thấy thường 2 người đi làm bụp vô là được mừ. Với kiểu ở đâu nữa, càng gần núi rừng càng rẻ :thinkhard:
[1/19/2020, 12:12:16 AM] [huy]: ở US thì tùy theo vùng mà quyết định nên mua nhà hay rent nhà, ở những vùng có mật độ dân số cao (thành phố nào có trên 1M dân chẳng hạn), thì thuê nhà lợi hơn, do market nhà thuê cũng sẽ có giá thấp hơn những vùng khác
[1/19/2020, 12:12:31 AM] [huy]: nhưng mà rent thì cũng hét 50% lương vô tiền thuê nhà rồi
[1/19/2020, 12:12:47 AM] [huy]: mua nhà thì cũng tốn tầm đó nếu mà vay ngân hàng 30 năm
[1/19/2020, 12:12:53 AM] [huy]: có tiền thì mua cho khỏe
[1/19/2020, 12:13:38 AM] [huy]: với theo ý kiến chuyên gia thì
[1/19/2020, 12:13:53 AM] [huy]: ai muốn mua nhà, cứ đợi recession tới là mua đc ngay
[1/19/2020, 12:14:03 AM] [huy]: nghe cứ như khái niệm reset trong MU :notbad:
[1/19/2020, 12:19:00 AM] [// english-ignore]: Mình thì không muốn mua nhà vì cứ có cảm giác chôn chân tại chỗ :okay:
[1/19/2020, 12:25:55 AM] [huy]: thực ra cái trói chân một người tại một chỗ là cái cty đang làm chứ ko phải cái nhà đang ở :doubt:
[1/19/2020, 12:26:18 AM] [huy]: còn nhà thì cứ đi mỗi thành phố mua 1 cái nhà là đc mà
[1/19/2020, 12:33:19 AM] [ledongthuc]: :notbad:
[1/19/2020, 12:34:10 AM] [ledongthuc]: @kcj.pop.com_rbvn tự mỗi người mua 1 căn chứ 2 đứa 1 căn sau này sao dám ly hôn
[1/19/2020, 12:35:09 AM] [// english-ignore]: :notbad:
[1/19/2020, 12:35:19 AM] [// english-ignore]: ^ cho cả 2 comments của 2 mẹ
[1/19/2020, 12:36:17 AM] [huy]: tư bản việt cộng nói chuyện máu lửa quá :disappointed:
[1/19/2020, 12:41:41 AM] [ko luong thien]: (siliently watch from thiên đường)
[1/19/2020, 7:36:30 AM] [Huy]: Tầm @thien ở VN chỉ có mua đứt chứ cần gì mua nợ
[1/20/2020, 6:16:48 AM] [ledongthuc]: #til trashion
<https://www.urbandictionary.com/define.php?term=trashion>
[1/21/2020, 5:27:16 AM] [n]: #til URL has Double slashes (//) is *valid* :shake:
```Ex: <https://foobar.vault.azure.net//secrets?api-version=7.0>```
[1/21/2020, 6:40:54 AM] [ko luong thien]: nice one anh :))
[1/22/2020, 8:37:13 PM] [ko luong thien]: #til `expand` :okay:
[1/22/2020, 8:46:31 PM] [ko luong thien]: #til flatpak sucks :arggg: snap sucks :arggg: gui for package management is far from good :arggg:
[1/22/2020, 11:48:37 PM] [noob]: :question:
[1/23/2020, 2:55:02 AM] [hungton]: ?
[1/23/2020, 5:36:08 AM] [ko luong thien]: <https://bugs.launchpad.net/ubuntu/+source/snapd/+bug/1585332>
[1/23/2020, 5:37:47 AM] [noob]: sao bữa giờ đụng mấy cái đó thế
[1/23/2020, 5:43:32 AM] [ko luong thien]: code app gtk kiếm tiền ăn tết
[1/23/2020, 5:43:52 AM] [hungton]: &gt; Confined graphical GTK &amp; Qt applications do not use the user-selected or default theme of the end-user desktop outside Ubuntu
được Ubuntu support là vui rồi, sống sao cho vừa ý với độ phân mãnh distro của linux
<https://www.reddit.com/r/linux/comments/a4xl2j/linus_torvalds_fragmentation_is_why_desktop_linux/>
[1/23/2020, 5:44:40 AM] [hungton]: kiếm job làm app gtk đâu thế, share dc ko Thiện
[1/23/2020, 5:46:23 AM] [ko luong thien]: à k phải là job :)) mình với bạn mình làm thôi :))
[1/23/2020, 5:46:55 AM] [noob]: :notbad:
[1/23/2020, 5:55:14 AM] [hungton]: giờ viết native app sao ko viết react hen ^^
[1/23/2020, 6:37:18 AM] [ko luong thien]: cross platform is a myth :v
[1/24/2020, 12:13:04 AM] [n]: #til in case you would to implement a standalone HTTP/2 parser. NIOHTTP2 from Apple is the best reference:
• Full HTTP/2.0 data frame parser
• Support HPACK
Ref: <https://github.com/apple/swift-nio-http2/tree/master/Sources/NIOHTTP2>
[1/24/2020, 12:15:12 AM] [ledongthuc]: @thien swing
[1/24/2020, 12:15:28 AM] [ledongthuc]: it's real. chỉ là nhìn nó xấu không tả nổi
[1/24/2020, 12:15:56 AM] [n]: User-case:
• HTTP/HTTPS Server for macOS &amp; iOS
[1/24/2020, 12:20:02 AM] [n]: Fun fact: Proxyman hasn’t supported HTTP/2 yet 🥺 (Only support HTTP/1.x)
[1/28/2020, 12:52:08 AM] [Anh Ngọc]: TIL: Elixir không có event delegate như C# nhưng có thể dùng Registry để dispatch event tới các GenServer.
[1/28/2020, 5:54:26 PM] [stronglong]: #til SAML is dead-ing
[1/29/2020, 2:33:02 PM] [huy]: #til Tác giả của Vim đang làm việc cho Google [1], team Google Calendar.
[1]: <https://usesthis.com/interviews/bram.moolenaar/>
[1/31/2020, 4:24:05 AM] [thuanpt]: có nét giống Elon Musk
[2/3/2020, 9:15:03 PM] [ko luong thien]: #til <https://we-build-vn.slack.com/archives/C0GUMNSH0/p1580786205034000>
[2/4/2020, 7:42:06 AM] [calemolech]: trang này nhiều bài vãi
[2/6/2020, 1:20:01 AM] [tay vịn của anh bán chuối - cty A tìm FE]: <https://twitter.com/destroytoday/status/1224913758721658880?s=21|https://twitter.com/destroytoday/status/1224913758721658880?s=21>
[2/6/2020, 1:44:00 AM] [ben]: Giữ alt hoặc shift cũng có tác dụng khác
[2/6/2020, 1:49:11 PM] [Huy]: giữ option nữa
[2/8/2020, 4:34:41 AM] [ko luong thien]: #til <https://www.cs.rit.edu/~ats/books/ooc.pdf>
[2/8/2020, 4:37:47 AM] [Cậu Làm Vườn]: ^ til không có tâm :arggg:
[2/8/2020, 4:39:26 AM] [minh]: Thearddddddd :arggg:
[2/8/2020, 4:41:32 AM] [ko luong thien]: PDF free mà k có tâm gì :okay:
[2/8/2020, 4:41:50 AM] [ko luong thien]: đại khái nó là how to oop in C (ANSI)
[2/8/2020, 4:42:07 AM] [ko luong thien]: ví dụ như GTK
[2/8/2020, 4:42:32 AM] [ko luong thien]: OOP is (arguably) inevitable for UI kit
[2/8/2020, 4:42:39 AM] [ko luong thien]: but GTK needs to be written in C
[2/8/2020, 4:42:41 AM] [ko luong thien]: so here we go
[2/8/2020, 9:06:13 AM] [ko luong thien]: #til the way to implement multiple cursors is to repeatitively swapping the real and the fake one(s) and replicate all actions :arggg:
[2/8/2020, 9:11:59 AM] [huy]: it depends on an editor dude
[2/8/2020, 9:12:16 AM] [huy]: sublime has native multiple cursor. so does intelliJ
[2/8/2020, 9:15:44 AM] [ko luong thien]: sorry quên, ref là gnome builder =))
[2/8/2020, 9:15:56 AM] [ko luong thien]: ủa mà “native” là sao anh?
[2/8/2020, 9:16:07 AM] [ko luong thien]: ví dụ không phải “native” là như thế nào?
[2/8/2020, 9:16:26 AM] [ko luong thien]: như cái gnome builder với vscode là không native, còn sublime là native vì nó tự draw cái text editting?
[2/8/2020, 9:19:40 AM] [huy]: là cách mà e implement cái text buffer, cách e render cái editor ra á
[2/8/2020, 9:19:53 AM] [huy]: xài gnome / gtk thì đúng rồi
[2/8/2020, 9:20:05 AM] [huy]: do mấy cái đó nó chỉ build cho single cursor case
[2/8/2020, 10:15:08 AM] [ko luong thien]: Hiểu zồi, còn kiểu sublime là nó tự implement cái text buffer
[2/8/2020, 10:38:58 AM] [huy]: uhm
[2/8/2020, 10:39:16 AM] [huy]: thực tế ra thì ko ai build editor mà dùng built-in textarea component cả
[2/8/2020, 10:39:35 AM] [huy]: nó giống như kiểu e build một cái browser mới mà lại đi dùng cái webview của OS vậy đó
[2/8/2020, 11:45:40 AM] [// english-ignore]: #til <https://en.wikipedia.org/wiki/The_Unknown_Warrior>
[2/8/2020, 7:13:00 PM] [dat]: ^ #til
[2/9/2020, 4:48:03 AM] [ledongthuc]: #til <https://whatwebcando.today/wake-lock.html>
wake lock cho phép web có thể lock screen/system để ko thể nó dim/sleep
[2/10/2020, 12:31:45 AM] []: iOS không làm được :arggg:
[2/10/2020, 12:32:11 AM] [minh]: Không có iOS để test :okay:
[2/11/2020, 2:02:06 AM] [ledongthuc]: #til FAKE
Bói chỉ tay là 1 ngành khoa học lâu đời, có nền tảng dựa trên thống kê và quan sát tập mẫu trong khoảng thời gian dài?
Chỉ là do tập mẫu không đủ lớn, thời gian quan sát không đủ lâu, bị bias hoặc trục lợi bởi người coi chỉ tay nên bị cho là mê tín dị đoan.
[2/11/2020, 2:02:48 AM] [// english-ignore]: Vậy nếu tập mẫu lớn thì có khả năng nó đúng?
[2/11/2020, 2:03:15 AM] [ledongthuc]: :notbad: chẳng biết nữa, nãy mới bị ~bà kia~ người kia dụ coi chỉ tay =))))
[2/11/2020, 2:03:46 AM] [// english-ignore]: Bà lào, để méc vợ cho
[2/11/2020, 2:04:03 AM] [ledongthuc]: :kappa:
[2/11/2020, 2:10:33 AM] []: Sai nhé, cái này chỉ gọi là pseudo science thôi, vì không có lý thuyết để giải thích các kết quả mà bói chỉ tay đưa ra, đơn thuần là tìm mối liên hệ giữa những sự vật không liên quan.
Cái này tương tự như bảo là do bướm vỗ cánh ở Arizona nên có bão ở SF.
[2/11/2020, 2:11:41 AM] [// english-ignore]: Nghe nói vỗ ở Amazon mới ra bão ở SF được
[2/11/2020, 2:15:53 AM] [ledongthuc]: :sosad: uhm, nên mới bảo Fake mà, người dụ bói bảo thế đấy
[2/11/2020, 2:43:34 AM] [typescriptpher]: bữa thấy có bro còn share cuốn sách coi bói qua hình dáng của b@@b
[2/11/2020, 2:57:36 AM] []: ^ cái trên là khoa học nha :vayvay:
[2/11/2020, 5:08:03 AM] [unrealhoang]: @eyeball khoa học nha :vayvay:
[2/11/2020, 5:25:40 AM] [typescriptpher]: Hay mềnh học thêm một bằng phd về ngành này nhỉ :vayvay:
[2/11/2020, 5:29:18 AM] [typescriptpher]: @hieuk09 vụ hiệu ứng cánh bướm thì đơn giản là pure math thoai, đó là cách nói văn vẻ của input ban đầu có thể khác nhau rất nhỏ, nhưng kết quả cuối có thể khác nhau rất lớn
[2/11/2020, 5:30:29 AM] [typescriptpher]: đặc biệt là trong mấy hệ thống dự báo thời tiết
[2/11/2020, 5:31:33 AM] [typescriptpher]: một ví dụ có thể làm thực nghiệm luôn là con lắc ấy, để vị trí ban đầu khác nhau xíu, sau một thời gian là lệch hẳn luôn
[2/11/2020, 5:41:26 PM] [unrealhoang]: Con lắc đôi là nhìn rõ nhất
[2/11/2020, 5:42:06 PM] [unrealhoang]: Tuy là deterministic nhưng vẫn rất chaos
[2/11/2020, 7:08:09 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: vừa đọc bên kia có 1 bài về sinh trắc vân tay là bịp :think:
[2/12/2020, 1:43:06 AM] [minh.nguyen]: #til Một con ngựa sản sinh ra 14.9 mã lực <https://www.carkeys.co.uk/guides/does-one-horsepower-really-equal-the-power-of-one-horse|https://www.carkeys.co.uk/guides/does-one-horsepower-really-equal-the-power-of-one-horse>
[2/12/2020, 2:16:56 AM] [huynh.cam]: mua 1 con ngựa về kéo dc 7 cái máy lạnh 2 ngựa :notbad:
[2/12/2020, 7:40:57 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til global.gc()
<https://twitter.com/nikgraf/status/1227549174935293953?s=21|https://twitter.com/nikgraf/status/1227549174935293953?s=21>
[2/12/2020, 6:43:18 PM] [n]: #til good read <https://we-build-vn.slack.com/archives/C32HMMUAW/p1581543006044000>
[2/12/2020, 10:30:51 PM] [typescriptpher]: #til D3 = Data-driven document
[2/13/2020, 9:47:07 AM] [ptgamr]: #til (6×9)+(6+9)=69
[2/13/2020, 9:49:10 AM] []: #til (X*9) + (X+9) = X9
[2/13/2020, 10:06:43 AM] [tay vịn của anh bán chuối - cty A tìm FE]: =10X+9
[2/13/2020, 6:41:25 PM] []: @anh.trinhtrung obsessed about 69? :trollface:
[2/13/2020, 10:56:40 PM] [typescriptpher]: #til _*Saudade*_ is a deep emotional state of nostalgic or profound melancholic longing for an absent something or someone that one cares for and/or loves.
<https://en.wikipedia.org/wiki/Saudade>
[2/13/2020, 11:27:51 PM] [huy]: are you describing yourself @eyeball
[2/13/2020, 11:28:25 PM] [typescriptpher]: A sad story
[2/13/2020, 11:36:22 PM] [ko luong thien]: #til micro task in js tks to @nhducit
[2/13/2020, 11:37:39 PM] [ko luong thien]: <https://developer.mozilla.org/en-US/docs/Web/API/HTML_DOM_API/Microtask_guide>
[2/13/2020, 11:38:41 PM] [Cậu Làm Vườn]: Cái này nói quài mà nhỉ :thinkhard:
[2/13/2020, 11:39:06 PM] [Cậu Làm Vườn]: Trong #javascript có cả tr lần nói mấy cái liên quan
[2/13/2020, 11:40:07 PM] [Cậu Làm Vườn]: Ồ, cái này #til thiệt nè
&gt; JavaScript promises and the Mutation Observer API both use the microtask queue to run their callbacks
[2/13/2020, 11:40:07 PM] [ko luong thien]: ủa vậy hả :neutral_face:
[2/13/2020, 11:40:17 PM] [ko luong thien]: i’m new here
[2/13/2020, 11:40:29 PM] [Cậu Làm Vườn]: Mấy cái quiz liên quan tới execution order đó
[2/13/2020, 11:43:06 PM] [// english-ignore]: Biết để làm gì :why:
[2/13/2020, 11:44:14 PM] [ko luong thien]: ờ, @snacky cũng có biết đâu mà vẫn mua nhà mẽo được kìa
[2/13/2020, 11:44:29 PM] [// english-ignore]: :point_up: that's the point
[2/13/2020, 11:45:36 PM] [ko luong thien]: chỗ này sáng sủa hơn nè @snacky
[2/13/2020, 11:45:47 PM] [ko luong thien]: cái thread bên #frontend giờ nó lên tới tầm nào cao lắm rồi :okay:
[2/13/2020, 11:46:56 PM] [huy]: đm đừng tag tui vào nữa
[2/13/2020, 11:47:04 PM] [huy]: tui lạy các anh
[2/13/2020, 11:47:06 PM] [huy]: :notlikethis:
[2/13/2020, 11:47:08 PM] [huy]: :monday:
[2/13/2020, 11:47:31 PM] [ko luong thien]: này thì 3h sáng đi hỏi tech :roflrofl:
[2/14/2020, 6:17:56 AM] [dong]: #til If You Learn to Write, You Can Change Your Life.
<https://medium.com/swlh/if-you-learn-to-write-you-can-change-your-life-d0df747e02c8>
[2/18/2020, 9:14:30 PM] [ledongthuc]: #til group mình có <#C0GH8781K|jobs>
[2/18/2020, 9:14:54 PM] [xuan]: really man :rolling_on_the_floor_laughing:
[2/20/2020, 7:44:16 PM] [stronglong]: #til ctrl+tab in Chrome :facepalm:
<https://chrome.google.com/webstore/detail/clut-cycle-last-used-tabs/cobieddmkhhnbeldhncnfcgcaccmehgn/related>
[2/20/2020, 11:06:21 PM] [meowwwwwwwwwwwwwwww]: #til /etc/protocols
[2/21/2020, 5:59:22 AM] [Cậu Làm Vườn]: #til dark kitchen
[2/21/2020, 5:59:57 AM] [Cậu Làm Vườn]: <https://www.deliverect.com/blog/dark-kitchens/what-is-a-dark-kitchen>
[2/21/2020, 6:26:23 PM] [n]: #til Zero effort to detect race-condition by enabling *Thread Sanitizer* in Xcode <https://developer.apple.com/documentation/code_diagnostics/thread_sanitizer?language=objc>
Fix được mấy crash lâu năm của Proxyman :white_check_mark:
[2/22/2020, 1:39:51 PM] [huy]: #til Stable vs Unstable sort. <https://javarevisited.blogspot.com/2017/06/difference-between-stable-and-unstable-algorithm.html?m=1>
Thanks @khoiracle
[2/22/2020, 5:27:07 PM] [tay vịn của anh bán chuối - cty A tìm FE]: .sort của js dạo này cũng stable ròi
[2/22/2020, 9:16:32 PM] [huy]: cái này làm sao xem ở đâu thím
[2/22/2020, 9:19:47 PM] [huy]: <https://github.com/v8/v8/blob/78f2610345fdd14ca401d920c140f8f461b631d1/third_party/v8/builtins/array-sort.tq#L5|https://github.com/v8/v8/blob/78f2610345fdd14ca401d920c140f8f461b631d1/third_party/v8/builtins/array-sort.tq#L5>
[2/22/2020, 9:19:52 PM] [huy]: timsort luôn
[2/22/2020, 9:27:53 PM] [dong]: Cứ quicksort mà đánh tới, cùng lắm thì heap sort nó mà rơi vào worse case thì đó là ý trời. :troll:
[2/22/2020, 9:32:55 PM] []: shameless plug <https://www.khoi.io/post/sorting-algorithm-visualizations/>
[2/22/2020, 9:46:05 PM] [huy]: me too me too <https://github.com/huytd/bubble-sort-visualized>
[2/22/2020, 10:35:53 PM] [tay vịn của anh bán chuối - cty A tìm FE]: @snacky nhớ ko lầm là có spec thì phải
[2/22/2020, 10:36:31 PM] [tay vịn của anh bán chuối - cty A tìm FE]: Hoặc là mấy browser vendors đồng ý implement stable sort chứ hồi trước spec ko đề cập
[2/23/2020, 8:42:07 AM] []: #til nihilism
&gt; the rejection of all religious and moral principles, in the belief that life is meaningless.
<https://en.wikipedia.org/wiki/Nihilism>
[2/23/2020, 6:49:18 PM] [n]: Quora: maybe it’s related <https://qr.ae/Tj6rzO>
[2/23/2020, 9:11:12 PM] []: famous nihilists:
• Thanos
• BoJack Horseman
• Rick Sanchez
[2/23/2020, 9:19:10 PM] [ZeroX]: more famous nihilists:
• me :rolling_on_the_floor_laughing:
[2/23/2020, 9:25:03 PM] []: more ~famous~ nihilists:
• me
[2/24/2020, 10:05:43 AM] [minh]: #til LATCH method
<https://parsonsdesign4.wordpress.com/resources/latch-methods-of-organization/>
[2/24/2020, 10:36:33 PM] [huy]: #til Slack hiển thị đc cả monospace font mà không cần codeblock
[2/25/2020, 11:36:30 PM] [ko luong thien]: #til Jira is free for small teams (&lt;10) thanks @huyle <https://www.atlassian.com/software/free>
[2/25/2020, 11:36:51 PM] [ko luong thien]: the problem with Google is that there is no task management app for team
[2/25/2020, 11:36:59 PM] [unrealhoang]: but why?
[2/25/2020, 11:37:05 PM] [ko luong thien]: the problem with Atlassian is that confluence is too far from Google Docs
[2/25/2020, 11:37:14 PM] [ko luong thien]: ~@unrealhoang anh <@U0YCYDCTC> thuê em post~
đùa chứ em đang đi tìm, thì cái project management của jira ổn mà
[2/25/2020, 11:37:55 PM] [unrealhoang]: small team thấy xài github ngon mà
[2/25/2020, 11:38:03 PM] []: yup, github project nhe
[2/25/2020, 11:38:07 PM] [huyle]: 1 phút quản cáo Jira có Mac app native nha :smile:
[2/25/2020, 11:38:26 PM] [ko luong thien]: hm cũng hợp lí, github project may be good enough..
[2/25/2020, 11:38:41 PM] [ko luong thien]: chắc github + google docs :disappointed: sorry @huyle I tried
[2/25/2020, 11:38:53 PM] [unrealhoang]: google docs for what?
[2/25/2020, 11:39:04 PM] [ko luong thien]: non-tech documents
[2/25/2020, 11:39:14 PM] [unrealhoang]: project + wiki
[2/25/2020, 11:39:18 PM] [ko luong thien]: kiểu timesheet, review candidates, reports
[2/25/2020, 11:39:20 PM] [unrealhoang]: best combo
[2/25/2020, 11:39:34 PM] [ko luong thien]: github k có quản lý hiring được @unrealhoang :-1:
[2/25/2020, 11:39:57 PM] []: Google là phải rồi, nó có calendar
[2/25/2020, 11:40:09 PM] []: nhưng mà Google này nói chung chứ đâu phải docs không đâu :v
[2/25/2020, 11:40:13 PM] [n]: notion?
[2/25/2020, 11:40:24 PM] [n]: toggl toàn xài notion, tất tầng tật, support đủ
[2/25/2020, 11:40:26 PM] [ko luong thien]: ừa đúng rồi, còn calendar nữa, book lịch với candidates các thứ
[2/25/2020, 11:40:41 PM] [unrealhoang]: gsuite thì chắc khó kiếm replace
[2/25/2020, 11:41:02 PM] [ko luong thien]: @nghiatran em đang thử notion để manage hiring thì sếp em mua gsuite nên em qua xài google sheets :okay:
[2/25/2020, 11:41:10 PM] []: gsuite mắc vãi luôn :sosad: đang cắn răng trả mỗi tháng chỉ để đổi lấy mail service
[2/25/2020, 11:41:32 PM] [dat]: ^ me 2
[2/25/2020, 11:41:34 PM] [dat]: :'(
[2/25/2020, 11:41:46 PM] [dat]: k dung gsuite ma gui mail de vao spam
[2/25/2020, 11:41:59 PM] [unrealhoang]: trả tiền để đưa information cho google
[2/25/2020, 11:42:04 PM] [unrealhoang]: :cry:
[2/25/2020, 11:42:26 PM] [hieu.huynh]: xài JIRA chắc ok nhất rồi, team nhỏ thì free, team lớn thì cũng scale lên dễ, ai cũng biết xài, ticket custom dc nhiều field với build dc complex flow, sau này team đông ra thì rất flexible
[2/25/2020, 11:43:06 PM] [hieu.huynh]: confluence dạo này cũng đỡ dởm hơn trước, nên để xài dc thì dc, chứ nói ngon như mấy thằng khác chắc còn xa lắm
[2/25/2020, 11:43:13 PM] [ko luong thien]: ừa, 1 trong những cái selling point của jira là nó phục vụ được nhiều size :shake: _lỡ không may_ mốt team bự gấp 10 thì cái behaviour cũng đỡ thay đổi
[2/25/2020, 11:43:29 PM] [hieu.huynh]: ^ đúng rồi đó
[2/25/2020, 11:43:38 PM] [ledongthuc]: JIRA ổn mà. Đứng từ mặt quản lý xài JIRA nắm dc nhiều thông tin + query dễ lắm.
Confluence cũng ok (mặc dù lâu lâu vẫn có bug ở cái editor)
[2/25/2020, 11:44:08 PM] [ledongthuc]: chưa thấy tool nào làm query, report và custom dasboard dễ như JIRA
[2/25/2020, 11:44:17 PM] [ko luong thien]: true though
[2/25/2020, 11:44:36 PM] [unrealhoang]: thích nào chọn nấy thôi chứ cty ở Nhật cả ngàn người vẫn quản lý bằng excel tốt nha
[2/25/2020, 11:44:37 PM] [unrealhoang]: :vayvay:
[2/25/2020, 11:44:51 PM] [ko luong thien]: :shake: thật à
[2/25/2020, 11:44:53 PM] [hieu.huynh]: cái query của jira cực mạnh, mình có cái flow nho nhỏ là đánh label cho ticket, xong tự update vào trong confluence, cuối tháng dô đó xem là biết dc ticket dc group như nào, etc..
[2/25/2020, 11:45:13 PM] [ko luong thien]: hồi em ở cty F cũng quản lý bằng cái excel cơ mà nó hơi chaos
[2/25/2020, 11:46:10 PM] [unrealhoang]: excel làm computer vision còn được, xá gì mấy cái CRUD system :roflrofl:
<https://github.com/amzn/computer-vision-basics-in-microsoft-excel>
[2/25/2020, 11:46:54 PM] [ledongthuc]: Excel cũng tốt nha :pepegood:
Chỉ là hơi lười tự viết macro để làm notification, report với automation flow thôi
[2/25/2020, 11:47:11 PM] [ledongthuc]: chứ excel cũng là dạng custom cực mạnh, cỡ nào cũng chơi dc hết :))))
[2/25/2020, 11:47:22 PM] [hieu.huynh]: dĩ nhiên là dc, nhưng chả nhẽ phải tốn cả tháng để build 1 cái excel để quản lý task :why: thời gian đâu ngồi cót mấy cha
[2/25/2020, 11:47:48 PM] [unrealhoang]: wut
[2/25/2020, 11:47:55 PM] [unrealhoang]: excel là trùm agile nha
[2/25/2020, 11:48:02 PM] [unrealhoang]: cần tới đâu làm tới đó
[2/25/2020, 11:48:25 PM] [ledongthuc]: :shake: confirm là 1 số phần của bloomberg vẫn đang quản lý trade order bằng excel ấy.
Các bạn nghĩ các bạn trade thì đằng sau automation hết à, :vayvay:
[2/25/2020, 11:48:35 PM] [ledongthuc]: excel ftw
[2/25/2020, 11:48:44 PM] [ledongthuc]: nhưng mà thôi, JIRA dc rồi :okay:
[2/25/2020, 11:48:44 PM] [unrealhoang]: true, excel ftw
[2/25/2020, 11:49:04 PM] [unrealhoang]: ngày xưa mình thấy access còn hay ho hơn nữa, mà sao nó không catch up nhỉ :thinkmid:
[2/25/2020, 11:51:12 PM] [minh.nguyen]: Excel thì share thế nào nhỉ?
[2/25/2020, 11:53:18 PM] [ko luong thien]: thì bỏ vào usb, mỗi sáng chuyền tay nhau report vào đấy
[2/25/2020, 11:53:40 PM] [ledongthuc]: =))) hình như nó có cái workbook để share ấy.
Có phân quyền + password các kiểu nữa
[2/25/2020, 11:54:02 PM] [ledongthuc]: còn trước khi có chức năng đó thì chắc sáng sáng chia nhau ra rồi chép USB như Thiện thật
[2/25/2020, 11:54:10 PM] []: share bằng cloud service của Office luôn nhe
[2/25/2020, 11:55:13 PM] [ko luong thien]: đù em nói giỡn mà @ledongthuc =))
[2/25/2020, 11:55:15 PM] []: ủa mà sao không up lên Google Docs luôn, Google Docs có support file Excel
[2/25/2020, 11:55:22 PM] [ko luong thien]: hồi đó bên em là có 1 thanh niên đi hỏi rồi cập nhật vào
[2/25/2020, 11:55:28 PM] [ko luong thien]: kind of like “thư ký”
[2/25/2020, 11:55:38 PM] [ko luong thien]: @nguyenhuedang it’s 2010
[2/25/2020, 11:56:31 PM] [ledongthuc]: mấy bạn làm chuyên excel bảo Sheet ko đủ feature như excel, ko powerful như excel.
Còn thiếu gì thì mình ứ biết =)))))
[2/25/2020, 11:57:00 PM] [ko luong thien]: em biết thiếu gì nè
[2/25/2020, 11:57:20 PM] [ko luong thien]: thiếu Visual Basic for Applications =))
[2/25/2020, 11:57:25 PM] [ledongthuc]: =))))
[2/25/2020, 11:57:27 PM] [ledongthuc]: có thể
[2/25/2020, 11:57:49 PM] [ledongthuc]: @thien anh nghĩ thời office 97 share usb hay đĩa mềm thật mà, chứ thời đó mạng mẽo đâu tốt dc như giờ đâu mà live editing
[2/26/2020, 12:01:01 AM] [ko luong thien]: em nghĩ lúc đó sẽ có role phụ trách chuyên môn.. như kiểu bạn thư ký bên cty F hồi đó của em á
[2/26/2020, 12:01:10 AM] [ko luong thien]: cứ đi ping rồi update vào sheet rồi gửi lên sếp
[2/26/2020, 12:01:24 AM] [ko luong thien]: xong sếp comment xong gửi lại cho mỗi người
[2/26/2020, 12:01:24 AM] [hieu.huynh]: hình như thành #random cmnr :doubt:
[2/26/2020, 12:01:36 AM] [hieu.huynh]: thôi để em chạy cuốc xe đã, tối nói tiếp
[2/26/2020, 12:01:55 AM] [ledongthuc]: uhm :))) giống hồi xưa anh làm đề án bên trường. Mỗi đứa code 1 khúc. Cuối ngày chừa ra 1 tiếng ngồi copy code lại rồi chia ra làm tiếp ấy.
[2/26/2020, 12:02:51 AM] [unrealhoang]: _v1.java
[2/26/2020, 12:03:01 AM] [unrealhoang]: _v1-2.java
[2/26/2020, 12:03:05 AM] [unrealhoang]: :roflrofl:
[2/26/2020, 12:04:19 AM] []: hồi trước em thì tập tành dùng SVN, xong rồi không biết xài nên hai đứa phải copy hai cái folders khác nhau vô merge tay
[2/26/2020, 1:00:19 AM] [hasagi]: no offense chứ mình cảm giác JIRA hơi slow slow sao í
[2/26/2020, 1:00:21 AM] [hasagi]: chắc bias
[2/26/2020, 1:00:57 AM] [unrealhoang]: same experience for me :thinkcry:
[2/26/2020, 1:01:17 AM] [unrealhoang]: mở vài tab jira là máy kêu ầm ầm
[2/26/2020, 1:04:43 AM] [ledongthuc]: same for me :slightly_smiling_face:
confluence cũng y chang. Nếu có 1 page tầm 30 cái comments + replies thì load lâu + render giật giật luôn
[2/26/2020, 4:41:03 AM] [ledongthuc]: #til <https://splice.com>
[2/26/2020, 6:11:16 AM] []: Jira is painfully slow in my personal experiences
[2/26/2020, 6:11:37 AM] []: <https://linear.app/> my team has been using this for the past weeks and can’t be happier
[2/26/2020, 6:12:34 AM] [ko luong thien]: thanks @khoiracle that's a new one to me
[2/26/2020, 6:31:25 PM] [ko luong thien]: #til <https://en.wikipedia.org/wiki/Box-drawing_character> cc @iamquang95
[2/26/2020, 9:11:55 PM] [huyle]: @khoiracle it is requesting for early access, haven’t started yet :disappointed:
[2/26/2020, 9:12:35 PM] [minh.nguyen]: #til Old, but gold <https://people.mpi-inf.mpg.de/~jblanche/api-design.pdf>
[2/26/2020, 9:12:36 PM] [ko luong thien]: @khoiracle is is possible for those who have access to invite others?
[2/26/2020, 9:12:43 PM] [minh.nguyen]: Qt nè @thien
[2/26/2020, 9:15:19 PM] [ko luong thien]: yub :adore:
[2/26/2020, 9:15:33 PM] [ko luong thien]: the web needs a ui kit that is properly designed like this
[2/26/2020, 9:15:49 PM] [ko luong thien]: fund nè sếp: <https://github.com/dvkndn/extd>
[2/26/2020, 9:17:47 PM] [ko luong thien]: cái contributing viết đàng hoàng lắm á
[2/26/2020, 9:17:51 PM] [minh.nguyen]: Demo cũng không work. Xin fund kiểu này hèn gì tạch
[2/26/2020, 9:18:16 PM] [ko luong thien]: cái này chưa bắt đầu mà :sosad:
[2/26/2020, 9:18:19 PM] [ko luong thien]: em xin lỗi anh
[2/26/2020, 9:18:21 PM] [ko luong thien]: để em đi code
[2/26/2020, 9:18:21 PM] [ko luong thien]: huhu
[2/26/2020, 9:40:26 PM] []: oops, sorry guys, didn’t know they’re in private beta :disappointed: I’d say fill out the wait list so you get notified when it’s public
[2/26/2020, 9:53:02 PM] []: anyone tried Basecamp? is it any good?
[2/26/2020, 10:03:51 PM] [huyle]: I don’t like DHH :smile:
[2/26/2020, 10:04:00 PM] [huyle]: Try Trello :wink:
[2/29/2020, 3:56:35 AM] [Tu Huynh]: #til IE 11 auto caching from GET XHR :( dumb IE <https://stackoverflow.com/questions/54567654/ie-11-issue-automatically-cache-responses-from-get-requests-reactjs|https://stackoverflow.com/questions/54567654/ie-11-issue-automatically-cache-responses-from-get-requests-reactjs>
[3/1/2020, 8:13:24 PM] [ko luong thien]: hình như nó có support regex nữa á iem
[3/1/2020, 8:23:02 PM] [usbc]: em block request voi filter no lai roi a oi, a` ma no co reg <https://developers.google.com/web/tools/chrome-devtools/network>
[3/2/2020, 12:37:54 AM] [usbc]: filter devtool with regex: <https://stackoverflow.com/questions/38524801/chrome-dev-tool-any-way-to-exclude-each-call-containing-a-string-with-regex>
[3/2/2020, 8:32:49 PM] []: #til Make `nvm` respect `.nvmrc` file
<https://github.com/nvm-sh/nvm#zsh>
[3/3/2020, 1:53:54 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: why not `direnv`?
<https://github.com/direnv/direnv/wiki/Node>
[3/3/2020, 1:59:11 AM] []: Cái này lạ, em mới dùng zsh cơ bản à :thinkhard:
[3/3/2020, 6:22:08 AM] [chua dc luong thien]: #til the longest word in English is *antidisestablishmentarianism*
[3/3/2020, 6:30:30 AM] [ledongthuc]: _Spårvagnsaktiebolagsskensmutsskjutarefackföreningspersonalbeklädnadsmagasinsförrådsförvaltarens_
[3/3/2020, 6:38:15 AM] [chua dc luong thien]: :shake:
[3/3/2020, 6:41:26 AM] [// english-ignore]: Pseudopseudohypoparathyroidism?
[3/3/2020, 7:25:13 PM] [hieu.huynh]: #til <https://news.ycombinator.com/item?id=22473209>
&gt; The fact that you cannot write everything down forces you to think about what you are hearing and find the important part to write down
[3/4/2020, 12:51:31 AM] [giangth]: #til inline-block có space giữa các element
<https://css-tricks.com/fighting-the-space-between-inline-block-elements/>
[3/4/2020, 2:06:05 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til `.gitkeep`
<https://stackoverflow.com/questions/7229885/what-are-the-differences-between-gitignore-and-gitkeep>
[3/4/2020, 3:52:44 AM] [// english-ignore]: Cạm thậy `.gitignore` dễ hiểu hơn :think: vì `.gitkeep` không có trong documentation
[3/4/2020, 4:59:45 AM] [// english-ignore]: Do they?
[3/4/2020, 5:20:40 AM] [tay vịn của anh bán chuối - cty A tìm FE]: Không đọc ah @kcj.pop.com_rbvn
[3/4/2020, 5:20:49 AM] [tay vịn của anh bán chuối - cty A tìm FE]: :nono:
[3/4/2020, 6:07:04 AM] [// english-ignore]: Đọc gì nào
[3/4/2020, 6:10:30 AM] [tay vịn của anh bán chuối - cty A tìm FE]: ```Git cannot add a completely empty directory. People who want to track empty directories in Git have created the convention of putting files called .gitkeep in these directories. The file could be called anything; Git assigns no special significance to this name.```
[3/4/2020, 6:14:43 AM] [// english-ignore]: Um ý là cùng cái idea đó, xài `.gitignore` thấy nó tự nhiên hơn
[3/4/2020, 6:15:12 AM] [// english-ignore]: Hoặc có thể vì biết xài `.gitignore` trước nên thấy vậy
[3/4/2020, 6:15:34 AM] [// english-ignore]: Lần đầu thấy `.gitkeep` cái tưởng của mình bỏ qua cái tính năng này hồi nào không hay
[3/4/2020, 6:19:03 AM] [tay vịn của anh bán chuối - cty A tìm FE]: :+1:
[3/4/2020, 6:19:33 AM] [tay vịn của anh bán chuối - cty A tìm FE]: Em thấy nhiều file gitignore hơi confuse
[3/4/2020, 6:21:30 AM] [// english-ignore]: Vậy à, thường trong project thấy cũng ít cần empty folders lắm, trừ khi boilerplate
[3/4/2020, 6:25:38 AM] [tay vịn của anh bán chuối - cty A tìm FE]: đúng rồi, nay em ngó qua Angular project được tạo bằng angular cli mới thấy
[3/5/2020, 9:38:58 PM] [Cậu Làm Vườn]: Personally, I think the fact that we're been missing it this whole time and still doing fine means that it's not that much useful. Or the use case is super niche.
[3/6/2020, 2:54:08 AM] []: til: “There Is No Biological Reason to Eat Three Meals a Day”. It’s all a scam
[3/6/2020, 3:09:55 AM] []: ^Do bạn chưa chơi trong thế giới devops thôi
[3/6/2020, 3:11:01 AM] []: Chưa kể là nó khá useful nếu muốn làm một cái skeleton project. Kiểu để example folder structure
[3/6/2020, 3:11:50 AM] [huynh.cam]: Eat whenever you like
[3/6/2020, 3:12:31 AM] []: :point_up: that, but I’m actually more one-meal-a-day kinda guy
[3/6/2020, 3:14:39 AM] [// english-ignore]: The fact is I don't understand what Bần wanted to say
[3/6/2020, 3:14:51 AM] [// english-ignore]: And DevOps is a wild world :table-flip:
[3/6/2020, 3:15:11 AM] [huynh.cam]: wouldn't that be bad for your stomach?
[3/6/2020, 3:19:00 AM] [Cậu Làm Vườn]: I'm more like 2-meals-a-day kinda guy, intermittent fasting style
[3/6/2020, 3:29:37 AM] []: 16 8?
[3/6/2020, 3:29:50 AM] []: I’ve been doing 20:4 for a while
[3/6/2020, 3:30:14 AM] [Cậu Làm Vườn]: 18-6 mostly
[3/6/2020, 3:31:31 AM] [Cậu Làm Vườn]: 20-4 is a little bit inconvenient and hard for me
[3/6/2020, 3:32:25 AM] [huynh.cam]: out of curiosity, why do you guys fast?
[3/6/2020, 3:32:42 AM] [ko luong thien]: Why you guys reverse the numbers.. why not just say 4 20..
[3/6/2020, 3:33:17 AM] [ko luong thien]: What do the numbers mean..
[3/6/2020, 3:33:20 AM] [huynh.cam]: because ... fasting is more important than eating?
[3/6/2020, 3:33:32 AM] [huynh.cam]: 20 hours fasting, 4 hours eating
[3/6/2020, 3:34:14 AM] [ko luong thien]: Didn't know that, I thought eating at 4 and 20 o clock :shake:
[3/6/2020, 3:35:50 AM] [ko luong thien]: Is that continuous or not? Like I have 2 hours to eat, then wait 10, then another 2, then another 10?
[3/6/2020, 3:36:03 AM] []: I started out as an experiment to test my will power, nothing else, I didn’t even care about the health benefit or losing fat.
and it gradually became a lifestyle
[3/6/2020, 3:36:28 AM] []: @thien u can only eat in a specific time window (8 hours), the other 16 u can’t eat anything
[3/6/2020, 3:36:54 AM] [huynh.cam]: @thien <https://www.dietdoctor.com/intermittent-fasting>
[3/6/2020, 3:38:58 AM] [huynh.cam]: but what would you do if you are hungry during in the fasting period?
[3/6/2020, 3:39:57 AM] [ko luong thien]: Thanks guys so 20 4 means I don't eat anything for 20 hours..
[3/6/2020, 3:40:07 AM] [Cậu Làm Vườn]: Well it work tremendously well for cutting fat and losing weight. I lose 10kg in 6 months when I first started, that is when combined with exercise.
[3/6/2020, 3:40:45 AM] [Cậu Làm Vườn]: Later on I find it much more convenient also. One less meal to worry about :omg:
[3/6/2020, 3:41:08 AM] []: <https://www.businessinsider.com/twitter-ceo-jack-dorsey-only-eats-7-meals-per-week-2020-1>
[3/6/2020, 3:41:28 AM] []: this dude has a crazy routine, meditate for 2 hours a day? I can’t even do 5 mins
[3/6/2020, 3:41:39 AM] [Cậu Làm Vườn]: &gt; but what would you do if you are hungry during in the fasting period?
You get used to it after a while
[3/6/2020, 3:42:21 AM] [Cậu Làm Vườn]: Just like when eating low carb, after awhile our body kinda switch gears.
[3/6/2020, 3:42:25 AM] [huynh.cam]: &gt; You get used to it after a while
isn't that suffering?
[3/6/2020, 3:43:12 AM] []: you won’t feel uncomfortable at all once your body is used to it
[3/6/2020, 3:43:17 AM] [Cậu Làm Vườn]: No, not at all, it just means that your body need time to adapt.
[3/6/2020, 3:43:37 AM] []: just like Ban said, the body just switch to burning fat as the energy source, instead of using sugar
[3/6/2020, 3:44:14 AM] [Cậu Làm Vườn]: Like when you eating low carb, you will feel tired for the first few days, because your body is used to using carb as the main source of calories. After some time, it switch to using fat and protein instead.
[3/6/2020, 3:46:33 AM] [Cậu Làm Vườn]: It's the opposite of suffering. During fasting time, I feel like I have much better focus and clarity.
[3/6/2020, 3:46:56 AM] [Cậu Làm Vườn]: As long as I have enough water to drink. I'm good.
[3/6/2020, 3:47:42 AM] [huynh.cam]: but would there be any bad effect if you are hungry but refuse to eat?
[3/6/2020, 3:51:09 AM] [Cậu Làm Vườn]: I think you can find research that tell you it's not, but to an extent: 12-24 hours, not really, a couple of days or a week, may be. I think most stomach problems come from consuming too much acidic or alcoholic food and drink on an empty stomach, not from being simply hungry.
[3/6/2020, 3:52:22 AM] [Cậu Làm Vườn]: I don't think out near ancestor have meal at regular interval as we are today. And we are not far enough from them to change that much genetically
[3/6/2020, 3:53:23 AM] [Cậu Làm Vườn]: That is a lot of "I think", but there's a lot of researchs around on the topic. I just can't give a correct ref
[3/6/2020, 3:54:10 AM] [huynh.cam]: there is a fundamental difference between eating on a schedule and eating when hungry I guess
[3/6/2020, 3:54:47 AM] [huynh.cam]: yeah I read some research on the topics but it's still quite controversial
[3/6/2020, 3:56:33 AM] [huynh.cam]: I eat on hungry (3-5 meals a day) since I was 20 or something, my BMI is usually 18.7-19.0
[3/6/2020, 3:57:09 AM] [huynh.cam]: ofc BMI isn't the best way to measure how healthy you are
[3/6/2020, 3:57:44 AM] [huynh.cam]: but I almost never gain excess weight just because I eat a lot of meals
[3/6/2020, 3:57:48 AM] [Cậu Làm Vườn]: Personally, I have high blood sugar and was overweight. These kinds of diets work for me, so anecdotally it's not 100% fad. But I do believe there's some misinformation spreading around.
[3/6/2020, 3:59:32 AM] [Cậu Làm Vườn]: Well it's not because we think eating 3 meals a day is too much. But if you were overweight, fundamentally, eating 2 meal a day put your body on calorie deficit, so naturally you'll lose some weight.
[3/6/2020, 4:00:44 AM] [ko luong thien]: Do you guys have problem with your spouse regarding this? Like we usually need to have dinner together.. so that would be my only meal of the day right
[3/6/2020, 4:01:44 AM] [Cậu Làm Vườn]: Not much problem at all. 18-6 mean you eat at noon and 6pm or at 1pm and 7pm, which is quite normal. You just skip breakfast.
[3/6/2020, 4:02:11 AM] [ko luong thien]: Oh I see..
[3/6/2020, 4:03:22 AM] [Cậu Làm Vườn]: And that does not mean that you will always lose weight. If during that 6 hours interval, you consume an unholy amount of food, you will still gain weight :lol:
[3/6/2020, 4:03:26 AM] [huynh.cam]: &gt; You just skip breakfast.
haha I recalled back then there was a propaganda on TV about skipping breakfast would be bad for your health
[3/6/2020, 4:04:38 AM] [Cậu Làm Vườn]: If you don't want to skip break fast, you can eat at 7am and around noon. But so far skipping breakfast has been easier (and more convenient) for me because we gotta have dinner with friends and family sometimes
[3/6/2020, 4:11:41 AM] []: <https://www.theguardian.com/lifeandstyle/2016/nov/28/breakfast-health-america-kellog-food-lifestyle> @hqc
[3/6/2020, 4:12:48 AM] []: I have skipped breakfast my whole college life, I didn’t call it intermittent fasting, I called it being poor. I turned out fine, so yeah, breakfast is not the most important meal of the day
[3/6/2020, 4:13:45 AM] [huynh.cam]: LOL
[3/6/2020, 4:15:22 AM] [Cậu Làm Vườn]: @khoiracle We called it "Pulling an all nighter and sleeping till noon" :vayvay:
And yes it is truly economical
[3/6/2020, 5:26:08 AM] []: Nice, from now on, if there is something odd, I would say it's from Devops world :pepegood:
[3/6/2020, 5:41:31 AM] [Cậu Làm Vườn]: @kcj.pop.com_rbvn dạ em xin hứa từ rày về sau sẽ cố gắng giữ gìn và phát huy nét đẹp truyền thống của tiếng Việt ạ :okay:
[3/6/2020, 5:52:11 AM] [// english-ignore]: Ừa, qua tin em
[3/8/2020, 10:34:11 PM] []: Can i drink coffee in fasting time?
[3/8/2020, 10:38:31 PM] []: black coffee is fine
[3/8/2020, 10:47:48 PM] []: :crying: i drink coffee with milk
[3/8/2020, 10:57:03 PM] [unrealhoang]: #til design by invariant
[3/8/2020, 10:59:09 PM] []: details, please :think:
[3/8/2020, 10:59:17 PM] [Cậu Làm Vườn]: Class invariant?
[3/8/2020, 11:01:37 PM] [unrealhoang]: thì là collect những invariant của system, và design component around those invariant
[3/9/2020, 12:35:55 AM] [stronglong]: #til Mac magic :sparkles:
máy đang gào rú, quạt chạy ầm ầm
bật siri
=&gt; QUẠT IM LUÔN Ạ
tắt siri
=&gt; quạt lại gào rú tiếp @@ :sparkles: :why:
[3/9/2020, 12:36:13 AM] [lATAl]: :33:
[3/9/2020, 12:36:34 AM] [xuan]: Yup, confirmed
[3/9/2020, 12:36:56 AM] [xuan]: miinhf dùng mac 2018 cũng bị tương tự
[3/9/2020, 12:36:57 AM] [xuan]: @@
[3/9/2020, 12:37:27 AM] [phugodness]: same here :disappointed:
[3/9/2020, 12:37:41 AM] [usbc]: cái con siri quyền lực dzậy =))))
[3/9/2020, 12:44:30 AM] [lATAl]: hay nó tắt quạt cho đỡ bị dính tiếng ồn vào mic :))
[3/9/2020, 12:45:45 AM] [manhdv]: siri nó bảo quạt im để nó còn nghe chứ sao. Ồn vậy nó nghe sao nổi :)))))))))))
[3/9/2020, 1:08:48 AM] []: it’s the small things like this which make Apple the pioneer when it comes to UX
[3/9/2020, 1:08:49 AM] []: love it
[3/9/2020, 1:34:35 PM] [huy]: #til Sublime Text rendered using Skia, a library from Google
[3/9/2020, 5:33:31 PM] [meowwwwwwwwwwwwwwww]: *renderer :think:
[3/9/2020, 5:34:38 PM] [huy]: ignored :pepeandao:
[3/9/2020, 5:36:52 PM] [unrealhoang]: *is rendered
[3/9/2020, 8:01:59 PM] [Cậu Làm Vườn]: #til 2-fingers typing is called hunt-and-peck
[3/9/2020, 8:02:45 PM] [dat]: ^ which is.. "mổ cò"
[3/9/2020, 8:02:51 PM] [dat]: dịch cũng hợp lý nhỉ :))
[3/10/2020, 1:09:23 AM] [minh.nguyen]: #til Tắt docker xong pin trâu hơn hẳn
[3/10/2020, 3:51:18 AM] [typescriptpher]: anh kéo cái build Intellij pin dc 30min nên ko care lắm = ))
[3/10/2020, 4:06:26 AM] [ko luong thien]: Wtf..
[3/10/2020, 4:08:08 AM] [dzung_nguyen]: #til <https://www.predator.dev/> tool test performance run trên docker/kubernet tạo test, job từ UI và rất là dynamic
[3/10/2020, 4:10:01 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: k6 đi bạn, siêu xịn
[3/10/2020, 10:03:56 PM] [ZeroX]: #til <https://docs.microsoft.com/en-us/windows/win32/api/winbase/nf-winbase-accesscheckbytyperesultlistandauditalarmbyhandlea?redirectedfrom=MSDN>
:shake:
[3/10/2020, 10:07:34 PM] [ZeroX]: but wait, there's moar
<http://ashutoshmehra.net/blog/2010/02/long-function-names/>
[3/10/2020, 11:32:43 PM] [gaupo]: #til ACD (Automatic Call Distribution) <https://en.wikipedia.org/wiki/Automatic_call_distributor> feature of Virtual Call Center.
[3/10/2020, 11:33:31 PM] [gaupo]: Still finding how ppl implement it.
[3/10/2020, 11:47:08 PM] [ko luong thien]: This is public api
[3/10/2020, 11:47:24 PM] [ko luong thien]: Wait until you see internal ones
[3/10/2020, 11:47:54 PM] [ko luong thien]: Even at a small company like cty E, a function name may already longer than half of my screen width (40 chars) =))
[3/10/2020, 11:48:02 PM] [ko luong thien]: Not a good thing though
[3/11/2020, 12:08:56 AM] [ZeroX]: :shake:
[3/11/2020, 2:30:29 AM] [typescriptpher]: #til <https://twitter.com/naval/status/1225674500882100226?s=20> AI = “Anonymous Indians.”
[3/11/2020, 8:11:14 AM] []: #til Google Cloud Platform `gcloud app deploy` vẫn sẽ giữ lại các versions cũ của deployment cũ. Nếu trong code có run 1 cái cronjob hay gì gì, thì nó vẫn được trigger
```--stop-previous-version
Stop the previously running version when deploying a new version that receives all traffic.
Note that if the version is running on an instance of an auto-scaled service in the App Engine Standard environment, using --stop-previous-version will not work and the previous version will continue to run because auto-scaled service instances are always running.```
<https://cloud.google.com/sdk/gcloud/reference/app/deploy>
Solution là delete tất cả những version cũ đi, dùng `gcloud app deploy --version=specificVersion` :disappointed:
[3/12/2020, 1:11:29 AM] [huynh.cam]: <https://twitter.com/pallithordarson/status/1236549305189597189>
[3/12/2020, 1:13:24 AM] [huy]: well, soap work because it make the coronavirus slip off
[3/12/2020, 1:16:30 AM] [unrealhoang]: fake news
[3/12/2020, 1:17:34 AM] [huy]: how would you explain to a 3 years old so he would wash his hand everyday
[3/12/2020, 1:17:39 AM] [huynh.cam]: that's true in a sense
[3/12/2020, 1:18:14 AM] [huynh.cam]: &gt; Soapy water is totally different. Soap contains fat-like substances knowns as amphiphiles, some structurally very similar to the lipids in the virus membrane. The soap molecules “compete” with the lipids in the virus membrane.
[3/12/2020, 1:18:49 AM] [huynh.cam]: &gt; The soap molecules also compete with a lot other non-covalent bonds that help the proteins, RNA and the lipids to stick together. The soap is effectively “dissolving” the glue that holds the virus together. Add to that all the water.
[3/12/2020, 1:19:47 AM] [huy]: what kind of soap we're talking about here?
[3/12/2020, 1:19:55 AM] [huy]: the hardened soap blocks
[3/12/2020, 1:19:59 AM] [huy]: or liquid soap
[3/12/2020, 1:20:11 AM] [huynh.cam]: definitely not the protocol
[3/12/2020, 1:20:55 AM] [huynh.cam]: but what's the difference between them chemically?
[3/12/2020, 1:21:10 AM] [huy]: i don't know, you tell me
[3/12/2020, 1:21:23 AM] [huynh.cam]: no difference
[3/12/2020, 1:22:15 AM] [huy]: let me tell you what's the different
[3/12/2020, 1:23:08 AM] [huy]: ever wonder what would happen to the person who take a bath next to you when you rub the bar soap under your armpit?
[3/12/2020, 1:23:20 AM] [huy]: you can't do that with liquid soap
[3/12/2020, 1:23:22 AM] [huy]: :pepegood:
[3/12/2020, 1:28:09 AM] [huynh.cam]: xà bông đá FTW
[3/12/2020, 1:28:23 AM] [huynh.cam]: :pepegood:
[3/12/2020, 1:28:37 AM] [huy]: xa bong da' la no ko bi tan voi ko collect germs ha
[3/12/2020, 1:29:16 AM] [huynh.cam]: nó có bị tan với collect germ
[3/12/2020, 1:31:48 AM] [huy]: :thinkhard:
[3/12/2020, 1:31:52 AM] [huy]: so that's no good
[3/12/2020, 1:38:30 AM] [huynh.cam]: the thing is that ... no one would rub xà bông đá onto "háng" or "nách"
[3/12/2020, 1:38:45 AM] [huynh.cam]: wouldn't that solve your problem?
[3/12/2020, 1:40:27 AM] [huy]: why not?
[3/12/2020, 1:41:57 AM] [huynh.cam]: you ever use xà bông đá?
[3/12/2020, 1:43:36 AM] [huy]: nope
[3/12/2020, 1:44:01 AM] [huy]: it has sharp edges?
[3/12/2020, 1:44:02 AM] [huy]: :shake:
[3/12/2020, 1:44:19 AM] [huynh.cam]: it's nhám nhám
[3/12/2020, 1:44:34 AM] [huynh.cam]: you don't want to rub your "háng" into it
[3/12/2020, 1:45:07 AM] [huynh.cam]: you won't scratch your "háng" or "nách", but it doesn't feel good FWIW
[3/12/2020, 1:45:21 AM] [huy]: I see :shake: I can imagine it
[3/12/2020, 1:46:08 AM] [unrealhoang]: ở đâu có @snacky ở đó là #random :yaomin:
[3/12/2020, 1:47:31 AM] [huy]: :omg:
[3/12/2020, 1:47:47 AM] [huynh.cam]: :omg:
[3/12/2020, 8:18:34 PM] [dong]: #til dùng slack trên browser sẽ theo dõi được nhiều workspace hơn.
bye slack app ^_^
[3/12/2020, 8:19:23 PM] [Cậu Làm Vườn]: ^ Also feel more lightweight, if you were to open your browsers for other stuff anyway
[3/12/2020, 8:19:39 PM] []: Là sao, không hiểu?
[3/12/2020, 8:19:50 PM] []: :think:
[3/12/2020, 8:20:16 PM] []: nah, app slack trên Mac smooth hơn trên browser
[3/12/2020, 8:21:29 PM] [Cậu Làm Vườn]: Nhưng mà ý là mở nó cùng lúc với browser thì ăn RAM hơn vì electron nó pack thêm cái runtime vào nữa.
[3/12/2020, 8:22:35 PM] []: me have 16GB RAM, me no care :man-shrugging:
[3/12/2020, 8:23:08 PM] [Cậu Làm Vườn]: :areukiddingme:
[3/12/2020, 8:23:23 PM] [usbc]: #til dùng slack trên macos nhanh chuyển workplace nhanh hơn trên browser phòng khi sếp xuất hiện
[3/12/2020, 8:24:21 PM] [dong]: :oh:
[3/12/2020, 8:24:58 PM] [Cậu Làm Vườn]: Ủa dùng trên browser thì mở 2 cái workspace cùng lúc, sếp tới thì tắt cái tab là xong thôi mà :think:
[3/12/2020, 8:26:11 PM] [minh.nguyen]: Cmd 1 nhanh hơn là nhớ workspace đang ở tab nào
[3/12/2020, 8:29:41 PM] [Cậu Làm Vườn]: :think: Not sure, trên linux switch giữa workspace trên app thì thấy nó lag lag. Xài trên browser lại khỏe hơn.
[3/12/2020, 8:30:43 PM] [Cậu Làm Vườn]: @nghai.dev hình như cũng xài web là chính nè
[3/12/2020, 8:31:19 PM] [dong]: trên browser mở x tab = x wordspace, có ai nhắn gì nó hiện ở trên title, nó nhiều thông tin hơn là cái số ở trên icon của bên app
[3/12/2020, 8:32:16 PM] [Scott Dang]: cmd + số :+1:
[3/12/2020, 8:33:03 PM] [usbc]: sao em bấm không được nhỉ? command [1,2,3] ?
[3/12/2020, 8:33:52 PM] [usbc]: toàn dùng touchpad để chuyển …
[3/12/2020, 8:34:03 PM] [minh.nguyen]: hèn gì lâu :omg:
[3/12/2020, 8:34:11 PM] [minh.nguyen]: đang lướt #<channel-not-found> chuyển vậy là chết
[3/12/2020, 8:35:06 PM] [Cậu Làm Vườn]: Thật ra đang xài i3wm, bấm Mod+số nó bật ra cái i3 workspace khác nếu cần emergency switch :omg:
[3/12/2020, 8:35:58 PM] [usbc]: #til, leave <#C4EKCK0TF|gaming> và <#C0TUQGY83|random> trong giờ làm việc sẽ tăng hiệu suất công việc
[3/12/2020, 8:37:28 PM] []: ^But why? Có noti mà? Kể cả app cũng có badge hiện ra nếu có direct message mà
[3/12/2020, 8:37:51 PM] [minh.nguyen]: #<channel-not-found> và <#C0TUQGY83|random> không chưa đủ ...
[3/12/2020, 8:37:54 PM] [usbc]: mà sao em mấy cmd 1 ko ra nhỉ ?
[3/12/2020, 8:41:46 PM] [dong]: e thấy thoải mái hơn là chắc do dùng chrome nhiều và chuyển qua chuyển lại tab trên chrome là nhanh hơn so với chuyển từ chrome qua app và công thêm step chuyển giữa các workspace trong app
[3/12/2020, 8:46:51 PM] [Scott Dang]: theo index ấy bạn, cmd + 1 là wspace 1
[3/12/2020, 9:16:18 PM] [typescriptpher]: #til UDC <https://en.wikipedia.org/wiki/Universal_Decimal_Classification>
[3/12/2020, 9:22:53 PM] [unrealhoang]: Present mở gaming mới hiệu quả chứ
[3/12/2020, 11:07:22 PM] [bdragon]: thu hút người xem vl ngay
[3/13/2020, 12:24:43 AM] [// english-ignore]: Đang xài Firefox, mỗi workspace là 1 pinned tab
[3/14/2020, 2:17:50 AM] [Cậu Làm Vườn]: Wouldn't this be framework specific?
[3/14/2020, 2:24:46 AM] [minh]: Popular hashing be like: password + salt + work factor + salt round
[3/14/2020, 2:38:45 AM] [// english-ignore]: bcrypt nhe
[3/14/2020, 3:38:01 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: <https://xluffy.github.io/post/how-to-hash-store-password/|https://xluffy.github.io/post/how-to-hash-store-password/>
[3/14/2020, 3:38:07 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :think:
[3/14/2020, 3:41:32 AM] [minh]: :adore:
[3/14/2020, 3:58:49 AM] [giangnh]: hmmm laravel?
[3/14/2020, 5:59:26 AM] [typescriptpher]: md5?
[3/14/2020, 6:51:50 AM] [minh]: md5 = plain text = sha-256 :pepeandao:
[3/14/2020, 7:01:26 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: anh @eyeball có vụ này mới nè :smile:<https://twitter.com/marcan42/status/1238125727855206400?s=20>
Liên quan tới bọn Yubico
[3/14/2020, 7:22:56 AM] [typescriptpher]: ủa, ở dưới có thằng pwn dc ah =))
[3/14/2020, 8:46:02 PM] [_hoang_nguyen_]: #til Encryption and Signing
<https://medium.com/@piraveenaparalogarajah/understanding-encryption-signing-and-verification-fc256f6b763b>
[3/15/2020, 11:47:52 PM] [ko luong thien]: 99% là tình cờ phát hiện chứ k cố í đúng k :v
[3/15/2020, 11:53:58 PM] [typescriptpher]: #til HHKB = Happy Hacking Keyboard, quên cái dây nối gõ bàn phím mac tù vãi chưởng :v
[3/15/2020, 11:55:56 PM] [ko luong thien]: :think:
[3/15/2020, 11:56:04 PM] [ko luong thien]: chứ trước giờ anh đọc "HHKB" là gì..
[3/15/2020, 11:56:22 PM] []: hắc hắc ca bê :)))
[3/15/2020, 11:56:38 PM] [typescriptpher]: ˆ - true
[3/16/2020, 3:28:25 AM] [Cậu Làm Vườn]: Uhh... I hate this so much
[3/16/2020, 3:29:32 AM] [// english-ignore]: dm the worst
[3/16/2020, 3:29:53 AM] [// english-ignore]: Tởm lợm, lần nào đi Đức hay mấy nước lân cận cũng muốn điên với nó.
[3/16/2020, 3:34:18 AM] [ledongthuc]: ủa mà bên đó có đồ xịt đít ko?
Nếu ko có thì nó vẩy :shit: dính trên thành bằng cây chùi à?
[3/16/2020, 3:34:50 AM] [usbc]: :shake: nhin ghe ghe sao a’
[3/16/2020, 3:37:55 AM] [Cậu Làm Vườn]: :roflrofl:
[3/16/2020, 3:38:28 AM] [ledongthuc]: xả nước thì chừng nào mới sạch dc
[3/16/2020, 3:38:37 AM] [ledongthuc]: hoặc là dùng cái xịt đít xịt, còn ko thì bàn chà thôi
[3/16/2020, 3:42:45 AM] [Cậu Làm Vườn]: Imagine hangover poop :shake:
[3/16/2020, 3:48:54 AM] [// english-ignore]: Nô, ở Đức không có bidet nha. Bàn chà is your friend
[3/16/2020, 3:49:40 AM] [ledongthuc]: :shake: văn minh nhân loại tuột hậu so với VN quá
[3/16/2020, 3:50:08 AM] [// english-ignore]: Quan trọng là cái của nợ đó nó bốc mùi, siêu mùi luôn vì nó có ở dưới nước đâu
[3/16/2020, 3:50:22 AM] [// english-ignore]: Không hiểu German engineering kiểu gì :face_palm:
[3/16/2020, 3:54:00 AM] [xuan]: Wtf is this. Whyyyyyy :why:
[3/16/2020, 3:56:00 AM] [// english-ignore]: Thật ra cái chỗ dưới nó hơi trũng xuống đó, nên lúc nào cũng sẽ có ít nước ở đó =&gt; không dính luôn đâu
[3/16/2020, 3:56:10 AM] [// english-ignore]: Nhưng nói chung là, shitty design :disappointed:
[3/16/2020, 3:57:01 AM] [xuan]: Đi đức chắc mình xoay ngược người lại :lol:
[3/16/2020, 4:07:07 AM] [noob]: bên Ý cũng vậy :shake:
[3/16/2020, 4:20:32 AM] []: :facepalmanim:
[3/16/2020, 4:31:46 AM] []: Nghe nói là họ làm thế để quan sát màu chất thải, từ đó biết tình trạng sức khỏe
[3/16/2020, 4:36:54 AM] []: Em gọi là bàn phím đắt tiền :'(
[3/16/2020, 4:37:49 AM] [minh.nguyen]: Chùi rửa kiểu gì nhỉ? Nhất là nhà vs công cộng
[3/16/2020, 5:22:20 AM] [typescriptpher]: có mí cái còn đắt hơn...
[3/16/2020, 5:28:38 AM] []: Lần trước e được sợ vào con cứt tôm (custom) nghe bảo giá đâu đó 15m :(
[3/16/2020, 5:30:50 AM] [typescriptpher]: mèn ơi, chừng đó tiền có thể mua dc 15 con...
[3/16/2020, 5:40:40 AM] [typescriptpher]: practice một hồi google nó build xong một con bot giọng giống hệt giọng em...
[3/16/2020, 5:47:31 AM] [huynh.cam]: ghét nhất là đi hơi lâu hoặc phân hơi khô xíu là :shit: nó dính cứng ngắc
[3/16/2020, 5:51:10 AM] [huynh.cam]: cơ mà vụ nó thiết kế như vậy để kiểm tra :shit: là urban myth á
[3/16/2020, 5:52:34 AM] [huynh.cam]: để tránh vi trùng các kiểu
[3/16/2020, 5:53:37 AM] [huynh.cam]: đại khái là lúc bạn ị, :shit: nó làm đống nước đó bắn lên
[3/16/2020, 5:53:52 AM] [huynh.cam]: bạn bị nhiễm trùng
[3/16/2020, 5:54:40 AM] [xuan]: Trước khi đi thì mình để ít giấy lên mặt nước :thinkhard: hơi tốn giấy nhưng mà giải quyết đc vấn đề bắn đó
[3/16/2020, 5:55:24 AM] [huynh.cam]: mình nghĩ trước khi đi dội nước vài lần là ok
[3/16/2020, 5:55:41 AM] [huynh.cam]: bọn Giéc man nghĩ nhiều quá
[3/16/2020, 6:43:02 AM] [unrealhoang]: #til NAT loopback:
Many routers and some security tools prevent loopback connections as a security feature. This means that a machine on your local network cannot connect to the external IP address (such as 208.112.93.73) of a machine that is also on your local network. Connecting to a local IP address (such as 192.168.0.2) of that same machine works fine.
[3/16/2020, 7:19:00 AM] [huy]: :okay:
[3/16/2020, 7:30:02 PM] [lhlong]: dùng nhưng có vẻ là nghĩ tới việc đấy
[3/16/2020, 9:21:26 PM] [hasagi]: machine local network có connected to internet ko a
[3/16/2020, 9:22:39 PM] [unrealhoang]: Có chứ
[3/16/2020, 9:23:03 PM] [unrealhoang]: Ý là nó không đi ra ngoài rồi NAT vào lại ấy
[3/16/2020, 9:24:32 PM] [unrealhoang]: Đơn giản là anh mở cái webserver port 8000, NAT ra internet, thì anh access cái webserver đó bằng external IP bị connection refused
[3/16/2020, 9:26:08 PM] [unrealhoang]: Nhưng anh nhờ người khác (ngoài local network) access vô cái webserver đó thì được
[3/16/2020, 10:27:21 PM] [hasagi]: À hiểu
[3/16/2020, 10:27:56 PM] [hasagi]: Protect gì nhỉ?
[3/16/2020, 10:28:05 PM] [hasagi]: Tấn công từ internal network à
[3/16/2020, 10:28:18 PM] [unrealhoang]: cái này thì không biết :thinkmid:
[3/16/2020, 10:28:30 PM] [unrealhoang]: chắc có atk nào đó lợi dụng cái này
[3/16/2020, 10:28:52 PM] [unrealhoang]: @runi_mage hứng thú thì nghiên cứu rồi transfer đi :adore:
[3/16/2020, 10:30:14 PM] [Cậu Làm Vườn]: #til This is a thing
[3/16/2020, 10:30:16 PM] [Cậu Làm Vườn]: <https://en.wikipedia.org/wiki/Domain_name_front_running>
[3/16/2020, 10:31:43 PM] [Cậu Làm Vườn]: Did a quick domain search today and find out Godaddy has been registering a bunch of domains for themselves and sell it back at absurd price
[3/16/2020, 10:31:48 PM] [Cậu Làm Vườn]: f*ck Godaddy
[3/16/2020, 10:32:53 PM] [Cậu Làm Vườn]: Not sure how this is legal
[3/16/2020, 10:34:39 PM] [huy]: there's nothing wrong with buying something that available on the market, hold it, and sell it back to someone who needed
[3/16/2020, 10:34:58 PM] [huy]: as long as you don't block the demand
[3/16/2020, 10:35:35 PM] [Cậu Làm Vườn]: well if you're an individual doing domain squating, it's kinda ok
A little bit jerky in my opinion, but still ok
[3/16/2020, 10:35:52 PM] [Cậu Làm Vườn]: but a registrar doing that is not ok
[3/16/2020, 10:36:27 PM] [hasagi]: =)) til thì til cho tới chứ a
[3/16/2020, 10:37:33 PM] [Cậu Làm Vườn]: That is basically price gouging
[3/16/2020, 10:38:01 PM] [huy]: they don't buy it as a registrar
[3/16/2020, 10:38:12 PM] [huy]: they practice the freedom and buy it just as any buyer out there
[3/16/2020, 10:38:29 PM] [Cậu Làm Vườn]: ok, might explain why that is legal
[3/16/2020, 10:38:31 PM] [unrealhoang]: nah, not needed to me atm :omg:
[3/16/2020, 10:38:41 PM] [Cậu Làm Vườn]: but that is shady as :shit:
[3/16/2020, 10:38:48 PM] [huy]: it's not violating any law tho
[3/16/2020, 10:38:57 PM] [unrealhoang]: please don’t spam #til
[3/16/2020, 10:39:09 PM] [huy]: you just did it as well @unrealhoang
[3/16/2020, 10:39:33 PM] [huy]: to make it legal
[3/16/2020, 10:39:34 PM] [Cậu Làm Vườn]: Fair. Stil boycotting them. We should not support shady business.
[3/16/2020, 10:40:08 PM] [huy]: #til Sublime Text: Cmd + K + Up to split new pane, Cmd + K + Down to close a pane
[3/16/2020, 10:40:41 PM] [huy]: please find me some non-shady business that make substainable amount of money these days
[3/16/2020, 10:40:57 PM] [Cậu Làm Vườn]: Sorry my bad. Gonna leave it up for the sake of discussion.
[3/16/2020, 10:43:30 PM] [Cậu Làm Vườn]: There's a bunch of businessed that are not shady, but might not be making a great amount of money.
And there's probably a lot of companies that do shady thing under the hood that I don't know of. But as a person, I'm gonna not gonna continue supporting those that I know about.
[3/16/2020, 10:44:40 PM] [Cậu Làm Vườn]: E.g. I really love Patagonia. But they might be an extreme example as they are a certified B-corp
[3/17/2020, 12:25:02 AM] []: &gt; is it legal ?
yeah
&gt; is it morally wrong ?
I think same as reselling anything basically
[3/17/2020, 12:42:43 AM] [huynh.cam]: #TodayIRelearned lâu rồi ko xài quên mất "cache" có từ dịch thuần việt là "bộ nhớ đệm" :thinkhard:
[3/17/2020, 12:43:21 AM] [Cậu Làm Vườn]: I think this is more akin to knowing you need a certain kind of goods and buying all the supply of it. But yeah, this topic drubs people in different ways.
[3/17/2020, 1:04:01 AM] []: #HômBữaIL “cache” đọc là cash
[3/17/2020, 1:05:48 AM] [Cậu Làm Vườn]: ...
[3/17/2020, 1:05:52 AM] [Cậu Làm Vườn]: :notlikethis:
[3/17/2020, 1:06:09 AM] [Cậu Làm Vườn]: The hell...
[3/17/2020, 1:06:30 AM] [meowwwwwwwwwwwwwwww]: #til IDEMPOTENT_METHODS
A request method is considered _idempotent_ if the intended _effect_ on the server of multiple identical requests with that method is the same as the _effect_ for a single such request. And it’s worthwhile to mention that idempotency is about the _effect_ produced on _the state of the resource_ on the server and not about the _response status code_ received by the client.
[3/17/2020, 1:07:29 AM] [ledongthuc]: :kappa: ơ thế lâu nay mình đọc sai à.
toàn đọc cát-chờ
[3/17/2020, 1:10:45 AM] []: not only limited to requests, but idempotent is a very important term in software engineering that can be apply everyhwere. For instance:
<https://arslan.io/2019/07/03/how-to-write-idempotent-bash-scripts/>
[3/17/2020, 1:10:53 AM] []: e thì nghe giang hồ đọc là ca-che :troll:
[3/17/2020, 1:11:20 AM] [meowwwwwwwwwwwwwwww]: interesting
[3/17/2020, 1:18:21 AM] [unrealhoang]: you mean qash @nguyenhuedang :troll:
[3/17/2020, 1:21:08 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: @vanhtuan0409 :vayvay:
[3/17/2020, 1:21:22 AM] []: A wise man once said: “Qash đọc là quát-sờ”
[3/17/2020, 1:29:52 AM] [tuan]: :vayvay:
[3/17/2020, 1:30:02 AM] [tuan]: cache hết cả vào thì lại chẳng idempotent
[3/17/2020, 1:34:38 AM] [Cậu Làm Vườn]: <https://we-build-vn.slack.com/archives/C32HMMUAW/p1584433917113600>
[3/17/2020, 1:35:13 AM] [Cậu Làm Vườn]: #til ^ `<http://www.example.com|www.example.com>.` (with trailing dot) is called fully qualified domain name or absolute domain name
[3/17/2020, 1:37:27 AM] [Cậu Làm Vườn]: What we usually use is relative domain name
[3/17/2020, 1:43:46 AM] [meowwwwwwwwwwwwwwww]: ^ DELETE với PUT đâu có cache nhỉ :think:
[3/17/2020, 1:43:47 AM] [anh bán chuối]: #til skip NYT paywall by adding . `<https://www.nytimes.com>./2020/03/17/world/coronavirus-news.html`
[3/17/2020, 1:45:10 AM] [hieu.huynh]: em thấy trang nào paywall, em out luôn, có tí chữ cũng kiết, thấy ghét
[3/17/2020, 1:45:33 AM] [anh bán chuối]: ừ mà bọn nó hay share NYT, :disappointed: FOMO thì cũng ráng kiếm đọc thôi
[3/17/2020, 1:46:35 AM] []: how does this work technically?
[3/17/2020, 1:47:06 AM] [anh bán chuối]: Paywall là 1 cái script dc load sau, chỉ đúng origin mới load thì phải :v - đoán chứ lười check
[3/17/2020, 1:48:59 AM] [tuan]: cache luôn kq bạn ơi :vayvay: mốt gọi lên ko chạy nữa
[3/17/2020, 1:49:14 AM] [Cậu Làm Vườn]: Confirmed by disabling JS
[3/17/2020, 1:50:31 AM] [hieu.huynh]: btw, nhân tiện nói về chuyện paywall, em thấy cách tiếp cận của <http://lwn.net|lwn.net> &amp; <http://stratechery.com|stratechery.com> hay vkl
[3/17/2020, 1:50:32 AM] [Cậu Làm Vườn]: Cái này do nó muốn Google crawl được content nên server rendered ra toàn bộ, chứ nhiều bên nó làm kĩ là cho dù có disabling JS vẫn không đọc đc.
[3/17/2020, 1:50:43 AM] [hieu.huynh]: vừa kích thích người ta subcribe, vừa đỡ bực
[3/17/2020, 3:42:45 AM] [SFzxc]: oh xịn xịn :beauty: :adore:
[3/17/2020, 3:44:19 AM] [SFzxc]: Bần code js mà disable JS hả :thinkhard:, hay disable ở 1 trình duyệt nào đó thôi phải ko
[3/17/2020, 3:45:22 AM] [anh bán chuối]: disable ở trang dc mà (mỗi trang 1 setting riêng ) nếu xài chrome
[3/17/2020, 3:46:07 AM] [SFzxc]: oh giờ em mới biết, lạc hậu ghê
[3/17/2020, 4:09:29 AM] [ko luong thien]: #til naming material <https://valadoc.org/glib-2.0/string.html>
[3/17/2020, 4:16:50 AM] []: =)))))) được anh ơi
[3/17/2020, 4:27:24 AM] []: yeah, uMatrix ftw :arggg:
[3/17/2020, 7:19:45 AM] [ko luong thien]: #til <https://developers.google.com/protocol-buffers/docs/encoding#varints> tks Minh
[3/17/2020, 7:48:59 AM] []: til OR-Tools <https://developers.google.com/optimization/introduction/overview> Google has a framework for solving optimization problems
[3/17/2020, 10:24:14 PM] [ko luong thien]: #til unicode &amp; varchar tks @nguyenquangminh
[3/17/2020, 10:24:27 PM] [ko luong thien]: vãi k còn làm chung thì học từ thanh niên nhiều vãi :okay:
[3/17/2020, 10:24:32 PM] [ko luong thien]: lúc còn làm chung thì :sosad:
[3/17/2020, 10:25:27 PM] [unrealhoang]: đọc #rustlang nha, mấy cái này trong <#C3HGW0MFZ|rustlang> có share hết :vayvay:
[3/17/2020, 10:26:08 PM] [unrealhoang]: @thien lurking #rustlang mà méo thèm đọc :crying:
[3/17/2020, 10:34:56 PM] [emacsguy]: học #rust có vẻ như học được khá nhiều thứ internal nhỉ đúng không anh @unrealhoang
[3/17/2020, 10:35:51 PM] [minh.nguyen]: thật ra học gì cũng học được :)) ai học rust thường kiểu hardcore, thích khổ nên sẽ tìm hiểu
[3/17/2020, 10:35:59 PM] [minh.nguyen]: mình học ruby cũng đọc internal tuốt luốt
[3/17/2020, 10:36:37 PM] [unrealhoang]: in a way, học Rust tới mức viết được code mà không phải fight với borrow checker nữa thì nó tương đương với học C++ viết được code cho production
[3/17/2020, 10:37:39 PM] [unrealhoang]: Rust nó đưa những cái best practice, internal interface ra upfront
[3/17/2020, 10:38:19 PM] [unrealhoang]: phải hiểu rõ thì mới code smooth được
[3/17/2020, 10:38:51 PM] [unrealhoang]: otherwise you will feel a constant struggle without knowing why
[3/17/2020, 10:39:06 PM] [unrealhoang]: như @snacky (sorry đá đểu tí) :roflrofl:
[3/17/2020, 10:39:51 PM] [huy]: :doubt:
[3/17/2020, 10:40:00 PM] [minh.nguyen]: Hèn gì nhiều người thích S&amp;M đến vậy
[3/17/2020, 10:40:04 PM] [minh.nguyen]: không hiểu sẽ không thấy cái hay của nó
[3/17/2020, 10:40:06 PM] [unrealhoang]: còn học C/C++ thì nó là incremental learning
[3/17/2020, 10:40:39 PM] [unrealhoang]: nhưng mà bị cái là thường không biết mình đang làm gì sai
[3/17/2020, 10:43:28 PM] [unrealhoang]: nên để viết production-grade C/C++ thì phải cực kì vững, và learning qua thời gian dài + kinh nghiệm
[3/17/2020, 10:43:31 PM] [ko luong thien]: thật chứ :sosad: mấy nay làm DB, k có @nguyenquangminh là mình thành snarky rồi
[3/17/2020, 10:47:20 PM] [huy]: &amp;
[3/17/2020, 10:47:21 PM] [huy]: ồ
[3/17/2020, 10:47:29 PM] [huy]: font của slack là font gì @thien
[3/17/2020, 10:47:31 PM] [huy]: cái dấu et nhìn vui quá
[3/17/2020, 10:48:57 PM] [ko luong thien]: Lato, k rõ có customized chưa
[3/17/2020, 10:49:03 PM] [ko luong thien]: cc @nghai.dev
[3/17/2020, 10:50:55 PM] []: Slack có customized
[3/17/2020, 10:51:36 PM] []: Làm sao để hide topic này trong slack ta. Mình hok muốn biết, mình hok muốn thấy cái topic này :)))
[3/18/2020, 9:37:37 AM] [huy]: #til JavaScript's Array sort function, by default, will compare the input as if it's an UTF-16 string, even if you put in a numnber, for example:
const a = [1, 81, 2, 9];
a.sort();
a will be [1, 2, 81, 9]
[3/18/2020, 6:35:43 PM] [Jun]: :pepegood: was in your situation. This is a bug. :roflrofl:
[3/18/2020, 7:21:22 PM] [unrealhoang]: best lang evar
[3/18/2020, 7:34:10 PM] [huy]: ublang
[3/18/2020, 7:37:00 PM] [usbc]: :omg:
```However, if numbers are sorted as strings, "25" is bigger than "100", because "2" is bigger than "1".```
[3/18/2020, 7:46:25 PM] [Cậu Làm Vườn]: #til white-glove delivery
[3/18/2020, 8:19:26 PM] [ko luong thien]: I know this like 4 years ago but still making this mistake every now and then :omg:
[3/18/2020, 8:19:53 PM] [unrealhoang]: not your fault
[3/19/2020, 1:21:02 AM] [// english-ignore]: #til cabin fever <https://www.verywellmind.com/cabin-fever-fear-of-isolation-2671734>
[3/19/2020, 8:44:34 PM] []: #til <https://wiki.archlinux.org/index.php/Dash> DASH (Debian Almquist shell)
Below command is in Ubuntu:
```$ ls -l /bin/sh
lrwxrwxrwx 1 root root 4 Oct 21 23:48 /bin/sh -&gt; dash```
[3/19/2020, 8:45:59 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: Ubuntu cũng dash
[3/19/2020, 8:47:08 PM] []: Yeah, em mới ăn hành xong :okay:
<https://askubuntu.com/a/886540/572147>
[3/19/2020, 8:48:02 PM] [tuan]: :cggt: what magic is this
[3/19/2020, 8:48:20 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :)) à, hồi xưa anh cũng ăn hành vụ này, debug ói máu luôn :disappointed:
[3/19/2020, 8:49:58 PM] [tuan]: ôi voãi mấy cái distro magic voãi
[3/19/2020, 8:54:40 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: mấy cái shell này khác nhau nhiều, syntax, tính năng. Như bash thì nhiều tính năng, nhưng ko phải system nào cũng có. Ví dụ POSIX shell thì ko có array
[3/19/2020, 8:56:23 PM] [tuan]: h xài zsh nhiều khi ko compliant vs POSIX :arggg: viết script đã đời lên servẻ ko chạy
[3/19/2020, 8:56:35 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: Xài shellcheck đi, ale có sẵn đó <https://github.com/koalaman/shellcheck>
[3/19/2020, 9:02:45 PM] [Cậu Làm Vườn]: Oh f*ck :cggt:
[3/19/2020, 9:09:31 PM] [hieu.huynh]: hmmm
[3/19/2020, 9:09:41 PM] [hieu.huynh]: Em chưa bị bao giờ
[3/19/2020, 9:09:54 PM] [hieu.huynh]: Có thể nào giờ em toàn define shebang là bash
[3/19/2020, 9:10:07 PM] [hieu.huynh]: Và bình thường run cũng xài bash script.sh
[3/23/2020, 5:22:16 PM] []: #til `T` trong `2011-08-12T20:17:46.384Z` chi la literal de tach biet time and date <https://stackoverflow.com/questions/8405087/what-is-this-date-format-2011-08-12t201746-384z>
[3/24/2020, 12:24:06 AM] [dong]: bữa code go bị 1 lần ko hiểu vì sao random mà nó luôn đúng với lần chạy trước, chỉ biết là phải thay seed. Giờ thì biết rồi thank a
[3/25/2020, 8:03:00 AM] [ko luong thien]: #til <https://www.rosettacode.org/wiki/Rosetta_Code> :think:
[3/25/2020, 9:41:28 PM] [ko luong thien]: <https://we-build-vn.slack.com/archives/C0GCPHQNM/p1585190235015300?thread_ts=1585106512.002700&amp;cid=C0GCPHQNM> thank to @triet
[3/25/2020, 11:11:14 PM] [Shaw Vu]: white noise is good :smoke:
[3/26/2020, 2:00:34 AM] [white]: #til repo for online events around the world <https://github.com/okanaydin/online-events>
[3/26/2020, 5:51:39 PM] [chua dc luong thien]: #til Ngã 4 Hàng Sanh, đó giờ cứ tưởng Xanh :sadtroll:
[3/26/2020, 9:08:04 PM] []: ơ, Xanh mà
[3/26/2020, 9:13:03 PM] [ledongthuc]: <https://vnexpress.net/giao-duc/nhung-dia-danh-o-tp-hcm-thuong-bi-viet-sai-3530439-p3.html>
[3/26/2020, 9:17:55 PM] [ledongthuc]: :full_moon_with_face: lịch sử viết bởi người chiến thắng.
Và google map map thì được viết bởi số đông đồng ý.
[3/26/2020, 10:22:15 PM] [// english-ignore]: Ôi hàng cây xanh thắm dưới mái trường mến yêu. Có loài chim đang hót âm thầm tựa như nói. :notes::notes::notes:
Hàng Xanh nghen
[3/26/2020, 10:43:02 PM] [chua dc luong thien]: Sg làm gì có còn hàng cây xanh nào
[3/28/2020, 7:13:36 AM] [King Tran]: #til javascript’s `Date` months start with `0`
[3/28/2020, 7:19:02 AM] [typescriptpher]: #til <https://en.wikipedia.org/wiki/Polymath> A polymath (Greek: πολυμαθής, polymathēs, "having learned much"; Latin: homo universalis, "universal man") is an individual whose knowledge spans a significant number of subjects, known to draw on complex bodies of knowledge to solve specific problems.
[3/28/2020, 10:47:31 AM] [minh.nguyen]: #til <https://research.google/pubs/pub44824/|https://research.google/pubs/pub44824/>
[3/29/2020, 9:53:59 PM] [n]: #til use DynamicMessage to be able to list all fields and value in *runtime* by given Protobuf Scheme + Protobuf Binary file (Only support Java and C++)
[3/29/2020, 9:56:08 PM] [n]: the standard approach is that we have to generate all proto models files during the compile time then serializing from binary protobuf data
[3/29/2020, 11:31:04 PM] [ko luong thien]: #til <https://we-build-vn.slack.com/archives/C32HMMUAW/p1585549663104900?thread_ts=1585526358.087400&amp;cid=C32HMMUAW|https://we-build-vn.slack.com/archives/C32HMMUAW/p1585549663104900?thread_ts=1585526358.087400&amp;cid=C32HMMUAW> thanks @mquy
[3/30/2020, 7:33:31 AM] [ko luong thien]: #til "Third world countries" originally doesn't mean "poor countries" but "neutral countries after WW3" <https://en.wikipedia.org/wiki/Three-world_model>. For example Vietnam is a 2nd world country but Singapore is 3rd
[3/30/2020, 8:39:51 AM] [tay vịn của anh bán chuối - cty A tìm FE]: after WW2?
[3/30/2020, 8:40:42 AM] [ko luong thien]: :okay: dạ
[3/30/2020, 10:04:47 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: #til The United States of America and Canada uses the Pacific Time Zone or PT. It is based on the 120th meridian west of the Greenwich Observatory. It is called the *Pacific Standard Time (PST) in winter* and the *Pacific Daylight Time (PDT) in summer*. :neutral_face: :neutral_face: :neutral_face:
[3/30/2020, 10:08:26 PM] [huy]: only the west
[3/31/2020, 11:44:56 PM] [SFzxc]: #til Giờ mới biết Ruby có thằng này <https://ruby-doc.org/stdlib-2.7.0/libdoc/set/rdoc/Set.html> :thinkhard:
[3/31/2020, 11:49:01 PM] [unrealhoang]: Dùng hash cũng đc mà
[3/31/2020, 11:49:51 PM] [unrealhoang]: Trừ khi cần mấy cái set operator như intersect or union, different
[4/1/2020, 12:02:18 AM] [huynh.cam]: internally Set cũng dùng Hash mà
[4/1/2020, 12:15:13 AM] [SFzxc]: Dạ, có cái no duplicates với operators cũng hay, useful trong một số cases :omg:
[4/1/2020, 2:40:52 AM] [ZeroX]: #til Noise music :shake:
<https://en.wikipedia.org/wiki/Noise_music>
[4/1/2020, 5:31:47 AM] [ko luong thien]: #til
- how it looks ~&gt; correct
- what it looks like ~&gt; correct
- how it looks like ~&gt; incorrect
[4/1/2020, 5:31:51 AM] [ko luong thien]: <https://english.stackexchange.com/questions/55672/is-it-what-it-looks-like-or-how-it-looks-like>
[4/2/2020, 9:19:57 PM] [alias Trung.Le, as tle]: Nếu phần trật tự trong quan trọng thì dùng Set
[4/2/2020, 9:20:19 PM] [alias Trung.Le, as tle]: Hồi mới vào nghề mình cũng có câu hỏi này
[4/2/2020, 9:20:40 PM] [alias Trung.Le, as tle]: Ông lead nói mày đi xem bài nói Rick Hickey Easy Made Simple
[4/4/2020, 9:39:11 AM] [ko luong thien]: #til rel-noopener is not only helpful security-wise but also performance-wise
[4/4/2020, 9:39:15 AM] [ko luong thien]: <https://developers.google.com/web/tools/lighthouse/audits/noopener>
[4/4/2020, 9:39:34 AM] [ko luong thien]: &gt; When you open another page using target="_blank", the other page may run on the same process as your page, unless Site Isolation is enabled. If the other page is running a lot of JavaScript, your page's performance may also suffer.
This is surprise as f
[4/4/2020, 9:03:12 PM] [alias Trung.Le, as tle]: #til veth creates a pipe of which each end is a network interface. It could be used to establish connection between two Linux networks on different name space:
```ip netns create red # create network namespace red
ip netns create blue # create network namespace blue
ip link add veth-red type veth peer name veth-blue # create veth pipe between veth-red and veth-blue
ip link set veth-red netns red # assign veth-red interface to network namespace red
ip link set veth-blue netns blue # assign veth-blue interface to network namespace blue
ip -n red addr add 192.168.15.1/24 dev veth-red # assign IP address for veth-red
ip -n blue addr add 192.168.15.2/2 dev veth-blue # assign IP address for veth-blue
ip -n red link set veth-red up # bring veth-red up
ip -n blue link set veth-blue up # bring veth-blue up
ip netns exec red ping 192.168.15.2 # now red could ping blue
ip netns exec blue ping 192.168.15.1 # and blue could ping red```
[4/4/2020, 9:11:51 PM] [dzung_nguyen]: #til <https://app.apiary.io/> document api tiện vãi, viết markdown dễ đọc hơn format yaml của swagger
[4/4/2020, 9:13:54 PM] [minh.nguyen]: Lúc doc nó phình ra rất khó maintain :smile: công ty E đang xài. Hơi vật vã tí
[4/4/2020, 9:16:36 PM] [dzung_nguyen]: Document của mình chưa đủ lớn nên chưa biết thế nào :D
[4/4/2020, 9:27:43 PM] [dzung_nguyen]: <https://stoplight.io/studio/> tool này xài ngon nhưng mà ko collaborate được
[4/4/2020, 10:00:07 PM] [typescriptpher]: @nguyenquangminh xài cái này em có nối với Git ko, ví dụ khi api thay đổi thì sẽ phải manual update API document ah?
[4/4/2020, 10:01:17 PM] [minh.nguyen]: @eyeball Apiary nó là UI cho api blueprint syntax. Tụi em sử dụng thẳng API blueprint (<https://apiblueprint.org/>) và viết renderer riêng cho nó để khớp với pipeline của công ty, chứ không xài Apiary
[4/4/2020, 10:05:23 PM] [minh.nguyen]: Điểm yếu của nó là dài dòng, mà khó maintain. Ngoài ra, dạng doc này là soft contract, việc outdated với code là bình thường. Nên sắp tới em dang dụ chuyển sang Protobuf hẳn luôn.
[4/4/2020, 10:05:29 PM] [typescriptpher]: API blueprint (markdown) là em viết tay hay sinh từ code? Vì nếu viết tay thì có bị vấn đề là ví dụ API thay đổi mà quên ko update API blueprint ko?
[4/4/2020, 10:05:46 PM] [minh.nguyen]: :lol: câu trả lời có trước câu hỏi à :lol:
[4/4/2020, 10:05:51 PM] [typescriptpher]: ờ = ))
[4/4/2020, 10:05:56 PM] [typescriptpher]: vì anh cũng gặp phải vấn đề đó : ))
[4/4/2020, 10:06:15 PM] [typescriptpher]: solution của anh là API bản chất là contract, nên chỉ cần 1 single source of truth
[4/4/2020, 10:06:25 PM] [minh.nguyen]: Cái này tùy workflow. Công ty E đang áp dụng là document first =&gt; backend &amp; frontend impelement dự vào doc
[4/4/2020, 10:06:44 PM] [minh.nguyen]: Nên hiện tại đang work, nhưng không cách nào test được có implêmnt đúng theo doc không
[4/4/2020, 10:06:55 PM] [typescriptpher]: workflow của anh là toàn bộ API định nghĩa bằng protobuf hết (với full document cũng nằm trong file proto luôn), rồi tất cả tool xung quanh là generate theo file service này hết
[4/4/2020, 10:07:10 PM] [typescriptpher]: mà do là code gen nên ví dụ client dùng bản outdate, hoặc bị breaking change là compiler báo liền
[4/4/2020, 10:07:16 PM] [minh.nguyen]: ^ cách này chuẩn nè :dancer:
[4/4/2020, 10:07:25 PM] [minh.nguyen]: mà nhiều việc quá, nên em chưa làm
[4/4/2020, 10:08:34 PM] [typescriptpher]: uah, vì sẽ có 1 việc khá nặng là mấy cái code gen default đi cùng với gRPC/protobuf là... ko dùng được : )))
[4/4/2020, 10:08:50 PM] [typescriptpher]: do API ở dưới mình có hết rồi, nên kiểu gì cũng phải tự viết phần code gen lấy
[4/4/2020, 10:09:22 PM] [minh.nguyen]: Nếu theo đúng syntax thì được đó anh :))
[4/4/2020, 10:09:41 PM] [typescriptpher]: &gt; mà nhiều việc quá, nên em chưa làm
Tooling hiện nay của anh chỉ có mỗi... 1 cái Makefile thôi :vayvay:
[4/4/2020, 10:10:57 PM] [typescriptpher]: mà em có dùng luôn protobuf làm encoding ko?
[4/4/2020, 10:11:53 PM] [minh.nguyen]: <https://github.com/googleapis/googleapis/blob/master/google/longrunning/operations.proto>
[4/4/2020, 10:12:01 PM] [minh.nguyen]: ^ example cuar API doc gen tốt
[4/4/2020, 10:12:20 PM] [minh.nguyen]: HTTP servẻ thì encode ra json :omg:
[4/4/2020, 10:12:33 PM] [minh.nguyen]: em không tự tin việc encode ra binary để gởi
[4/4/2020, 10:12:38 PM] [minh.nguyen]: Team chưa ready lắm, debug cũng khó
[4/4/2020, 10:12:48 PM] [minh.nguyen]: (mà cái đó sau này chuyển dễ)
[4/4/2020, 10:14:11 PM] [typescriptpher]: yeah, anh đang để switch qua
```Content-Type: application/protobuf```
[4/4/2020, 10:15:27 PM] [minh.nguyen]: Nó nằm ở tầng dưới cùng. Nếu ở client và servẻ đều gen code ra thì sau này bước switch protôcol transparent. Không lo
[4/5/2020, 12:18:49 AM] [// english-ignore]: #til tiếng Maldives nó thế này ވިކިޕީޑިއާ އިންވިކިޕީޑިއާ :exploding_head: <https://en.wikipedia.org/wiki/Maldivian_language>
[4/5/2020, 12:20:14 AM] [// english-ignore]: @thien mua cái `nouseless.dv` nào
[4/5/2020, 12:23:53 AM] [ko luong thien]: Là gì á
[4/5/2020, 12:24:09 AM] [ko luong thien]: Đù có tên miền dv à
[4/5/2020, 12:24:18 AM] [ko luong thien]: Hồi đó chỉ có .do
[4/5/2020, 12:24:37 AM] [// english-ignore]: `<http://chithien.do|chithien.do>` à :think:
[4/5/2020, 12:25:53 AM] [ko luong thien]: <http://thien.do|thien.do> với <http://thn.do|thn.do>
[4/5/2020, 1:33:05 AM] [meowwwwwwwwwwwwwwww]: <https://docker-k8s-lab.readthedocs.io/en/latest/docker/bridged-network.html#veth-pair>
[4/5/2020, 1:38:23 AM] [minh]: Trông đẹp nhỉ... :think:
[4/5/2020, 2:40:16 AM] [sai]: #til Wobbly Table theorem
<https://www.youtube.com/watch?v=OuF-WB7mD6k>
[4/5/2020, 9:10:20 AM] [ko luong thien]: #til <https://developer.mozilla.org/en-US/docs/Web/CSS/Replaced_element>
[4/5/2020, 9:57:40 AM] [ko luong thien]: #til old but gold <https://css-tricks.com/almanac/properties/f/font-display/>
[4/6/2020, 11:38:15 AM] [ko luong thien]: #til <https://en.wikipedia.org/wiki/Ordinal_indicator>
[4/6/2020, 11:56:52 AM] [Ahihi]: #til nhìn xung quanh toàn người khủng, khủng hoảng tinh thần quá.
[4/6/2020, 11:59:31 AM] [ko luong thien]: nhifn owr ddaua these
[4/6/2020, 11:59:34 AM] [ko luong thien]: cho nhìn với
[4/6/2020, 12:00:49 PM] [Ahihi]: từ đồng nghiệp, các diễn đàn, các blog đó anh. Đọc/nghe họ viết/nói 1 hồi mà không hiểu gì cả.
[4/6/2020, 12:01:24 PM] [ko luong thien]: thường cái đó là tốt
[4/6/2020, 12:01:32 PM] [ko luong thien]: bạn đã biết những cái bạn chưa biết :adore:
[4/6/2020, 12:01:44 PM] [ko luong thien]: tốt hơn là k biết đến việc đó luôn
[4/6/2020, 12:02:05 PM] [ko luong thien]: giờ bước tiếp theo thì dễ rồi á :omg: có target để học/tìm hiểu rồi
[4/6/2020, 12:04:18 PM] [huy]: skim qua tháy: Nhìn xung quanh toàn người bị khùng
[4/6/2020, 12:04:20 PM] [huy]: :okay:
[4/6/2020, 12:06:33 PM] [ko luong thien]: cả 2 đều khủng hoảng như nhau though :thinkhard:
[4/6/2020, 12:07:14 PM] [Ahihi]: Có những thứ kiến thức không phải cứ học là được ạ. Đến từ trải nghiệm thì mới thấm.
Basically về technical thì đúng, giờ em cũng cố gắng học từng ngày, chỉ mong ra đường họ nói gì mình còn hiểu chút.
[4/6/2020, 12:09:56 PM] [ko luong thien]: interesting
&gt; Đến từ trải nghiệm thì mới thấm.
cá nhân mình thường thấy có 2 kiểu người mà có trải nghiệm nhiều hơn hẳn mình, 1 là dạng bet lớn, high risk high reward, 2 là dạng super khiêm nhường, gặp ai cũng học được chuyện đời người ta :thinkhard:
[4/6/2020, 12:10:38 PM] [huy]: &gt; 2 là dạng super khiêm nhường, gặp ai cũng học được chuyện đời người ta
[4/6/2020, 12:11:54 PM] [huy]: Có người từng nói với mình thế này: Bất cứ ai mà mình gặp trong cuộc đời, đều có lý do của nó, và bất cứ ai đều giỏi hơn mình về một điều gì đó. Cho nên mình phải có trách nhiệm sống khiêm nhường và tìm cách học hỏi cái mà họ giỏi hơn mình, vì đó là mục đích mà thượng đế đưa mình gặp với người đó.
[4/6/2020, 12:12:31 PM] [huy]: Nếu cuộc sống sắp đặt cho mình gặp đc một người mà mình không học hỏi đc gì từ người ta, thì đó là sai lầm của mình.
[4/6/2020, 12:15:25 PM] [Ahihi]: Chuẩn luôn đó anh.
[4/6/2020, 6:06:51 PM] [ZeroX]: nope, em nghĩ luôn sẽ có 2 mặt. Trái cần có phải để tồn tại giống như trên cần có dưới, nếu không thì làm sao phân biệt đc? Người xung quanh cũng thế, mình gặp những người giỏi hơn để học hỏi, nhưng khi mình gặp những người mà mình không học hỏi đc gì tức là mình là những người giỏi cho họ học hỏi.
[4/6/2020, 6:42:51 PM] []: #til Anyone know about this myth?
&gt; In 2014, science came to the conclusion that the elderly have trouble remembering because they have filled their heads with so much information from their long lives.
<http://www.sherlock-guide.com/extras/remembering>
[4/6/2020, 8:09:10 PM] [huy]: hồi đó a có đọc cái paper nói là bộ nhớ con ng ko có giới hạn. càng muốn nhớ nhiều thì sẽ nhớ nhiều. cái thông tin gì mình ko nhớ đc hoặc hay quên là do mình ko có để cho não bộ tương tác với thông tin do nên lâu dần nó mất kết nối với khối thông tin đó thôi
[4/6/2020, 8:56:44 PM] [tuan]: vẫn nhớ ngày đầu join webuild/golang :thinkhard: vô khá là ngộp nhưng có động lực bơi từ từ. Em thấy có 1 nơi tập hợp nhiều người giỏi vẫn tốt cho các bạn trẻ mà :smile:
[4/6/2020, 8:57:33 PM] [tuan]: hồi đó ấn tượng anh @snacky vãi :adore:
[4/6/2020, 8:58:13 PM] [Sony Huynh]: Case này sai lầm là do mình chưa biết họ mạnh và giỏi gì thôi :lel:
[4/6/2020, 8:58:55 PM] [huy]: ý là giờ hết rồi hả :pepeandao:
[4/6/2020, 8:58:56 PM] [minh]: ~Giờ thấy anh như ...~ :troll:
[4/6/2020, 8:59:03 PM] [hieu.huynh]: huy ra đê
[4/6/2020, 8:59:14 PM] [hieu.huynh]: huy tư bản
[4/6/2020, 8:59:36 PM] [hieu.huynh]: huy traitor
[4/6/2020, 8:59:45 PM] [minh]: vanhtuan tuyên bố huy ra đê là thằng đầu.. ra đê :yaomin:
[4/6/2020, 8:59:48 PM] [tuan]: h thì vẫn ấn tượng nhưng theo 1 cách khác :roflrofl:
[4/6/2020, 9:00:17 PM] [hieu.huynh]: dcm nhiều tên thế, khi nào thì khởi nghiệp phụ bếp :pepeandao:
[4/6/2020, 9:03:00 PM] [huy]: :pepeansung:
[4/6/2020, 9:41:58 PM] [Heo Con]: Cái này hình như `khiêm nhường` hơi quá rùi.:haha:
[4/6/2020, 10:02:55 PM] [ko luong thien]: @hieu.huynh lái hay quá anh
[4/6/2020, 10:43:49 PM] [// english-ignore]: Chờ tới ngày thành `huy bê đê` nữa là xong
[4/7/2020, 3:37:48 AM] [minh.nguyen]: #til <https://www.lurklurk.org/linkers/linkers.html> and `ldd` and `nm` tool
[4/7/2020, 3:39:30 AM] [tuan]: `huy lãnh tụ`
[4/8/2020, 10:31:53 AM] [ko luong thien]: #til statically render dynamic nextjs page, thank to @nhducit('s complain)
[4/8/2020, 10:31:58 AM] [ko luong thien]: <https://github.com/dvkndn/otf.show/commit/aa5cfd644759e1e60a50a2db4d573af70f5c775b>
[4/8/2020, 10:32:17 AM] [// english-ignore]: :ads:
[4/8/2020, 10:34:34 AM] [ko luong thien]: but that's the spirit of OSS :arggg: you can share your learning through your code rite :nod:
[4/8/2020, 12:19:39 PM] [Ahihi]: #til hiểu được thế nào là chấp nhận và từ bỏ.
[4/8/2020, 12:22:51 PM] [huy]: ^ that's when both your Knight and Queen being forked attack by opponent Knight, you have to sacrifice one, the best move should be saving the most valuable one and let the cheaper one die.
[4/8/2020, 12:23:19 PM] [ko luong thien]: thread
[4/8/2020, 12:23:21 PM] [ko luong thien]: this is not #random
[4/8/2020, 12:25:56 PM] [huy]: Random isn't a place
[4/8/2020, 12:25:57 PM] [huy]: it's a soul
[4/8/2020, 12:26:14 PM] [ko luong thien]: :adore:
[4/8/2020, 12:26:23 PM] [ko luong thien]: still you are bad
[4/8/2020, 12:27:15 PM] [Ahihi]: Đầu tiên là cố gắng đấm thằng Hiệp sĩ kia trước, nếu thấy đấm không lại thì mới chọn lựa.
[4/8/2020, 12:27:46 PM] [Ahihi]: Ít nhất là mình cố gắng hết sức mà cũng không được thì sau này nhìn lại cũng không hối hận.
[4/8/2020, 12:28:28 PM] [huy]: :pepegood:
[4/8/2020, 12:29:22 PM] [Ahihi]: Ai ở SG nhậu nhẹt gì ko, em cần uống 1 tí.
[4/8/2020, 12:30:03 PM] [Ahihi]: Em mời
[4/8/2020, 5:57:07 PM] [manhdv]: still alive VoE? :smile:
[4/8/2020, 8:24:26 PM] [minh.nguyen]: :smile: mốt vào trại cách ly uống chung
[4/8/2020, 9:42:56 PM] []: #til rã đông thịt trước khi nấu là cần thiết :(
[4/8/2020, 9:48:09 PM] [ledongthuc]: :trollface: em có cảm giác vừa có người ăn thịt sống
[4/8/2020, 10:06:49 PM] []: oh no, hoho, chẳng qua là lúc bỏ vào nồi luộc các miếng nó dính hết vào nhau ko chịu tách ra thoy :))
[4/8/2020, 10:11:23 PM] [ko luong thien]: Example: <http://www.eccentrifuge.com/clients/KosmikOT.html>
Demo: You Know Where :ads:
[4/8/2020, 10:14:51 PM] [Cậu Làm Vườn]: Noice
[4/8/2020, 10:26:26 PM] [vthu]: mua tủ lạnh có ngăn đông mềm
[4/8/2020, 10:30:16 PM] [minh.nguyen]: mắt mình không phân biệt được :cry:
[4/8/2020, 10:30:33 PM] [minh.nguyen]: nhìn xa xa cũng như nhau
[4/8/2020, 10:49:05 PM] [minh]: rã đông cũng cần kỹ thuật nữa :pepegood:
[4/8/2020, 10:54:09 PM] [minh]: nice
[4/8/2020, 11:31:06 PM] []: :male-cook:
[4/8/2020, 11:31:12 PM] []: microwave ftw
[4/9/2020, 2:46:37 AM] [Cậu Làm Vườn]: #til cho anh em trồng cây
Khi thay chậu hoặc tưới nước thấy đất có mấy con màu trắng trắng siêu nhỏ, chạy nhanh, có khả năng nhảy thì khả năng cao nó là bọ đuôi bật (springtail), loài nay thường ăn vật chất hữu cơ phân hủy, không gây hại lắm. Rệp rễ (root aphid) hay rệp sáp ở rễ (root mealybug) thường rất chậm, và để lại một lớp sáp trắng trong đất. Dính hai con này thì RIP. Google ảnh của 3 loài để biết thêm chi tiết khi cần nhận dạng.
[4/9/2020, 2:47:54 AM] [usbc]: vụ trồng cây này thì e chịu, =))) e trồng có vài cây nha đam mà nó lớn ko nổi luôn
[4/9/2020, 2:48:18 AM] [usbc]: lấy từ cây của nhà đứa bạn về trồng, bên nó trồng tốt lắm, to ơi là to, bên mình kiểu như suy dinh dưỡng =))
[4/9/2020, 2:49:02 AM] [usbc]: a đang trồng cây gì thế @harrisnguyen
[4/9/2020, 2:49:18 AM] [Cậu Làm Vườn]: Muốn tốt thì dùng phân tam chậm trộn vào đất hoặc vài tháng tưới phân hòa tan một lần. Cây nó cũng cần ăn như mình thôi :omg:
[4/9/2020, 2:49:44 AM] [minh]: cay mấy con rệp này vl
[4/9/2020, 2:50:07 AM] [Cậu Làm Vườn]: Nhiều lắm. Có ít chậu lan, sen đá, haworthia, lá gấm, sứ, với trồng rau thơm nữa :omg:
[4/9/2020, 2:50:49 AM] [Cậu Làm Vườn]: Mấy bữa trước cứ tưởng rệp hút nhựa rễ, làm hại phải tiệt trùng mấy chậu. Nay mới identify được.
[4/9/2020, 3:02:34 AM] []: Rệp sáp thì trừ sao được nhỉ? Bị trên lá/thân chứ không phải rễ
[4/9/2020, 3:16:51 AM] [// english-ignore]: :okay: Bần show hàng cây ở nhà nào
[4/9/2020, 3:18:10 AM] [minh]: mới chuyển nhà, đang xin mấy ông anh mua thùng về trồng rau củ quả, chứ chưa có ý định trồng cây cảnh lại :))
[4/9/2020, 3:18:42 AM] [// english-ignore]: Giờ phải đi mua đất nữa T___T
[4/9/2020, 3:20:34 AM] [minh]: Ủa @harrisnguyen trồng cây có lót than ko anh?
[4/9/2020, 3:46:25 AM] [Cậu Làm Vườn]: @quybx91 Không thích dùng thuốc diệt côn trùng thì có thể dùng nước rửa chén nhé. 5ml (~một muỗng cà phê) pha 3 lít nước. Bỏ vô bình rồi cứ tìm nó mà xịt.
[4/9/2020, 3:47:45 AM] [Cậu Làm Vườn]: @monodylh Không lót than vì để thoát nước tốt thì có option khác tốt hơn. Với nếu lót than thì nếu có tưới phân nó khử mất mấy chất hóa học trong đó.
[4/9/2020, 5:13:33 AM] [ko luong thien]: #til <https://www.w3.org/TR/2011/WD-html-markup-20110405/syntax.html#void-element|https://www.w3.org/TR/2011/WD-html-markup-20110405/syntax.html#void-element>
[4/9/2020, 9:17:04 AM] [ZeroX]: Bọc mỗi miếng thịt = plasic food wrap. Không bao giờ dính và khỏi rã đông :fast-omg:
[4/9/2020, 9:53:04 AM] [tuan]: có cách nào diệt mấy con này ko. Cây nhà anh đang bị cuốn chiếu
[4/9/2020, 9:55:57 AM] [minh]: Theo lý thuyết thì không
[4/9/2020, 7:57:20 PM] []: công phu quá :))
[4/10/2020, 3:05:19 AM] [dzung_nguyen]: cuốn chiếu thì có hại gì không nhỉ
[4/10/2020, 3:24:29 AM] [Cậu Làm Vườn]: Thường thì không, nó ăn vật chất hữu cơ phân hủy thôi, như lá cây chết chẳng hạn. Sự có mặt của nó và trùng là dấu hiệu của healthy soil system.
[4/10/2020, 3:28:36 AM] [Cậu Làm Vườn]: Còn nếu bị rệp rễ và rệp sáp rễ thì cách tốt nhất là thay đất tiệt trùng, ngâm rễ trong nước ấm 50 độ trong 10p để diệt trứng nếu có. Nếu trồng outdoor và ok với việc dùng thuốc diệt côn trùng thì tìm thuốc có thành phần imidacloprid. Trên Shopee nó có bán cái gôi là thuốc tím trị rệp Thái Lan Starkle G, cái đó xài cũng được, đã check thành phần, không phải là hàng tào lao. Mua về rải trên bề mặt rồi tưới nước.
Thuốc hóa học thì sure là hiệu quả nhất, nhưng mà mình cố gắng hạn sử dụng tối đa.
[4/10/2020, 4:13:09 AM] []: #music
[4/10/2020, 7:55:16 AM] [// english-ignore]: Người nông dân Bần thật đáng ngưỡng mộ :adore:
[4/10/2020, 8:01:54 AM] [minh]: Hãy gọi anh là Bần nông :adore:
[4/10/2020, 8:14:07 AM] [usbc]: :adore:
[4/10/2020, 9:10:27 AM] [tuan]: Nhà anh cuốn chiếu lên nhiều lắm. Sáng ra tưới cây thấy nó bò lúc nhúc luôn. Sợ nó ăn rễ cây
[4/10/2020, 4:04:40 PM] [Ahihi]: #til có thể setting như này trong vỉmrc để complie &amp; run nhanh cho C++, hợp với lập trình thi đấu:
``` nnoremap &lt;buffer&gt; &lt;C-m&gt; :w&lt;cr&gt;:!g++ -O2 % -o %&lt; -std=c++11 -I ./&lt;cr&gt;:!./%&lt;&lt;cr&gt;```
[4/10/2020, 4:05:32 PM] [Ahihi]: nvim không dùng được, không hiểu sao
[4/11/2020, 8:22:41 AM] [dzung_nguyen]: #til 25% thiên nga đen trống đồng tính và khi đến mùa sinh sản, 1 con trống sẽ giả thẳng gạ chịch 1 con mái sau đó cướp trứng về ấp
[4/11/2020, 10:05:10 AM] [ko luong thien]: :notbad:
[4/11/2020, 11:02:10 AM] [minh.nguyen]: #til <http://fingfx.thomsonreuters.com/gfx/rngs/USA-BANKS-COBOL/010040KH18J/index.html|http://fingfx.thomsonreuters.com/gfx/rngs/USA-BANKS-COBOL/010040KH18J/index.html>
[4/13/2020, 1:22:44 AM] [usbc]: #til : use onMouseDown instead of onClick when onBlur preventing click in React
[4/13/2020, 1:33:10 AM] []: có a, e thấy hơi phiền, nó báo suốt ngày
[4/13/2020, 1:41:10 AM] [minh]: em cũng thấy phiền vl... :disappointed: mà cái auto upgrade của nó dởm vãi, có repo nó tự pull request có repo yêu cầu nó pull mà cả nửa năm nó ko thèm pull
[4/13/2020, 2:07:41 AM] [huynh.cam]: Oh phiền vkl
[4/13/2020, 2:08:01 AM] [huynh.cam]: vô tắt luôn
[4/13/2020, 2:49:08 AM] [ko luong thien]: :ie: #til React's async controlled state :sosad:
```interface Props {
foo: string;
setFoo: string =&gt; void; // this is async
}
const Input: React.FC&lt;Props&gt; = ({ foo, setFoo }) =&gt; {
const [_foo, _setFoo] = useState&lt;string&gt; (foo);
useEffect (() =&gt; { _setFoo (foo); }, [foo]); // out =&gt; in
useEffect (() =&gt; { setFoo(_foo); }, [_foo]); // in =&gt; out
return &lt;input value={_foo} onChange={_setFoo} /&gt;;
};```
[4/13/2020, 3:12:20 AM] [tay vịn của anh bán chuối - cty A tìm FE]: evil
[4/13/2020, 3:12:29 AM] [tay vịn của anh bán chuối - cty A tìm FE]: * hóng usecase
[4/13/2020, 3:36:52 AM] [ko luong thien]: #frontend anh
[4/13/2020, 7:37:00 AM] [tb]: #til Undo is better than confirmation for most cases, confirmation is better when action is irreversible
<https://ux.stackexchange.com/questions/71960/deletion-confirm-or-undo-which-is-the-better-option-and-why>
<#C16AY670U|til> <https://goodui.org/>
[4/13/2020, 4:30:46 PM] [typescriptpher]: <https://mobile.twitter.com/ThrillScience/status/1249742678532620293|https://mobile.twitter.com/ThrillScience/status/1249742678532620293> #til Skynet was written in COBOL
[4/13/2020, 6:02:01 PM] [ko luong thien]: #til k trả tiền thuê nhà 3 tháng mới bị đuổi, at least là theo luật <https://moj.gov.vn/vbpq/lists/vn%20bn%20php%20lut/view_detail.aspx?itemid=30345|https://moj.gov.vn/vbpq/lists/vn%20bn%20php%20lut/view_detail.aspx?itemid=30345>
[4/13/2020, 6:57:41 PM] [nakhoa]: #til anything written while the IME is active will have keyCode = 229 (<https://github.com/facebook/react/issues/14512>)
[4/13/2020, 7:02:10 PM] [nakhoa]: @monodylh đồng chí chắc phải handle event onKeyUp lúc đó e.key mới có value thực sự.
[4/13/2020, 7:08:20 PM] [nakhoa]: à đang nói cái <https://typings-app.now.sh/> khi mà gõ với ibus ấy =)), fix để toai gõ tiếng việt với
[4/13/2020, 7:38:26 PM] [minh]: Bản build test là `onKeyUp` đó anh, nhưng mà gặp vấn đề là cái keyup nó bị delay nên cảm giác gõ chậm rõ rệt lắm nên em mới đổi thành `onKeyDown`
[4/13/2020, 7:39:26 PM] [minh]: ibus thì... nightmare vl em đang list nó vào bugs problem rồi mà chưa nghĩ ra hướng giải quyết :sosad:
[4/14/2020, 2:43:55 AM] [// english-ignore]: #til `/shrug` command trong Slack ¯\_(ツ)_/¯
[4/14/2020, 2:45:23 AM] [minh]: ¯\_(ツ)_/¯
[4/14/2020, 2:45:56 AM] [// english-ignore]: @triet (눈‸눈)
[4/14/2020, 2:46:50 AM] [ko luong thien]: ¯\_(ツ)_/¯
[4/14/2020, 3:06:59 AM] [anh bán chuối]: wth ¯\_(ツ)_/¯
[4/14/2020, 3:08:09 AM] [usbc]: ¯\_(ツ)_/¯
[4/14/2020, 3:16:09 AM] []: ¯\_(ツ)_/¯
[4/14/2020, 3:16:28 AM] [xuan]: ¯\_(ツ)_/¯
[4/14/2020, 3:27:51 AM] [vthu]: ¯\_(ツ)_/¯
[4/14/2020, 3:28:19 AM] [unrealhoang]: ¯\_(ツ)_/¯
[4/14/2020, 3:33:12 AM] [su]: ¯\_(ツ)_/¯
[4/14/2020, 3:34:05 AM] [Cậu Làm Vườn]: ¯\_(ツ)_/¯
[4/14/2020, 3:35:45 AM] [meowwwwwwwwwwwwwwww]: ¯\_(ツ)_/¯
[4/14/2020, 3:36:11 AM] [// english-ignore]: &gt; Mà kệ cha nó, mình còn trẻ, có gì đâu mà căng ¯\_(ツ)_/¯.
[4/14/2020, 3:53:06 AM] []: ¯\_(ツ)_/¯
[4/14/2020, 4:11:58 AM] [ledongthuc]: ¯\_(ツ)_/¯
[4/14/2020, 4:14:13 AM] [tay vịn của anh bán chuối - cty A tìm FE]: ¯\_(ツ)_/¯
[4/14/2020, 4:27:42 AM] []: ¯\_(ツ)_/¯
[4/14/2020, 4:27:46 AM] []: a /shrug
[4/14/2020, 4:28:15 AM] [anh bán chuối]: a ¯\_(ツ)_/¯
[4/14/2020, 4:34:15 AM] [chua dc luong thien]: ¯\_(ツ)_/¯
[4/14/2020, 4:55:36 AM] [ko luong thien]: #til <https://developer.mozilla.org/en-US/docs/Web/CSS/caret-color>
[4/14/2020, 5:47:54 AM] [tuan]: ¯\_(ツ)_/¯
[4/14/2020, 6:25:54 AM] [SFzxc]: ¯\_(ツ)_/¯
[4/14/2020, 7:59:32 AM] [minh]: @nakhoa17 fixed: <https://github.com/monodyle/typings-app/issues/3> mời anh vào test thử :vayvay:
[4/14/2020, 8:08:14 AM] [nakhoa]: nai xừ work rồi =)))
[4/14/2020, 8:12:18 AM] [nakhoa]: sáng fix thử, đổi onChange thành onKeyUp nó cũng work, mà ko ra cái WPM mà trước h chưa code react cái thôi =)))
[4/14/2020, 8:15:28 AM] [minh]: Cái `onKeyUp` thực ra là cách fix dễ nhất rồi :))) nhưng mà thời gian từ lúc gõ tới lúc xử lý xong nó bị dài hơi nên khi gõ sẽ có cảm giác cái input nó thay đổi chậm rõ rệt so với tốc độ bình thường nên em không xài tới. Cái `onChange` cũng chậm hơn `onKeyDown` 1 xíu nhưng không có cảm giác nhiều nên dùng ok nhất
[4/14/2020, 3:10:25 PM] [huy]: #til `set virtualedit=all` in vim
<https://keleshev.com/my-book-writing-setup/virtualedit.gif>
[4/17/2020, 6:52:27 AM] [huy]: #til CEO gojek la <https://en.wikipedia.org/wiki/Ministry_of_Education_and_Culture_(Indonesia)|minister of education and culture of the Republic of Indonesia> …
[4/17/2020, 9:09:06 AM] [huy]: bác này còn là bạn học cùng lớp của hai bác founder Grab nữa. cùng bàn về idea gọi xe khi còn đi học rồi tách ra làm thành 2 hướng
[4/18/2020, 9:53:26 PM] [typescriptpher]: #til <https://en.wikipedia.org/wiki/Hikikomori>
[4/18/2020, 10:39:04 PM] [hasagi]: Anthony Ran
[4/18/2020, 10:39:11 PM] [hasagi]: *Tan
[4/18/2020, 10:39:29 PM] [hasagi]: Và Nadiem
[4/18/2020, 10:40:02 PM] [hasagi]: Plot twist 2 bác này cũng là bạn cto cty mình
[4/18/2020, 10:40:07 PM] [hasagi]: Nhưng 2 số phận :(
[4/18/2020, 10:44:06 PM] [huy]: queo, vay la nguyen cai lo'p do', tot nghiep xong ra truong mo cty lam app goi xe
[4/18/2020, 10:44:07 PM] [huy]: :notbad:
[4/22/2020, 11:21:29 AM] [huy]: #til How to make a div going fullscreen <https://developer.mozilla.org/en-US/docs/Web/API/Element/requestFullscreen>
[4/22/2020, 8:13:16 PM] [thai]: Mấy ông này ngoài giỏi ra, còn có nền tảng gia đình mạnh nữa.1 người là con nhà siêu giàu, mẹ gọi bạn bè tới “hỗ trợ” con vài triệu đô khởi nghiệp. 1 người thì ông nội là khai quốc công thần
[4/24/2020, 12:52:17 AM] [tuan]: #til `sudo dd if=/dev/urandom of=/dev/mem` :troll:
[4/24/2020, 12:53:04 AM] [tuan]: @unrealhoang <@U0GP83HM3> <@U0GE29BN3>
[4/24/2020, 1:21:36 AM] [noob]: tự hủy à :shake:
[4/24/2020, 1:37:47 AM] [dat]: …
[4/24/2020, 1:43:17 AM] [tuan]: `kaboooom`
[4/25/2020, 4:56:27 AM] []: #til <https://mobyproject.org>
[4/26/2020, 8:51:29 AM] [unrealhoang]: #til <https://en.m.wikipedia.org/wiki/Squircle|https://en.m.wikipedia.org/wiki/Squircle> vs rounded square
[4/26/2020, 4:47:16 PM] [ko luong thien]: This is pretty common in icon set, which each provider has their own function (the Samsung's one produces more "curveness" than Apple's)
[4/26/2020, 4:47:32 PM] [ko luong thien]: Google also has one, but it's the exact squircle afaik
[4/26/2020, 5:43:00 PM] [unrealhoang]: Squircle is much more easier to render
[4/27/2020, 12:52:10 AM] [Heo Con]: #til <https://en.wikipedia.org/wiki/Public_opinion_brigades>
[4/27/2020, 1:03:48 AM] []: #til Time is the only real currency we have <https://blog.theboringtech.io/2020/04/16/time_is_the_real_currency.html>
[4/27/2020, 2:30:28 AM] [Tu Huynh]: Great post :adore:
[4/28/2020, 7:35:30 AM] [blcsntb]: #til <https://www.youtube.com/watch?v=SzJ46YA_RaA>
[4/28/2020, 9:11:56 AM] []: <https://david-peter.de/cube-composer/>
[4/29/2020, 4:03:07 AM] [Jun]: #til .env Don’t add comment right after the value of variable
```KEY=value # this is value ```
[4/30/2020, 6:04:38 AM] [// english-ignore]: #til phantom pain
&gt; Phantom pain is a perception that an individual experiences relating to a limb or an organ that is not physically part of the body.
[5/3/2020, 12:04:54 AM] [ko luong thien]: #til
```type Foo = &lt;T&gt;(value: T) =&gt; string; // type of generic function
type Foo&lt;T&gt; = (value: T) =&gt; string; // generic type of function```
[5/3/2020, 7:07:15 AM] [Cậu Làm Vườn]: #til cây Ngô đồng không có bà con gì với cây ngô và cũng không dính dán gì tới cái đồng...
[5/3/2020, 7:11:52 AM] [minh]: fyi: Cây ngô đồng thuộc họ cẩm quỳ (mấy cái hoa dâm bụt) :troll:
[5/3/2020, 7:25:01 AM] []: Nhắc tới làm thèm nước râu ngô :omg:
[5/3/2020, 7:53:30 AM] [Cậu Làm Vườn]: Tự nhiên nhắc tới cũng thèm quá, Trời đang hanh nóng. :omg:
[5/3/2020, 8:00:11 AM] [// english-ignore]: Cho tấm hình nào
[5/3/2020, 3:24:21 PM] []: #til có thể viết proof được cho runtime complexity <https://www.twanvl.nl/blog/agda/sorting>
[5/3/2020, 3:35:47 PM] []: ```Finally I would like to note that you can use something like _in-time_ to show that head ∘ insertion-sort takes linear time, see "Lightweight Semiformal Time Complexity Analysis for Purely Functional Data Structures" (<http://www.cse.chalmers.se/~nad/publications/danielsson-popl2008.html>). ```
[5/3/2020, 3:35:49 PM] []: :omg:
[5/3/2020, 4:30:11 PM] [huy]: mới mua thêm giống rau má về trồng
[5/4/2020, 3:08:46 AM] []: :+1: đề nghị làm một buổi seminar
[5/4/2020, 5:44:37 AM] [ko luong thien]: #til <https://en.wikipedia.org/wiki/String_interning>
[5/4/2020, 6:57:35 PM] []: mới coi qua agda, để hiểu rõ tí đã :omg:
[5/5/2020, 12:45:08 AM] []: #til datediff() in postgresql <http://www.sqlines.com/postgresql/how-to/datediff>
[5/5/2020, 11:29:54 PM] [tuan]: #til brief history of unix
<http://tldp.org/HOWTO/Secure-Programs-HOWTO/history.html>
[5/6/2020, 12:47:56 AM] []: #til hash join <https://use-the-index-luke.com/sql/join/hash-join-partial-objects>
[5/6/2020, 11:29:48 PM] [huynh.cam]: #til <https://www.cloudflare.com/products/registrar/>
[5/6/2020, 11:30:17 PM] [huynh.cam]: @snacky đã transfer hết domain chưa?
[5/6/2020, 11:37:35 PM] [huy]: nhiều domain ở nhiều service khác nhau quá
[5/6/2020, 11:37:40 PM] [huy]: giờ ko biết cái nào ra cái nào luôn
[5/6/2020, 11:37:40 PM] [huy]: =))
[5/6/2020, 11:39:23 PM] [huynh.cam]: LOL
[5/6/2020, 11:40:47 PM] [huynh.cam]: cơ mà CF wholesale cái mới lòi ra tụi registrar chịu lỗ cho một số LTDs
[5/6/2020, 11:41:19 PM] [huynh.cam]: như `.io` bọn namecheap renew $35 mà wholesale price $45 rồi
[5/6/2020, 11:41:30 PM] [huy]: :thinkhard:
[5/6/2020, 11:43:34 PM] [minh.nguyen]: chuyển qua phải đóng tiền thêm 1 năm :thinkold:
[5/7/2020, 12:09:51 AM] []: Em xài đó giờ
[5/7/2020, 12:31:17 AM] [ko luong thien]: ngon thank @hqc <@U356M3XT7>
[5/7/2020, 12:31:22 AM] [ko luong thien]: highly regulated?
[5/7/2020, 12:33:00 AM] [ko luong thien]: ma sao cc em anh @ledongthuc
[5/7/2020, 12:33:40 AM] [Cậu Làm Vườn]: Look again dude :vayvay:
[5/7/2020, 12:34:30 AM] [Cậu Làm Vườn]: typo.fail mua chưa? Mua thì thủ tục thế nào? Thấy highly-regulated nên tò mò thôi.
[5/7/2020, 12:34:57 AM] [ko luong thien]: mua lau roi, i la cai do chua lam ma sao moi nguoi biet :shake:
[5/7/2020, 12:44:05 AM] [Cậu Làm Vườn]: Ủa mà cái này là mua chỗ khác rồi transfer qua à, không thấy chỗ mua mới
[5/7/2020, 12:53:14 AM] [ko luong thien]: cai fail la t mua o zeit day
[5/7/2020, 10:26:26 PM] [ko luong thien]: #til wheel vs scroll event <https://developer.mozilla.org/en-US/docs/Web/API/Element/wheel_event>
[5/8/2020, 12:53:17 AM] []: “refucktor”: when u update your code and tests at the same time, it’s not refactor it’s refucktor
<https://vimeo.com/108441214>
[5/9/2020, 7:50:42 AM] [Cậu Làm Vườn]: #til khi trộn đất trồng, đặc biệt đối với cây cần dinh dưỡng cao, đừng trộn vỏ trấu, xơ dừa chưa ủ mục hay các loại vỏ khác quá tay. Lí do là quá trình phân hủy những thành phần hữu cơ có hàm lượng carbon cao sẽ cần rất nhiều nitrogen. Chỉ đến khi nó được phân hủy hết thì lượng nitrogen đó mới được release ra cho cây hấp thụ -&gt; Gây nitrogen deficiency cho cây trong giai đoạn đầu. Lesson learnt the hard way...
[5/9/2020, 7:51:19 AM] [Cậu Làm Vườn]: cc @vanhtuan0409
[5/9/2020, 7:52:55 AM] [Cậu Làm Vườn]: Lỡ tay trộn rồi giờ phải bón thêm phân bổ sung :shake:
[5/9/2020, 7:54:33 AM] [Cậu Làm Vườn]: Dấu hiện dễ nhận biết là cây tự dưng vàng lá, lá mới ngày càng nhỏ đi và chậm lớn.
[5/9/2020, 8:00:43 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: bố mẹ mình ở quê, bón phân chuồng (gà hoặc bò) với vỏ cafe đều phải ủ rất lâu, có khi vài tháng - nửa năm để phân mục rồi mới đem bón
[5/9/2020, 8:02:07 AM] [Cậu Làm Vườn]: Ừa đó :thinkcry:. Noob mistake.
For reference I use ~50% rice hull for extra drainage and normal potting soil. If it were rich compost instead, it would not likely not be a problem nutrient-wise.
[5/9/2020, 8:06:35 AM] [Cậu Làm Vườn]: cc luôn các bạn hội làm vườn
@kcj.pop.com_rbvn <@U0GECN1NH>
[5/9/2020, 8:40:49 AM] [tuan]: cái này lúc em mua phân người bán hay nhắc mà. Người ta gọi là cháy cây đó. Bón phân ko đúng cách là gây cháy cây
[5/9/2020, 8:41:35 AM] [tuan]: mới mang 1 mớ vỏ cafe đã ủ ở nhà lên chuẩn bị bón :vayvay:
[5/9/2020, 8:54:57 AM] [Cậu Làm Vườn]: Không phải nutrient burn mà là nó thiếu dinh dưỡng do mấy thành phân vỏ cây chưa ủ (trường hợp của em là vỏ trấu tươi, để thoát nước) quá trình phân hủy nó hút hết nitrogen trong đất :thinkcry:. Nên hoặc là giảm carbon source lại hoặc phải bón nitrogen thêm.
[5/9/2020, 8:59:52 AM] [tuan]: uhm đúng rồi :smile: trước đó anh cũng ko hiểu nguyên lý. Nhưng dân dã thì mọi người hay nói là cháy cây (hiện tượng là vàng lá + lá nhỏ đi), đi mua bị nhắc hoài
[5/9/2020, 9:01:17 AM] [Cậu Làm Vườn]: Em nghĩ bình thường người ta gọi cháy cây là chỉ nutrient burn á. Bón dư dinh dưỡng nó cháy lá. Còn case này là deficiency.
[5/9/2020, 9:02:00 AM] [tuan]: ùa thoi rút kinh nghiệm :sosad: xót cây vãi
[5/9/2020, 9:32:32 AM] [tuan]: @snacky quy hoạch giúp em 1 group trồng rau đi anh :’(
[5/9/2020, 9:33:03 AM] [huy]: quân số ít quá :))
[5/10/2020, 1:40:55 AM] [// english-ignore]: đề nghị quy hoạch #finance-cafe thành #hobbies hay gì đi, sở thích lướt sóng, trồng cây, chăn rau etc.
[5/12/2020, 6:03:40 AM] []: <https://www.microsoft.com/en-us/p/windows-terminal-preview/9n0dx20hk701>
[5/12/2020, 8:01:49 AM] [typescriptpher]: #til hai vị thần phù hộ gia đình ấm no, bảo vệ hạnh phúc của các cặp vợ chồng là hai thằng đàn ông <https://www.facebook.com/cholondowntown/posts/2675231456054087>
[5/12/2020, 7:36:14 PM] []: &gt; Câu chuyện trên được người dân truyền tai để nói về lòng thuỷ chung của 2 vị thần này.
[5/12/2020, 7:36:31 PM] []: Da heck, 2 ông thần bỏ vợ về sống chung với nhau là thủy chung?!
[5/12/2020, 7:48:53 PM] [tuan]: chỉ có đàn ông mới đem lại hạnh phúc cho nhau :roflrofl:
[5/13/2020, 9:16:31 AM] [giangnh]: #til <https://www.docker.com/blog/docker-desktop-wsl-2-best-practices/>
[5/13/2020, 8:27:01 PM] [n]: #til Some hosts need setting SNIs by `SSL_set_tlsext_host_name` . Otherwise. `SSL_get_peer_certificate` won’t receive the server certificate properly. Ref: <https://quuxplusone.github.io/blog/2020/01/27/openssl-part-4/#the-sni-field>
[5/14/2020, 12:37:36 AM] [ko luong thien]: #til <https://developers.google.com/web/tools/workbox>
[5/14/2020, 1:25:13 AM] [ko luong thien]: cty mình bắt buộc cái này..
[5/14/2020, 2:07:43 AM] [Tu Huynh]: cái này có ý nghĩa gì vậy a :think:
[5/14/2020, 2:11:23 AM] [Tu Huynh]: commit do Github tạo thì sẽ có cái này hả
[5/14/2020, 2:16:40 AM] [tuan]: nó verify commit này là chính chủ :okay: ko có chuyện em commit xong bảo đây là commit của anh :okay:
[5/14/2020, 2:20:19 AM] [hieu.huynh]: :cannabis:
[5/14/2020, 2:20:28 AM] [hieu.huynh]: …good…to..know….
[5/14/2020, 2:20:30 AM] [hieu.huynh]: hmmm
[5/14/2020, 2:20:31 AM] [hieu.huynh]: :okay:
[5/14/2020, 2:20:32 AM] [hieu.huynh]: fml
[5/14/2020, 2:27:44 AM] [Tu Huynh]: à, mặc định là cái author của git commit nếu ko sign có thể sửa thành cái gì cũng đc :okay:
[5/14/2020, 2:28:49 AM] [Tu Huynh]: mình tạo private key xong rồi đăng kí lên github hả a, hay nó lấy luôn cái SSH key đã integrated nếu có :think:
[5/14/2020, 2:29:52 AM] [tuan]: quăng public key lên github. Còn private key em giữ ở máy em mà sign chứ :shake:
[5/14/2020, 2:32:26 AM] [Tu Huynh]: à nhầm, quăng publickey :vayvay:
[5/14/2020, 3:20:22 AM] [Tu Huynh]: #til
```The reason why you should NOT use ssh for signing commits is the one of the common rules of cryptography: You should not use the same keys for different applications/use cases.
In SSH you use a key for authentication, but that is something different then the signing your commits. For this, GPG is much more suited as it is already widely used for signing emails, files and so on.```
<https://stackoverflow.com/questions/45119932/why-does-git-sign-with-gpg-keys-rather-than-using-ssh-keys>
[5/14/2020, 4:43:37 AM] []: always sign your commit, or 1 day your colleague going to commit :poop: under your name :))
[5/14/2020, 4:43:39 AM] []: <https://news.ycombinator.com/item?id=10005577>
[5/14/2020, 4:46:32 AM] []: “Git comes with a nice pull-request generation module, but github
instead decided to replace it with their own totally inferior version.
As a result, I consider github useless for these kinds of things. It’s
fine for _hosting_, but the pull requests and the online commit
editing, are just pure garbage.” - Linus
haha, telling Github is garbage on their own platform. What a guy
[5/14/2020, 6:49:37 AM] [hieu.huynh]: Linus thì chí phèo vkl :doubt: gì cũng chửi được.....
[5/14/2020, 11:57:13 PM] [ko luong thien]: #til <https://webkit.org/blog/68/understanding-html-xml-and-xhtml/>
[5/15/2020, 12:55:46 AM] [ko luong thien]: #til <https://developer.mozilla.org/en-US/docs/Web/API/XSLTProcessor>
[5/15/2020, 12:55:55 AM] [ko luong thien]: #til <https://developer.mozilla.org/en-US/docs/Web/API/Document/importNode>
[5/15/2020, 1:06:40 AM] [Tu Huynh]: #til <https://cs.stackexchange.com/questions/44305/why-are-functional-languages-turing-complete>
Any functional code you write is converted to it’s Turing equivalent - we don’t have a real machine built on Church Calculus except <https://en.wikipedia.org/wiki/Lisp_machine|Lisp machine> :okay:
[5/15/2020, 9:26:28 PM] [giba]: #til <https://heartbeat.fritz.ai/diving-into-data-structures-in-swift-arrays-4ffd516bde9b>
array’s size in Swift increases exponentially. It has a name to make it fancy: _geometric growth pattern._
[5/17/2020, 1:19:25 AM] [anh bán chuối]: <https://stackoverflow.com/a/9083>
[5/17/2020, 1:19:33 AM] [anh bán chuối]: #til
```For BSD or GNU grep you can use -B num to set how many lines before the match and -A num for the number of lines after the match.
grep -B 3 -A 2 foo README.txt```
[5/17/2020, 8:12:05 AM] [Tu Huynh]: <https://muldoon.cloud/programming/2020/04/17/programming-rules-thumb.html>
[5/17/2020, 7:51:11 PM] [FULLCLEARONSTAGE]: #til SoftBank means Bank of Software
[5/17/2020, 11:53:37 PM] [huy]: #til Khi xài bàn phím rời trên ipad, muốn đổi ngôn ngữ thì gõ: Shift + Ctrl + Space
[5/18/2020, 12:40:32 AM] []: hình như ctrl space cũng đc mà nhỉ :thinkhard:
[5/18/2020, 9:39:19 PM] []: <https://getpocket.com/explore/item/the-definitive-superfood-ranking>
[5/19/2020, 12:25:49 AM] [huy]: #til Các thuộc tính HTML `contentEditable` và `designMode` được phát triển và giới thiệu bởi Microsoft lần đầu tiên trên IE 5.5, nhưng không cung cấp bất cứ thông tin, tài liệu gì về API của nó. Về sau, các browser khác phải reverse engineer các API này và implement lại. <https://blog.whatwg.org/the-road-to-html-5-contenteditable>
[5/19/2020, 4:20:38 AM] [ZeroX]: sorting algo?
[5/19/2020, 4:38:02 AM] [unrealhoang]: maybe sorting visualization
[5/19/2020, 4:48:44 AM] [ko luong thien]: quick sort
[5/19/2020, 4:55:26 AM] []: shameless plug :"&gt; <https://imgur.com/gallery/VQxl1ol>
[5/19/2020, 5:09:19 AM] [unrealhoang]: :adore:
[5/19/2020, 9:57:56 PM] []: #til <https://smallstep.com/blog/ssh-agent-explained/>
[5/21/2020, 3:50:49 PM] [huy]: #til componentDidUpdate in React Hook
```const mounted = useRef();
useEffect(() =&gt; {
if (!mounted.current) {
mounted.current = true;
} else {
// do componentDidUpate logic
}
});```
[5/22/2020, 12:37:45 AM] [tay vịn của anh bán chuối - cty A tìm FE]: phải không vậy
[5/22/2020, 12:37:57 AM] [tay vịn của anh bán chuối - cty A tìm FE]: có nhầm với didMount không đó ba
[5/22/2020, 12:39:51 AM] [huy]: didupdate
[5/22/2020, 12:46:54 AM] [Charlie Brown]: ACM Professional Membership (Basic Online Membership Package — $25 U.S. Dollars)
1. Benefit: *online books from O'Reilly*® ... (Detail: <https://www.acm.org/membership/membership-benefits>)
2. Register: <https://services.acm.org/public/qj/proflevel/proflevel_control.cfm?level=3&amp;country=Viet%20Nam&amp;form_type=Professional&amp;promo=LEVEL>
[5/22/2020, 12:52:04 AM] [huynh.cam]: TIL <https://giaoducthoidai.vn/can-phan-biet-van-van-vv-cham-lung--3838491.html>
[5/22/2020, 1:18:06 AM] [ko luong thien]: side note: it's "…", not "..."
[5/22/2020, 4:59:20 PM] [Thanh Pham]: TIL a few countries have reserved phone number ranges for fictional use <https://softwareengineering.stackexchange.com/a/376537>
[5/22/2020, 9:42:12 PM] [minh]: #til NXNSAttack - the flaw hinges on the DNS delegation mechanism to force DNS resolvers to generate more DNS queries to authoritative servers of attacker's choice, potentially causing a botnet-scale disruption to online services.
<http://www.nxnsattack.com/>
[5/23/2020, 6:17:43 PM] []: không có tiền đọc bài <https://www.wsj.com/articles/the-healing-power-of-proper-breathing-11590098696>
nên tìm ra
<https://github.com/iamadamdev/bypass-paywalls-chrome>
[5/23/2020, 6:20:55 PM] []: yeah just found out about this today
[5/23/2020, 6:21:26 PM] []: iOS simulator is pre populated with some contacts with the phone numbers of : 555-xxx-xxxx
[5/23/2020, 6:21:54 PM] []: it drove me nuts that libphonenumber couldn't parse it
[5/23/2020, 6:22:15 PM] []: then I google 555 phone number, then realized it's reserved for fictional use
[5/26/2020, 2:11:25 AM] [ko luong thien]: #til cronjob syntax <https://we-build-vn.slack.com/archives/C0J7M3P8V/p1590483426024200>
[5/26/2020, 4:05:33 AM] [ko luong thien]: #til bày này viết hay quá <https://en.wikipedia.org/wiki/Ray_tracing_(graphics)>
[5/26/2020, 4:10:09 AM] [noob]: bữa giờ anh đọc wiki khá nhiều, lười đọc ietf quá, toàn chữ :sosad:
[5/26/2020, 4:11:10 AM] [ko luong thien]: <https://en.wikipedia.org/wiki/Polygon_mesh>
[5/26/2020, 4:11:16 AM] [ko luong thien]: nhiều bài hay quá anh ơi :&lt;
[5/26/2020, 5:25:30 AM] [dat]: coi demo unreal engine trên ps5 r đi đọc à
[5/26/2020, 5:36:01 AM] [ko luong thien]: không coi meme rtx
[5/26/2020, 6:34:30 AM] []: Nhìn qua cái hình lại liên tưởng ngay đến cái Phong shading của ông người Việt. Cơ mà ko có background về cái này nên ko biết shading với tracing là gì :slightly_smiling_face:
[5/26/2020, 8:02:46 AM] [dong]: #til
ci command :beauty:
<https://www.youtube.com/watch?v=E7NBhSsZouc>
[5/26/2020, 9:09:57 PM] [giangnh]: #til <https://speed.cloudflare.com/>
[5/26/2020, 9:18:00 PM] []: wow, cái này cung cấp nhiều metrics thấy hay ghê. Thanks
[5/27/2020, 12:42:49 AM] [tucq88]: #til We Build giờ vẫn mạnh phết
[5/27/2020, 2:14:28 AM] [Heo Con]: More Info: <https://blog.cloudflare.com/test-your-home-network-performance/>
[5/27/2020, 10:22:58 PM] [Tu Huynh]: #til
Certificates and public key infrastructure (PKI) are fk hard:okay:
<https://smallstep.com/blog/everything-pki/>
[5/27/2020, 10:24:14 PM] [tuan]: có vài cái principle thôi mà :vayvay: nắm dc rồi sau này đọc follow cũng dễ hiểu. Implêmnt thì khó thôi
[5/27/2020, 11:14:42 PM] [giangnh]: nhớ hồi đó học cái này mà chả hiểu mô tê gì
[5/27/2020, 11:29:20 PM] [Tu Huynh]: ^ same :okay:
[5/28/2020, 3:48:02 AM] [Heo Con]: Cái gì đụng đến Crypto lại làm mình nhức đầu. Note lại nào rảnh đọc .:pepeandao:
[5/28/2020, 10:23:38 AM] []: <https://youtu.be/6avJHaC3C2U|https://youtu.be/6avJHaC3C2U> this is definitely up there with Simplicity Matters by Rich Hickey. my 2nd favorite tech talk so far
[5/28/2020, 10:52:55 AM] []: <https://github.com/mame/quine-relay|https://github.com/mame/quine-relay> mind blown
[5/28/2020, 7:29:34 PM] []: What's the first then?
[5/28/2020, 7:39:12 PM] [whyn4]: <https://frontendchecklist.io/>
[5/28/2020, 7:49:00 PM] []: Simplicity matters
[5/28/2020, 8:05:02 PM] []: thank, bookmarked
[5/29/2020, 11:44:47 PM] [giangnh]: #til chaos engineering
[5/30/2020, 1:25:38 AM] [ledongthuc]: #til read csv file
```cut -f &lt;column_number&gt; -d "," &lt;file&gt;```
[5/30/2020, 1:28:58 AM] [minh]: learn R
[5/30/2020, 1:34:23 AM] [huy]: learn Excel
[5/30/2020, 1:34:47 AM] [ledongthuc]: :yaomin:
[5/30/2020, 11:38:39 PM] [giba]: #til I suck at math
<http://www.giaithuatlaptrinh.com/?p=985&amp;>
[5/31/2020, 12:17:58 AM] [sai]: cũng có follow trang này, mà thấy hardcore quá nên lâu rồi ko vô :panic:
[5/31/2020, 9:30:31 AM] [Tu Huynh]: #til <https://medium.com/python-features/pythons-gil-a-hurdle-to-multithreaded-program-d04ad9c1a63>
I don’t know about you but for me it was a shocker :shake:
Python threads can’t run in parallel on multiple CPU cores because of the global interpreter lock (GIL)
[5/31/2020, 9:55:35 AM] [unrealhoang]: same for ruby
[5/31/2020, 9:59:56 AM] [minh.nguyen]: Actually, depend on the implementation.
[5/31/2020, 10:57:20 AM] [Tu Huynh]: ~thread~process per request :shake:
[5/31/2020, 10:16:37 PM] [dat]: luc moi biet cung shocked af
[6/1/2020, 1:47:05 AM] [ko luong thien]: #til
```const refA = useLibraryA(...);
const refB = useLibraryB(...);
const ref = (node) =&gt; {
refA(node);
refB(node);
};
return &lt;div ref={ref} /&gt;```
[6/1/2020, 1:53:01 AM] [Tem]: :wat: don’t get what you mean
Use 2 refs?
[6/1/2020, 1:53:18 AM] [ko luong thien]: anh paste bên #frontend á
[6/1/2020, 1:53:22 AM] [ko luong thien]: qua bển tiếp nào
[6/1/2020, 1:53:30 AM] [Tem]: à há :v
[6/1/2020, 1:53:51 AM] [Tem]: ờ, vậy e hiểu đúng mà :lol:
[6/1/2020, 9:06:14 AM] [typescriptpher]: <https://en.wikipedia.org/wiki/Bushcraft>
[6/1/2020, 1:38:21 PM] [trexnix]: giờ mới biết :omg:
[6/1/2020, 1:38:35 PM] [trexnix]: tuỳ vào implementation thiệt, CPython (default implementation) thì bị nhưng Jython thì không <https://wiki.python.org/jython/WhyJython>
[6/1/2020, 5:03:14 PM] [unrealhoang]: lý thuyết là tùy vào implementation, nhưng thực tế là ecosystem sẽ viết library dựa trên assumption của main implementation (MRI, CPython) regarding thread-safety
[6/1/2020, 5:04:26 PM] [unrealhoang]: dẫn tới việc đa số lib cũng không an toàn khi chạy true parallel
[6/1/2020, 8:14:30 PM] [giangnh]: #til <https://www.youtube.com/watch?v=b2F-DItXtZs>
[6/1/2020, 9:26:33 PM] [trexnix]: interesting
[6/1/2020, 9:44:00 PM] [trexnix]: &gt; dẫn tới việc đa số lib cũng không an toàn khi chạy true parallel
Đây là vấn đề về thread-safety và của người viết libs, chớ implementation của language có support true parallel hay hông thì nó có liên quan gì hông ta :thinking_face: Ý em là nếu đã viết multi-threaded program rồi thì thready-safety luôn là 1 vấn đề bất kể underlying implementation của language có support true parallel hay không.
[6/1/2020, 9:44:28 PM] [unrealhoang]: À
[6/1/2020, 9:44:48 PM] [unrealhoang]: Vì với GIL
[6/1/2020, 9:45:32 PM] [unrealhoang]: Cái thread safety nó dễ đúng
[6/1/2020, 9:46:48 PM] [unrealhoang]: Or accidentally đúng
[6/1/2020, 9:52:38 PM] [trexnix]: à ý anh là GIL dễ làm người ta tưởng code của họ đã thread-safety?
[6/1/2020, 11:51:07 PM] [unrealhoang]: Yep
[6/1/2020, 11:52:05 PM] [unrealhoang]: Ngày xưa nhớ có gặp lib ruby works on MRI not on JRuby
[6/2/2020, 1:07:19 AM] [trexnix]: cool anh :+1:
[6/2/2020, 1:09:14 AM] [trexnix]: nãy tự hỏi mấy webserver bên Ruby làm sao nó chạy highly concurrent được
[6/2/2020, 1:09:26 AM] [trexnix]: xem <https://github.com/puma/puma|Puma> thì thấy nó
nói rõ:
[6/2/2020, 1:23:53 AM] [Tu Huynh]: cái đoạn *improve MRI* đó làm ntn nhỉ
[6/2/2020, 10:10:23 AM] [nakhoa]: #til <http://whyyoushouldusemongodb.com/>
[6/2/2020, 10:11:15 AM] [xuan]: @snacky
[6/2/2020, 10:11:47 AM] [huy]: whatever work will work
[6/2/2020, 4:39:39 PM] [unrealhoang]: @snacky xài mông db à
[6/2/2020, 4:41:03 PM] [huy]: xài parser, parser xài mông
[6/2/2020, 7:43:59 PM] [ko luong thien]: parser là gì thế
[6/2/2020, 8:45:18 PM] [minh]: #til preventing bad commits
```cd .git/hooks
cp pre-commit.sample pre-commit # for older git version: chmod +x pre-commit
```
fyi: `git help hooks`
[6/2/2020, 8:48:42 PM] [usbc]: mongo lần đầu e tiêp xúc thì thích lắm, lưu cái quái gì cũng được, làm 1 thơi gian rồi thấy … :thinkcry:
[6/2/2020, 8:51:06 PM] []: not only that, but you can run code formatter in pre-commit hook
[6/2/2020, 8:51:35 PM] []: ```#!/bin/bash
git diff --diff-filter=d --staged --name-only | grep -e '\.swift$' | while read line; do
swiftformat "${line}";
git add "$line";
done```
for instance
[6/2/2020, 8:51:59 PM] [huy]: parse. ghi dư chữ r
[6/2/2020, 8:54:12 PM] [minh]: #til
[6/2/2020, 9:04:20 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: just install <https://pre-commit.com/>, everything is done :yaomin:
[6/2/2020, 9:26:09 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: <https://github.com/Arkweid/lefthook/wiki/Comparison-with-other-solutions>
another solutions here
[6/2/2020, 9:26:29 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: pre-commit, overcommit, lefthook …
[6/2/2020, 10:38:00 PM] []: Em ghét cực mấy cái này
[6/2/2020, 10:38:09 PM] []: Disable hết
[6/2/2020, 10:38:13 PM] []: :omg:
[6/2/2020, 11:27:52 PM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :smile: me too, lúc đầu thì thấy hay, sau càng thấy bực mình
[6/3/2020, 1:20:11 AM] [trexnix]: details implementation của GIL thì mình hông rõ, chắc đọc code mới biết. Ở high level thì một thread đang chạy mà gặp blocking IO thì không có lý do gì mà phải chờ nên nó sẽ nhả cái GIL lock và để thread khác có cơ hội được dùng CPU, nên có thể coi cái việc chờ IO kia đang chạy song song.
[6/3/2020, 2:16:26 AM] [tuan]: cho tới 1 hôm cháy nhà, bấm commit mãi ko dc. Thế là mất code :trollface:
[6/3/2020, 2:25:02 AM] [minh]: :notlikethis:
[6/3/2020, 2:25:07 AM] [minh]: Nghe sợ thế
[6/3/2020, 2:39:15 AM] []: commit mà chờ chạy test, lint, blah blah blah mất 15 phút
[6/3/2020, 2:39:20 AM] []: thì ocnf làm ăn gì nữa
[6/3/2020, 3:13:46 AM] []: mấy cái lint test thì nên nằm trên CI/CD hơn
[6/3/2020, 3:13:59 AM] []: keep pre-commit hook neat and fast, mình chỉ dùng nó để run formatter
[6/4/2020, 2:12:59 AM] [minh.nguyen]: #til Great introduction to parallel computing: <https://computing.llnl.gov/tutorials/parallel_comp/|https://computing.llnl.gov/tutorials/parallel_comp/>. Well-explained, pratical and tons of real-life examples
[6/4/2020, 2:21:24 PM] [dangthaison91]: Tiếng Việt là đi Bú :smile:
[6/6/2020, 6:09:55 AM] [Cậu Làm Vườn]: It'ssssss Black Bean Aphid. I'ma nuke them!
[6/6/2020, 7:24:32 AM] [giangnh]: #til đa cấp 4.0 <https://www.facebook.com/tintucvtv24/videos/278202216664207/?vh=e|https://www.facebook.com/tintucvtv24/videos/278202216664207/?vh=e>
[6/6/2020, 7:51:20 AM] [xuan]: mạng 5G =))
[6/6/2020, 8:10:01 AM] [huy]: burn them?
[6/6/2020, 6:11:38 PM] [Cậu Làm Vườn]: Go nuclear!
[6/8/2020, 2:26:41 AM] [noob]: #til <https://en.wikipedia.org/wiki/ANSI_escape_code>
[6/9/2020, 12:05:45 AM] [thành]: #til set -ex
<https://gist.github.com/mohanpedala/1e2ff5661761d3abd0385e8223e16425>
[6/9/2020, 12:11:10 AM] [meowwwwwwwwwwwwwwww]: `set -euxo pipefail`
[6/9/2020, 12:14:32 AM] [meowwwwwwwwwwwwwwww]: <https://vaneyckt.io/posts/safer_bash_scripts_with_set_euxo_pipefail/>
[6/9/2020, 12:27:42 AM] [thành]: interesting
[6/9/2020, 1:10:31 AM] [noob]: đang dùng `-e` <https://github.com/MQuy/mos/blob/master/src/build.sh#L2> để update thêm mấy cái option còn lại :+1:
[6/10/2020, 1:11:14 AM] [ko luong thien]: #til tks @triet
<https://web.stanford.edu/class/ee384m/Handouts/HowtoReadPaper.pdf>
<https://viblo.asia/p/mot-so-luu-y-khi-doc-research-paper-cho-nguoi-moi-naQZR910Kvx>
[6/10/2020, 7:12:22 AM] [ko luong thien]: #til I've always missed this since leaving Mac OS <https://en.wikipedia.org/wiki/Compose_key#Common_compose_combinations>
[6/10/2020, 7:22:16 AM] [ko luong thien]: #til <https://en.wikipedia.org/wiki/Combining_character>
[6/10/2020, 7:22:36 AM] [ko luong thien]: vụ thiết kế font hôm bữa mình nói nè @nguyenhuedang
[6/10/2020, 4:13:16 PM] [Thanh Pham]: #til cans of Diet Pepsi float while cans of regular Pepsi sink
<https://www.haydenplanetarium.org/tyson/commentary/2020-06-03-reflections-on-color-of-my-skin.php>
[6/10/2020, 4:20:38 PM] [huy]: a better explanation <https://www.mentalfloss.com/article/93383/why-do-cans-diet-coke-float-while-regular-coke-sinks#:~:text=The%20can%20of%20Diet%20Coke,less)%2C%20so%20it%20floats>.
[6/10/2020, 6:13:54 PM] []: Đúng là phải vậy nếu k chỉnh một dấu là chỉnh quá trời chữ
[6/11/2020, 10:23:42 PM] [Quan Nguyen]: #til the rule of three <https://andrewbrookins.com/technology/the-rule-of-three/|https://andrewbrookins.com/technology/the-rule-of-three/>
[6/12/2020, 6:13:57 AM] [huy]: #til <https://cacm.acm.org/magazines/2020/6/245158-commit-to-memory/fulltext> chiplet, 7nm vs 14nm chip, TSMC
[6/12/2020, 8:04:27 AM] [alias Trung.Le, as tle]: #til ARM might be next big transition in computing. Once Apple has made the move, many developers would embrace ARM as the development platform.
[6/12/2020, 8:24:47 AM] [tuan]: Arm có gì mới gần đây vậy anh :D ra lâu rồi mà
[6/13/2020, 4:52:22 AM] [huy]: #til <https://en.wikipedia.org/wiki/LPDDR> Low power DDR
[6/13/2020, 10:58:35 AM] [ledongthuc]: #til Trại lạnh nuôi gà
Là hệ thống trại điều hoà nhiệt độ môi trường theo từng lứa tuổi để cho năng suất cao nhất.
Ngoài ra còn có hệ thống thức ăn tự động theo từng độ tuổi của gà.
[6/13/2020, 6:10:00 PM] [xuan]: Đợt gần chỗ em, trời nóng, cúp điện, chủ trại đến k kịp, gà chết nhiều lắm. Điều hoà chỉ cần tắt tý thôi là chết hết
[6/13/2020, 6:15:12 PM] [Cậu Làm Vườn]: Klq lắm, nhưng mà ở những nơi có độ ẩm thấp, việc hạ nhiệt độ có thể dùng hơi nước, khá dễ và tiết kiệm. Ở xứ này độ ẩm lúc nào cũng 60-70+% thì phải làm điều hòa khéo kín :thinkcry:
[6/14/2020, 10:42:59 AM] [ko luong thien]: #til [FE Performance] Use ref to have up-to-date value without invalidate callback
```const Component = ({ foo }) =&gt; {
const fooRef = React.useRef&lt;Foo&gt;(foo);
fooRef.current = foo;
// logFoo will always log latest foo without being a new function
const logFoo = React.useCallback(() =&gt; {
console.log(fooRef.foo);
}, [fooRef]);
}```
[6/14/2020, 10:45:22 PM] [ko luong thien]: #til <https://github.com/acidanthera>
[6/14/2020, 10:45:40 PM] [ko luong thien]: cc thanh niên build máy @snacky
[6/14/2020, 11:27:50 PM] [ko luong thien]: #til
&gt; Trong public, ko phải cứ truy cập Internet mới có khả năng bị đánh cắp thông tin. Có rất nhiều cái mà end-user ko bao giờ để ý như type password dưới 1 cái camera trên đầu, check thẻ tín dụng bị camera quay lại
tks @xluffy (from <#C169UEXQB|security>)
[6/15/2020, 1:12:51 AM] [ZeroX]: #til
&gt; Internet Protocol television (IPTV) is the delivery of television content over Internet Protocol (IP) networks.
<https://github.com/iptv-org/iptv>
[6/15/2020, 2:04:55 AM] [minh.nguyen]: #til How to write your own malloc: <https://www.dropbox.com/s/l1puw1c9flrgccw/Malloc_tutorial.pdf?dl=0|https://www.dropbox.com/s/l1puw1c9flrgccw/Malloc_tutorial.pdf?dl=0>
[6/15/2020, 2:42:58 AM] [noob]: gần giống cách của dan luu, implement của anh <https://github.com/MQuy/mos/blob/master/src/kernel/memory/malloc.c>
[6/15/2020, 3:22:05 AM] [minh.nguyen]: Fun fact: Dan Luu inspire từ bài này :smile:. Em đang xem thử các allocator khác nó giải quyết bài toán fragmentation thế nào
[6/15/2020, 7:10:28 AM] [noob]: cái trên là allocator đơn giản nhất thì phải với lại bữa nay người ta không dùng sbrk nữa mà dùng mmap, bữa anh đọc sơ qua ở linux thì nó dùng slab allocator
[6/15/2020, 9:37:45 AM] [minh.nguyen]: @mquy :thumbsup:. Để em nghiên cứu tiếp. Implement thử nmap với anonymous mode xem có nhanh hơn không
[6/15/2020, 9:37:55 AM] [minh.nguyen]: Btw về vấn đề address alignment: <https://developer.ibm.com/technologies/systems/articles/pa-dalign/>
[6/16/2020, 6:43:59 AM] [ko luong thien]: #til <https://github.com/facebook/create-react-app/pull/8177> tks @nhducit
[6/16/2020, 6:44:36 AM] [ko luong thien]: didn't know this imply children. I thought it doesn't have children at all..
[6/16/2020, 9:04:00 AM] [Huy]: #til cái search của Chrome Dev Tool có thể search được content của tất cả các files đã loaded cho page đó
[6/16/2020, 9:36:57 AM] [Alpha]: My god. Đó giờ em toàn xài cái này. Cũng nhiều lần khó chịu vì cái children. Mà giờ không xài thì xài type gì nhỉ
[6/16/2020, 9:38:53 AM] [ko luong thien]: mình nghĩ mấy solution đề cập trong PR đủ tốt á bạn
[6/16/2020, 9:40:19 AM] [ko luong thien]: #til React.memo has a second argument to define the equal function <https://reactjs.org/docs/react-api.html#reactmemo> tks @nvcuong.infotech!
[6/17/2020, 1:39:46 AM] [whyn4]: #til <https://dev.to/ibrahima92/advanced-typescript-types-cheat-sheet-with-examples-5414>
[6/17/2020, 2:02:12 AM] [ko luong thien]: It looks just like <https://www.typescriptlang.org/docs/handbook/advanced-types.html>
[6/17/2020, 2:02:17 AM] [ko luong thien]: what's the difference?
[6/17/2020, 2:05:02 AM] [whyn4]: Have just take a look the content not difference but with example for each tips, it’s seem easier for understand xD
[6/17/2020, 4:24:51 AM] [ko luong thien]: #til "border priority" <https://developer.mozilla.org/en-US/docs/Web/CSS/border-style>
why because border-collapse
[6/18/2020, 2:02:52 AM] []: #til <https://notes.andymatuschak.org/Evergreen_notes>
[6/18/2020, 4:16:42 AM] [minh.nguyen]: #til Slab allocator: <https://srl.cs.jhu.edu/courses/600.418/SlabAllocator.pdf>. Hôm bữa anh nói về cái ày đúng không nhỉ? @mquy
[6/18/2020, 4:17:32 AM] [noob]: đúng rồi em :+1:
[6/18/2020, 5:50:31 AM] [unrealhoang]: slab này hay được dùng trong game nè
[6/18/2020, 5:50:41 AM] [unrealhoang]: increase pointer rồi drop nguyên frame
[6/19/2020, 8:22:29 AM] [ko luong thien]: #til in strict mode, React intentionally renders components that uses hook twice to highlight any side-effect-in-render issue. <https://we-build-vn.slack.com/archives/C32HMMUAW/p1592579865407800>
[6/19/2020, 12:11:27 PM] [huy]: #til Khi xài giấy A4/letter để đóng tập, nếu khi mở tập ra các trang giấy không chịu nằm xuống mà ngỏng lên trời, thì có nghĩa là gáy của tập đang nằm vuông góc với paper grain (chiều dàn trải của sợi xơ giấy) <http://myhandboundbooks.blogspot.com/2007/09/paper-grain.html>
[6/21/2020, 5:34:03 AM] [meowwwwwwwwwwwwwwww]: #til Cross-origin HTTP requests can be divided into two types: _simple_ requests and _non-simple_ requests.
[6/21/2020, 5:37:44 AM] [meowwwwwwwwwwwwwwww]: • for simple POST cross-origin request, the response needs to include the header `Access-Control-Allow-Origin: *` or an origin set that allowed to access the resource.
• for non-simple, requires browser to send pre-flight request for approving
[6/21/2020, 8:13:32 AM] [ShinaBR2]: #til Learning Typescript by fixing 405 in 1737 errors when running `tsc`.
[6/21/2020, 8:17:38 AM] [ko luong thien]: sao k adopt incrementally :))
[6/21/2020, 6:08:28 PM] [ShinaBR2]: Bug từ sâu bên trong basic interfaces :)) sửa 1 cái phải sửa hết những cái liên quan.
[6/21/2020, 9:24:23 PM] [stronglong]: #til keyboard only link embed
slack: hightlight text and paste link
github: hightlight text and Cmd+K, Cmd+V
[6/22/2020, 8:33:03 PM] [Charlie Brown]: #til Why DNS update take up to 2 days for everything to update
<https://jvns.ca/blog/how-updating-dns-works/>
#1 <https://howdns.works/>
#2 <https://www.joshmcguigan.com/blog/run-your-own-dns-servers/>
[6/22/2020, 8:39:31 PM] [ko luong thien]: #til (js) array.includes uses SameValueEqualityZero but array.indexOf uses strict equality
[6/22/2020, 10:38:46 PM] [minh.nguyen]: #til Doulingo used to trick users to translate content from its partners to earn money, the same as reCAPTCHA.
Another fact: Doulingo’s founder is also the foundet of reCAPTCHA.
[6/22/2020, 10:51:33 PM] [trexnix]: * Duolingo :smile:
[6/22/2020, 11:14:12 PM] [ko luong thien]: what do u mean "trick" :sosad: I thought that's very explicit
[6/22/2020, 11:15:34 PM] [anh bán chuối]: *founder
[6/22/2020, 11:17:20 PM] [ko luong thien]: oh my bad it's not that explicit :okay:
[6/22/2020, 11:52:36 PM] [meowwwwwwwwwwwwwwww]: #til `EPOCH=$(date +%s)`
[6/25/2020, 4:19:47 PM] [huy]: #til Chức năng zoom của Chrome nó ảnh hưởng theo hostname nhưng không phân chia port, ví dụ zoom lên 150% ở localhost:8111 thì qua localhost:8555 cũng vẫn bị zoom. This is stupid
[6/25/2020, 7:17:15 PM] []: nobody is surfing the web on localhost...
[6/25/2020, 9:05:05 PM] [huy]: people do have different web apps running on different localhost ports
[6/25/2020, 9:05:54 PM] []: who? and why?
[6/25/2020, 9:09:11 PM] [huy]: well, developer who has their in dev apps running
[6/25/2020, 9:10:20 PM] []: Not even 0.1% of internet users. Case closed. Won't fix.
[6/25/2020, 10:55:33 PM] [ko luong thien]: #til firefox fires blur/focus events when dragging but chrome doesn't :sosad:
[6/25/2020, 10:56:19 PM] [unrealhoang]: #CancelChrome đi
[6/25/2020, 10:56:26 PM] [unrealhoang]: :roflrofl:
[6/25/2020, 11:01:45 PM] [ko luong thien]: van de la khong biet cai nao dung hon
[6/25/2020, 11:01:48 PM] [huynh.cam]: safari có dịch rồi, bỏ chrome đi ae
[6/25/2020, 11:27:14 PM] [huy]: trên máy mềnh Safari và Chrome là 2 cái browser bị sys admin cài addon tracking, nên firefox là sự lựa chọn duy nhất
[6/25/2020, 11:27:25 PM] [huy]: in fact, hail firefox vì bảo vệ privacy của user
[6/26/2020, 11:55:15 AM] [huy]: #til `''` in vim
[6/27/2020, 12:02:18 AM] [huy]: #til deu` nhu vat’ “tranh” (not chanh)
[6/27/2020, 12:38:25 AM] [ko luong thien]: Nay làm podcast post bị ai nhắc hở anh :okay:
[6/27/2020, 12:38:36 AM] [ko luong thien]: Bữa định nhắc kín mà quên mất
[6/27/2020, 12:48:15 AM] [huy]: :sosad:
[6/27/2020, 12:58:57 AM] [Cậu Làm Vườn]: What the hell...
[6/27/2020, 2:22:42 AM] [ryan.tran]: mới xài vim nên không hiểu lắm anh ơi :okay:
[6/27/2020, 2:42:10 AM] []: Là sao anh
[6/27/2020, 8:28:07 AM] [huy]: jump to previous location
[6/27/2020, 11:53:44 AM] [Thanh Pham]: #til Parakaryon myojinensis
&gt; It is not clear whether P. myojinensis can be classified as a eukaryote or a prokaryote, the two categories to which all other cellular life belongs. ...P. myojinensis is the only organism to have a completely unknown position in the tree of life. Adding to the difficulties of classification, only one instance of this organism has been discovered to date, and so scientists have been unable to study it further.
<https://en.m.wikipedia.org/wiki/Parakaryon_myojinensis#Classification>
[6/27/2020, 11:04:51 PM] []: #til comprehension over speed reading and it's hard to measure the comprehension
<https://www.scotthyoung.com/blog/2015/01/19/speed-reading-redo/>
[6/28/2020, 9:42:03 AM] [huy]: thím scott có mấy bài cũng hay. nhất là về energy management
[6/28/2020, 11:57:27 PM] [hasagi]: trước giờ mình cũng nghĩ là vắt chanh hoài
[6/28/2020, 11:57:30 PM] [hasagi]: đúng là til luôn
[6/28/2020, 11:57:48 PM] []: :scream:
[6/29/2020, 8:38:28 PM] []: &gt; ... từ "vắt" trong "vắt tranh" là danh từ chỉ những vắt tranh đều tăm tắp trên tấm cỏ tranh chứ không phải động từ trong từ "vắt quả chanh". Ở đây câu thành ngữ "Đều như vắt tranh" ý nói làm một cái gì đấy rất đồng đều, đẹp mắt.
From <https://tintuc.vn/deu-nhu-vat-chanh-hay-vat-tranh-vi-sao-90-nguo-i-tra-lo-i-sai-post1396289>
[6/29/2020, 8:38:36 PM] [Charlie Brown]: #til BigQuery is Columnar storage
<https://cloudonair.withgoogle.com/events/2020-vn-cloud-solution/watch?talk=talk4>
[6/29/2020, 8:48:16 PM] [Dz]: but only support export table to Arvo ( row-based ) not Parquet ( column based )
[6/30/2020, 10:43:33 PM] [ko luong thien]: &gt; With a name standing for "search and save" in the Vietnamese language
#til TiKi
[6/30/2020, 10:49:55 PM] []: Tìm Kiếm và Tiết Kiệm ^
[6/30/2020, 10:55:48 PM] [Cậu Làm Vườn]: No "Tiết Kiệm" now :kappa:
[6/30/2020, 11:07:50 PM] []: You know what, it's just a random name. People like to say whatever they like. Don't forget that Tiki was just an online book store previously.
[6/30/2020, 11:10:58 PM] []: tìm cũng ko thấy luôn
[6/30/2020, 11:33:26 PM] [Vy]: fun fact: Passio -&gt; Passion without n (‘end’) :stuck_out_tongue:
[6/30/2020, 11:39:49 PM] [ko luong thien]: thread
[6/30/2020, 11:39:53 PM] [ko luong thien]: thread
[6/30/2020, 11:39:56 PM] [ko luong thien]: thread
[7/1/2020, 12:13:55 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: Nói thế là ko công bằng cho Tiki, năm 2013, tức là 3 năm kể từ khi thành lập, Tiki đã là cty bán lẻ nhiều mặt hàng rồi (thời trang, điện tử, phụ kiện, gia dụng …), và 1-2 năm sau đó, sách đã ko phải ngành hàng có doanh thu cao nhất rồi.
A Sơn cũng từng nói từ khi ảnh khởi nghiệp là ảnh đi theo mô hình của Amazon, nên từ khi thành lập, định hình là cty bán sách hay cty bán nhiều mặt hàng hay ko thì chỉ có ảnh mới biết chính xác đc nhưng khá chắc là ảnh ko chỉ có ý định dừng lại ở `just an online book store`.
[7/1/2020, 12:16:46 AM] []: Cũng có thể, vì cái đó cũng chuyện 10 năm trước rồi.
[7/1/2020, 12:17:33 AM] []: Nhưng mà cái slogan đi từ cái tên thương hiệu ra được vẽ ra từ bên team Marketing nhiều lắm.
[7/1/2020, 12:22:48 AM] []: Có anh em nào nghĩ ra slogan hay hay mình cùng làm EC nào :hopeful:
[7/1/2020, 12:23:40 AM] []: <http://lala.vn|lala.vn> -&gt; lập trình &amp; la liếm
[7/2/2020, 12:15:07 AM] [probokia]: ^ passio ~ endless passion thì chuẩn hơn
[7/2/2020, 3:57:54 AM] [chua dc luong thien]: #til we can use torrent hash as magnet link to download it :troll:
[7/2/2020, 11:56:26 PM] [ko luong thien]: #til <https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/void> thank @mac
[7/3/2020, 1:31:21 AM] [ledongthuc]: #til mỗi lần thèm mua monitor arms thì cứ dọn dẹp bàn làm việc cho gọn.
Nó gọn rồi thì hết muốn mua
[7/3/2020, 6:42:53 PM] [huy]: #til M&amp;Ms were developed in 1940 by Frank C. Mars and his son, Forrest Mars, Sr. During the Spanish Civil War (1936–1939), Forrest saw Spanish soldiers eating chocolate that had been covered in sugar as a way of “packaging” the chocolate to prevent it from making a mess
[7/3/2020, 6:46:53 PM] [huy]: #til chocolate pellets with a colored shell of what confectioners call hard panning (essentially hardened sugar syrup) surrounding the outside, preventing the sweets (candies) from melting.
[7/3/2020, 6:47:31 PM] [huy]: #til The company’s first big customer was the <https://en.wikipedia.org/wiki/United_States_Army|U.S. Army>, which saw the invention as a way to allow soldiers to carry chocolate in tropical climates without it melting.
[7/4/2020, 12:43:14 AM] [Heo Con]: #til 150 years in prison: <https://en.wikipedia.org/wiki/Bernie_Madoff>
[7/4/2020, 1:18:47 AM] [ko luong thien]: old but #til again onKeyPress event doesn't fire for non-character keys
[7/4/2020, 1:21:25 AM] [Phathdt]: #til server lưu datetime ở GMT + 0, khi trả về FE và dùng momentjs để convert thì momentjs sẽ lấy timezone của máy và convert về đúng timezone của máy user, issue xảy ra khi có 1 số user đang ở Sài Gòn mà lại set GMT + 8 ( SGP ) :crying:
[7/4/2020, 1:31:42 AM] [ko luong thien]: Interesting tai sao ban nghi do la issue :think: y minh la viec user o Saigon nhung set GMT la +8 (purposefully) co phai la invalid action khong nhi?
[7/4/2020, 1:35:22 AM] [Phathdt]: dạ, bug này do QC báo
sau 1 hồi debug thì phát hiện là do máy của QC xài windows và set timezone là GMT + 8, trong khi đó lại set thời gian là giờ việt nam
nên khi tạo record thì lúc đó là 14h30 ở vn, trên đồng hồ của QC cũng hiện là 14h30 luôn, nhưng sau khi moment format lại theo format `YYYY-MM-DD HH:mm` thì nó lại hiện 15h30
sau khi debug 1 hồi thì phát hiện vấn đề ở timezone và đồng hồ của máy QC …
[7/4/2020, 2:43:27 AM] [ledongthuc]: sound like feature. kiểu như travel đi Mỹ nhưng cần watch price history thì tự set về VN chứ ko muốn coi giờ Mỹ làm gì.
Nếu muốn improve thì chỗ tạo có thể nhắc user là time họ đang dùng tạo là +8 :thinking_face:
[7/4/2020, 2:59:26 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: :thinking_face: Chưa hiểu lắm, cái đó là lỗi user chứ hè? (set tz là +8 nhưng giờ lại là giờ +7)
[7/4/2020, 7:18:38 AM] [minh.nguyen]: #til <https://www.lihaoyi.com/Resume/|https://www.lihaoyi.com/Resume/> Đây là con trai Lý Hiển Long ...
[7/4/2020, 9:21:25 AM] [ko luong thien]: the hell that a :neutral_face:
[7/4/2020, 9:21:32 AM] [ko luong thien]: hoi o cty A toan xai hang cua thanh nien nay
[7/4/2020, 9:21:35 AM] [ko luong thien]: cc @iamquang95
[7/4/2020, 9:41:35 AM] []: :)) e nói cho a Minh mà
[7/4/2020, 9:49:48 AM] [ko luong thien]: sao k noi cho anh :sosad:
[7/4/2020, 9:49:50 AM] [ko luong thien]: buon`
[7/4/2020, 9:50:16 AM] [ko luong thien]: biet la con Ly Hien Long co khi hoi do bot cai nhau tren gitter :roflrofl:
[7/4/2020, 11:57:28 PM] []: @thien giờ có khi trong black list bên Sing rồi :roflrofl:
[7/5/2020, 6:18:23 AM] [dat]: :ie:
[7/6/2020, 2:09:14 AM] [Shaw Vu]: #til how JIT work
<https://carolchen.me/blog/jits-intro/>
[7/6/2020, 3:42:18 AM] [anh]: <https://wails.app/>
[7/6/2020, 7:35:08 AM] [dat]: comment xin, co tac gia vao tra loi: <https://lobste.rs/s/pz5gio/deep_introduction_jit_compilers_jits_are#c_merjqu>
[7/7/2020, 2:12:01 AM] [ledongthuc]: #til Lipstick_effect
```The theory that when facing an economic crisis consumers will be more willing to buy less costly luxury goods```
[7/7/2020, 2:16:43 AM] [ko luong thien]: I thought that's common sense :sad
[7/7/2020, 2:22:19 AM] [dat]: all economic theories are common sense
[7/7/2020, 2:24:44 AM] [ko luong thien]: Ừ nhỉ :|
[7/7/2020, 2:26:04 AM] [ledongthuc]: :yaomin: thế giờ đang crisis, mình có nên trốn sáp đèn cầy rồi bán giá cắt cổ ko nhỉ
[7/7/2020, 2:26:49 AM] [ledongthuc]: @thien phải nhử người ta đọc thêm chứ. Quote điều hiển nhiên thì có gì đâu đáng để TIL
[7/7/2020, 2:28:12 AM] [ledongthuc]: thêm link: <https://www.investopedia.com/terms/l/lipstick-effect.asp>
[7/7/2020, 2:29:39 AM] [Vy]: quote ko có tâm….vô góc ngồi đi anh @ledongthuc
[7/7/2020, 2:32:12 AM] [dat]: @thien:
```Paul Samuelson reports that the mathematician Stanislaw Ulam "used to tease me by saying, `Name me one proposition in all of the social sciences which is both true and non-trivial.` is was a test that I always failed."```
[7/8/2020, 2:01:59 AM] [huynh.cam]: TIL “vất bỏ” và “vứt bỏ”
[7/8/2020, 2:35:11 AM] [minh]: Chữ vất hay nè, nó là chữ nôm, không phải chữ hán. Ngày xưa độ phổ biến của từ vất khá cao, giờ hình như đỡ hơn rồi. Trong bộ bao nó có thể ghép thành "vất đi/vất bỏ", "vật ngã", "vặt vãnh", còn theo bộ thủ nó sẽ được ghép thành chữ "vất vưởng", "vất lên/vắt lên"
[7/8/2020, 2:37:06 AM] [minh]: Nhiều người nhầm "vất" là tiếng địa phương của từ "vứt", nhưng thực ra là nó cùng 1 bộ chữ, trong các âm ghép khác nhau sẽ tạo thành những cách đọc / hiểu khác nhau
[7/11/2020, 7:22:34 AM] []: #til <https://www.telegraph.co.uk/finance/newsbysector/mediatechnologyandtelecoms/11179017/This-is-the-kind-of-music-you-should-listen-to-at-work.html>
[7/11/2020, 7:23:23 AM] []: &gt; Classical music: if your work involves numbers or attention to detail
&gt; Pop music: if your work involves data entry or working to deadlines
&gt; Ambient music: if your work involves solving equations
&gt; Dance music: if your work involves proof-reading and problem solving
[7/11/2020, 10:27:59 AM] [ledongthuc]: #til cá heo có thể chết đuối nếu lặn quá lâu :omg: :omg: :omg:
[7/11/2020, 9:57:47 PM] []: #til Learning styles and strategies
<https://www.engr.ncsu.edu/wp-content/uploads/drive/1WPAfj3j5o5OuJMiHorJ-lv6fON1C8kCN/styles.pdf>
[7/11/2020, 9:58:19 PM] []: Bonus for the test to find your best fit style <https://www.webtools.ncsu.edu/learningstyles/>
[7/12/2020, 2:32:41 AM] [chua dc luong thien]: rất thú vị, sau khi khảo sát thấy rất giống :thinkhard:
[7/15/2020, 12:11:39 AM] [anh]: #til <https://marmelab.com/blog/2018/03/14/functional-programming-1-unit-of-code.html>
[7/15/2020, 6:52:06 AM] [Cậu Làm Vườn]: #til <https://en.wikipedia.org/wiki/Fundamental_attribution_error>
[7/15/2020, 10:17:21 AM] [ko luong thien]: #til accidentially <https://developer.mozilla.org/en-US/docs/Web/API/Window/length>
[7/15/2020, 10:25:57 AM] [ko luong thien]: #til mai ya hi mai ya hu is a love song <https://www.youtube.com/watch?v=Apo_olVTtH8>
[7/15/2020, 12:09:25 PM] [huy]: #til In the old times, scientist are required to have drawing skill, because they have to recreate everything they observed in their research, drawing is the only way to do that. With the advance of technologies (like camera, photographing, printing,...), people throw away their drawing skills.
It's a big mistake, because drawing skill also help them improve their observation, pay more attention on small details, patterns,... this seems to be an essential skills for technical worker like us as well.
<https://blogs.scientificamerican.com/symbiartic/rediscovering-the-forgotten-benefits-of-drawing/>
[7/15/2020, 2:29:44 PM] [huy]: #til <https://bradfrost.com/blog/post/atomic-web-design/|Atomic Design> in a Nutshell:
- HTML elements, font, colors,... are considered as an *atom*
- We combine atoms into a *molecules*, just like how we combined many elements into a reusable group (think about searchbox element or an address input group - which has address, zipcode, city fields,...)
- Groupping many reusable groups, you have an *organism*. Think of this as a complex but standalone and reusable components, like a Header component, or a Dropdown list, a Map, a Calendar component,...) - These are the building blocks of a web page.
- Next, *a template*, is a set of components putting together, come with placeholder content, providing context of all the building blocks. It's the final product of a design like an HTML wireframe.
- Lastly, a *page*, is a specific type of templates where all of the placeholder being replaced with real content, has the highest level of fidelity and this is where most of the review rounds happen (think of a complete mockup in your Figma documents)
[7/15/2020, 9:42:32 PM] [SFzxc]: Can't deny
[7/15/2020, 10:10:29 PM] [ko luong thien]: <https://we-build-vn.slack.com/archives/C32HMMUAW/p1594876166328300>
[7/16/2020, 8:37:28 AM] [minh.nguyen]: <https://gankra.github.io/blah/text-hates-you/|https://gankra.github.io/blah/text-hates-you/>
[7/16/2020, 8:38:29 AM] [minh.nguyen]: Another interesting link: <https://lord.io/blog/2019/text-editing-hates-you-too/|https://lord.io/blog/2019/text-editing-hates-you-too/>
[7/16/2020, 9:14:14 AM] [minh.nguyen]: cc @thien
[7/16/2020, 10:34:59 PM] [tay vịn của anh bán chuối - cty A tìm FE]: #til
<https://twitter.com/timneutkens/status/1282794931464151040?s=21|https://twitter.com/timneutkens/status/1282794931464151040?s=21>
[7/17/2020, 7:11:25 AM] [ZeroX]: <https://we-build-vn.slack.com/archives/C3HGW0MFZ/p1594995055101200>
[7/17/2020, 7:38:12 AM] [ko luong thien]: Nhớ vụ hack bằng uppercase k em :))
[7/17/2020, 7:51:48 AM] [ZeroX]: dè cái đó kì diệu phết:))
[7/17/2020, 7:52:46 AM] [ZeroX]: cơ mà anh đang nói về vụ hack bằng uppercase email phải không?
[7/20/2020, 5:49:02 AM] [manhdv]: s/ngoặc đơn/nháy đơn?
[7/20/2020, 5:51:57 AM] [Cậu Làm Vườn]: Đã fix. Vừa tra thì cái `'` cũng có thể gọi là ngoặc đơn nữa, nhưng đúng là dễ confuse với ngoặc tròn.
[7/20/2020, 7:47:07 AM] [meowwwwwwwwwwwwwwww]: #til <http://youtube.com/watch?v=kDxjcyHu_Qs|youtube.com/watch?v=kDxjcyHu_Qs>
[7/21/2020, 12:23:08 AM] [minh.nguyen]: #til Good paper about Build System: <https://www.microsoft.com/en-us/research/uploads/prod/2018/03/build-systems.pdf|https://www.microsoft.com/en-us/research/uploads/prod/2018/03/build-systems.pdf>
[7/21/2020, 5:18:45 AM] [dangthaison91]: MS có AnyBuild có vẻ cũng ngon
[7/21/2020, 7:32:46 AM] [vthu]: #til
```Object.preventExtensions```
[7/21/2020, 7:23:41 PM] [anh]: ```Object.seal -&gt; configurable:false + Object.preventExtensions
Object.freeze -&gt; Object.seal + writable:false```
[7/21/2020, 8:40:51 PM] [話せる森林]: #til lúc soạn mail mà gõ `@` thì sẽ hiện ra danh sách các contact để mình chọn. Lúc gửi mail thì tên được chọn sẽ được highlight lên nhưng vẫn chưa biết chức năng này dùng để làm gì.
[7/21/2020, 9:15:05 PM] [huy]: #til Component Shadowing in Gatsby <https://www.gatsbyjs.org/docs/themes/shadowing/>
[7/21/2020, 10:44:24 PM] [Graphic D. Thanh]: #til Hôm ni e đọc cuốn “Elasticsearch in action”(<https://livebook.manning.com/book/elasticsearch-in-action/chapter-2/208>) rồi thử test đoạn
```curl 'localhost:9200/get-together/_doc/_search?pretty' -d '{
"query": {
"query_string": {
"query": "elasticsearch"
}
}
}'```
thì bị lỗi thế này
```{
"error" : "Content-Type header [application/x-www-form-urlencoded] is not supported",
"status" : 406
}```
Research mới thấy bạn Elasticsearch apply *“strict content type checking”*(<https://www.elastic.co/blog/strict-content-type-checking-for-elasticsearch-rest-requests>)
Cho nên phải thêm `-H'Content-Type: application/json'` vào mới chạy được
[7/22/2020, 2:16:16 AM] [ko luong thien]: :neutral_face: it's google
[7/22/2020, 2:16:41 AM] []: @thien phải chọn favorite nữa mẹ
[7/22/2020, 2:17:03 AM] []: cái ngôi sao bên translated kìa
[7/22/2020, 2:17:03 AM] [ko luong thien]: là sao @triet
[7/22/2020, 2:17:18 AM] [ko luong thien]: biết cái đó rồi, nhưng cái history đúng ra phải hiện hết chứ..
[7/22/2020, 2:17:50 AM] [ko luong thien]: em xài để dịch manhwa mà giờ tìm lại chả thấy gì :think: tưởng nó auto lưu vào history
[7/22/2020, 2:17:52 AM] []: à, sr, cái đó thì theo session thôi
[7/22/2020, 2:18:17 AM] []: refresh là bay màu
[7/22/2020, 2:18:40 AM] [ko luong thien]: chắc bay màu ở máy thôi, chứ write vào db google rồi :vayvay:
[7/22/2020, 2:18:50 AM] [ko luong thien]: in google i trust (that they track everything)
[7/22/2020, 2:52:51 AM] [hieu.huynh]: data giờ là vàng nha, xoá là xoá thế nào dc, log hết
[7/22/2020, 2:52:54 AM] [hieu.huynh]: :doubt:
[7/22/2020, 4:05:22 AM] [Vy]: @triet hình như ko phải á anh, em vừa restart máy sẵn mở check lun thì thấy history vẫn còn
[7/22/2020, 7:04:28 AM] [ko luong thien]: @vytran0211 Vy bị track rồi lêu lêu
[7/22/2020, 6:45:37 PM] [Cá Ngừ Hoang]: Sống trong rừng, ngóc ngách nào thần rừng cũng biết :shake:
[7/23/2020, 1:19:06 AM] [ko luong thien]: #til <https://developer.mozilla.org/en-US/docs/Web/Guide/Events/Creating_and_triggering_events> first time doing this in paid work
[7/23/2020, 1:23:30 AM] [usbc]: bữa em cũng có dùng cái này :omg:
[7/23/2020, 1:23:50 AM] [usbc]: mà ko có #til
[7/23/2020, 1:24:05 AM] [ko luong thien]: where is your community spririt dude
[7/23/2020, 1:29:47 AM] [usbc]: hê hê :yaomin:
[7/23/2020, 1:48:31 AM] [ledongthuc]: hoắc ít nhất là ta nghĩ vậy
[7/23/2020, 1:49:47 AM] [ko luong thien]: não với thị giác nó vui lắm anh
[7/23/2020, 1:49:50 AM] [ko luong thien]: good topic to explore
[7/23/2020, 1:49:55 AM] [ko luong thien]: just don't do at 2AM
[7/23/2020, 1:50:06 AM] [ko luong thien]: anh biết vụ pink is not real color chưa :))
[7/23/2020, 1:50:27 AM] [ko luong thien]: nói chung não người là 1 cái hệ thống "try to work best"
[7/23/2020, 1:50:43 AM] [unrealhoang]: You mean magenta?
[7/23/2020, 1:52:37 AM] [ledongthuc]: uhm, có biết vụ pink là màu fake, kiểu 1 cảm nhận sắc thái của não bộ về màu đỏ
[7/23/2020, 1:53:28 AM] [ko luong thien]: @unrealhoang :okay:
[7/23/2020, 1:53:30 AM] [ledongthuc]: anh nhớ nó là gom từ ánh sáng đỏ với trắng hay gì đấy
[7/23/2020, 1:54:03 AM] [unrealhoang]: Đỏ / tím
[7/23/2020, 1:54:13 AM] [ko luong thien]: <https://en.wikipedia.org/wiki/Spectral_color#Extra-spectral_colors> enjoy
[7/23/2020, 1:54:15 AM] [Cậu Làm Vườn]: Không phải trắng là tất cả các màu gộp lại à :v
[7/23/2020, 1:54:37 AM] [unrealhoang]: 2 đầu của spectrum light wave
[7/23/2020, 1:55:40 AM] [ko luong thien]: ê mới coi lại, cái của Hoàng nói với cái pink là 2 case khác nhau :))
[7/23/2020, 1:55:45 AM] [ko luong thien]: case magenta là 2 đầu spectrum
[7/23/2020, 1:55:56 AM] [ko luong thien]: còn case pink là giống case brown (grayscale + real color = near color)
[7/23/2020, 1:56:16 AM] [ko luong thien]: magenta = red + violet
pink = red + grayscale(0) (aka white)
[7/23/2020, 1:56:20 AM] [unrealhoang]: Ồ #til
[7/23/2020, 1:56:38 AM] [ledongthuc]: #til
[7/23/2020, 1:56:46 AM] [ledongthuc]: ồ ra magenta khác pink
[7/23/2020, 2:43:06 AM] [Cậu Làm Vườn]: ^ :rage:
[7/23/2020, 2:44:20 AM] [usbc]: e cũng chưa cái #til cái đẩy <https://we-build-vn.slack.com/archives/C0J7M3P8V/p1595304721287300|này> nữa
[7/23/2020, 9:49:59 AM] [huy]: có liên quan tới vụ ngày xưa ng ta hay dùng màu magenta để làm background cho game sprite ko nhỉ. giống phông xanh.
[7/23/2020, 9:52:32 AM] [ko luong thien]: @snacky phông xanh thì em k biết, nhưng cái magenta is transparent trong thiết kế more likely là vì:
- cái màu được chọn rất hiếm xài
- dễ notice
[7/23/2020, 9:53:42 AM] [ko luong thien]: <https://forums.nesdev.com/viewtopic.php?t=13096>
[7/23/2020, 9:56:06 AM] [ledongthuc]: nhìn mỏi mắt nhỉ
[7/23/2020, 9:56:37 AM] [ko luong thien]: did u google magenta in game?
[7/23/2020, 9:56:49 AM] [ledongthuc]: ya
[7/23/2020, 9:57:36 AM] [ko luong thien]: nói chứ trong hình anh cũng k có cái pixel nào gần cái transparent magenta kìa :))
[7/23/2020, 9:57:53 AM] [ko luong thien]: cái đó là FF00FF (max red max blue)
[7/23/2020, 9:58:00 AM] [ledongthuc]: :okay: thấy khác gì đâu
[7/23/2020, 10:05:36 AM] [huy]: thực ra magenta cho sprite bg thôi. còn gâm background là layer khác r
[7/23/2020, 10:38:45 PM] [minh]: Cái này vật lý cấp 2 có nói mà :rolling_on_the_floor_laughing:
[7/23/2020, 11:00:00 PM] [ledongthuc]: Cấp 2 mình chỉ quan tâm B41 và B43, súng nào bắn ngon hơn thôi nha :okay:
[7/23/2020, 11:52:53 PM] [Scott Dang]: ^ cả lên đời trong bao phút nữa :okay:
[7/23/2020, 11:55:13 PM] [minh]: Cứ đủ 20 dân là lên đời nha :ok_hand: tầm 7p là đẹp
[7/23/2020, 11:56:01 PM] [huy]: til what
[7/23/2020, 11:56:17 PM] [ko luong thien]: #til <https://en.wikipedia.org/wiki/Quadtree> for FE rendering. Tks @snacky
[7/23/2020, 11:56:24 PM] [ko luong thien]: spam
[7/24/2020, 12:01:46 AM] [ledongthuc]: til about we have til channel
[7/24/2020, 12:35:49 AM] [Ralph]: Share bổ trợ
<https://github.com/d3/d3-quadtree|https://github.com/d3/d3-quadtree>
Hồi xưa có xài để tìm nearest object và objects in viewport
[7/24/2020, 6:48:08 AM] [ko luong thien]: <https://medium.com/@bellmar/is-cobol-holding-you-hostage-with-math-5498c0eb428b|https://medium.com/@bellmar/is-cobol-holding-you-hostage-with-math-5498c0eb428b>
[7/24/2020, 11:31:04 AM] [huy]: #til <https://notes.huy.rocks/social-loafing|Social Loafing>
[7/24/2020, 7:33:34 PM] [meowwwwwwwwwwwwwwww]: Em type lộn :))
[7/25/2020, 12:47:10 AM] [Nhà Quê]: xe độp: van FV là van hạt gạo
van AV là van cối hay gọi là van xe máy
[7/25/2020, 9:29:49 AM] [ko luong thien]: quite interesting <https://en.wikipedia.org/wiki/List_of_U.S._presidential_campaign_slogans>
[7/26/2020, 10:00:25 PM] [ko luong thien]: #til báo giá quảng cáo vnexpress là công khai <https://eclick.vn/bao-gia/>
[7/26/2020, 11:38:11 PM] []: #til spotifyd
[7/26/2020, 11:42:24 PM] [huy]: #til Apple Watch có chế độ *thổi* nước ra khỏi máy <https://www.youtube.com/watch?v=EIEwy8rPik4>
[7/26/2020, 11:52:27 PM] [ko luong thien]: Cái nào chả có..
[7/26/2020, 11:52:31 PM] [ko luong thien]: Samsung cũng có mà..
[7/26/2020, 11:52:42 PM] [ko luong thien]: Mấy cái mang đi bơi đc đều có mà..
[7/27/2020, 4:23:09 AM] [Cậu Làm Vườn]: #til <https://en.wikipedia.org/wiki/Hanging_punctuation>
[7/27/2020, 4:39:29 AM] [Cậu Làm Vườn]: Once you saw it, it cannot be unseen.
[7/27/2020, 11:26:17 AM] [ko luong thien]: #til it's been well known that's the "80" standard of line length comes from punch cards. However, <#C16AY670U|til> that the reason punch cards use 80 is because it's designed after a money bill <http://www.columbia.edu/cu/computinghistory/census-tabulator.html>
[7/28/2020, 3:08:41 AM] [Cậu Làm Vườn]: #til there's thin space, third space, quarter space, sixth space, flush space, hair space, figure space, and punctuation space. And why InDesign should be used for professional print layout and publishing (they support a tons of less publicly known typography options, like hanging punctuation)
[7/28/2020, 5:07:33 AM] [ko luong thien]: Wikipedia "space" page, and google "space yourself" for a smashing magazine article
[7/28/2020, 6:20:31 AM] [noob]: #til in C, a += 2 might not be the same as a = a + 2
[7/28/2020, 6:33:27 AM] [ko luong thien]: Why "might"?
[7/28/2020, 7:00:09 AM] [minh.nguyen]: Why?
[7/28/2020, 7:38:31 AM] [unrealhoang]: why
[7/28/2020, 7:48:00 AM] []: cái a = a + 2 có thể gây ra OMM vì nó sẽ tạo ra 1 biến tạm để lưu giá trị a + 2 rồi gán giá trị đó cho a.
e đọc cái này lâu lâu r nên k nhớ rõ lắm :)) trước e code leetcode bị OMM 1 cái như thế này rồi :cry:
[7/28/2020, 7:49:21 AM] []: mà c/c++ thì cũng tùy vào compiler nó optimize thế nào nữa, cái này thì em thua :cry:
[7/28/2020, 7:49:29 AM] []: nên chắc đấy là lý do của "might" :))
[7/28/2020, 7:56:12 AM] []: OMM?
[7/28/2020, 7:56:35 AM] []: out of mem ạ
[7/28/2020, 7:56:45 AM] []: (à code competitve nó giới hạn mem :&lt; )
[7/28/2020, 7:56:51 AM] []: là OOM chớ
[7/28/2020, 7:57:15 AM] []: :cry: dạ lỗi em :&lt;
[7/28/2020, 7:57:31 AM] []: tưởng đâu khái niệm gì mới nữa :thinkold:
[7/28/2020, 7:57:49 AM] []: :okay:
[7/28/2020, 8:04:56 AM] [unrealhoang]: vẫn hóng @mquy
[7/28/2020, 8:05:34 AM] [minh.nguyen]: • a += 2
```main:
push rbp
mov rbp, rsp
mov DWORD PTR [rbp-4], 1
add DWORD PTR [rbp-4], 2
mov eax, 0
pop rbp
ret```
• a = a + 2
```main:
push rbp
mov rbp, rsp
mov DWORD PTR [rbp-4], 1
add DWORD PTR [rbp-4], 2
mov eax, 0
pop rbp
ret```
Compile bằng GCC, Clang
[7/28/2020, 8:06:04 AM] [unrealhoang]: @nguyenquangminh chắc ý <@U0GP83HM3> là spec của 2 line đó
[7/28/2020, 8:06:18 AM] [unrealhoang]: chứ compile thì case đơn giản chắc chắn ra giống nhau rồi
[7/28/2020, 8:07:34 AM] [minh.nguyen]: Em vẫn đang cố tìm thử case này compile ra khác nhau :think: đã tắt tất cả các flag optimization rồi
[7/28/2020, 8:07:38 AM] [noob]: từ spec của C nè
```A compound assignment of the form E1 op= E2 differs from the simple assignment expression E1 = E1 op (E2) only in that the lvalue E1 is evaluated only once.```
thử cái ví dụ <https://godbolt.org/z/Gcajqo>
[7/28/2020, 8:08:57 AM] [unrealhoang]: à E1 có thể là expression, #til
[7/28/2020, 8:09:10 AM] [noob]: `a` dễ bị nhầm là biến `a` nào đó nhưng ý ở đây là lvalue :ommi:
[7/28/2020, 8:10:55 AM] [minh.nguyen]: #til Đọc vào cứ tưởng variable
[7/28/2020, 8:15:07 AM] []: à cái OOM của em thì a là string thì mới OOM được :cry:
[7/28/2020, 8:16:22 AM] []: <https://leetcode.com/problems/license-key-formatting/>
```string licenseKeyFormatting(string S, int K) {
string res;
for(auto i = S.rbegin(); i &lt; S.rend(); i++) {
if (*i != '-') {
if (res.size() % (K+1) == K) {
res += '-';
}
res += toupper(*i);
}
}
reverse(res.begin(), res.end());
return res;
}```
vs
```string licenseKeyFormatting(string S, int K) {
string res;
for(auto i = S.rbegin(); i &lt; S.rend(); i++) {
if (*i != '-') {
if (res.size() % (K+1) == K) {
res = res + '-';
}
res += toupper(*i);
}
}
reverse(res.begin(), res.end());
return res;
}```
[7/28/2020, 8:17:32 AM] [unrealhoang]: c++ thì khác hẳn rồi bạn
[7/28/2020, 8:17:50 AM] [unrealhoang]: 2 operator khác nhau hoàn toàn
[7/28/2020, 8:17:59 AM] []: dạ :cry:
[7/28/2020, 8:19:13 AM] [unrealhoang]: vì C++ overload operator thoải mái
[7/28/2020, 8:19:14 AM] [noob]: c++ thì có operator overloading, khi đó còn tricky hơn nựa
[7/28/2020, 8:20:38 AM] [minh.nguyen]: À grammar của C thì thế này:
```
assignment_expression
: conditional_expression
| unary_expression assignment_operator assignment_expression
;
assignment_operator
: '='
| MUL_ASSIGN
| DIV_ASSIGN
| MOD_ASSIGN
| ADD_ASSIGN
| SUB_ASSIGN
| LEFT_ASSIGN
| RIGHT_ASSIGN
| AND_ASSIGN
| XOR_ASSIGN
| OR_ASSIGN
;```
Nên left có thể là unary expression only, và right có thể là một assignment khasc: `a *= b *= 3;` or even `a *= (*b++) *= 3;`
[7/28/2020, 8:22:04 AM] []: e chưa code C cũng k code C++ nhiều, cơ mà who the hell will write this kind of code :cry:
[7/28/2020, 8:26:40 AM] [unrealhoang]: ^ <https://www.hyrumslaw.com/>
[7/28/2020, 8:28:31 AM] [noob]: chỉ mới viết c gần đây nên cũng chưa gặp trường hợp nào như vậy, dự là có thể do macro programming :thinkhard:
[7/28/2020, 9:19:02 AM] [minh.nguyen]: đọc nhiều, đặc biệt là các source cũ cũ, sẽ thấy các bô lão ngày xưa thích chơi với pointer lắm. Chaining càng nhiều, càng ngắn gọn càng nhìn "smart"
[7/28/2020, 9:20:10 AM] [minh.nguyen]: ```do {
const char *in_saved = in;
while (*in &amp;&amp; *in != '(' &amp;&amp; *in != ')' &amp;&amp; *in != ',')
*out++ = *in++;
if (*in != '(' &amp;&amp; in &gt; in_saved) {
len += 8;
if (len &gt;= CRYPTO_MAX_ALG_NAME)
goto too_long;
memcpy(out, "-generic", 8);
out += 8;
}
} while ((*out++ = *in++) != '\0');```
[7/28/2020, 9:20:18 AM] [minh.nguyen]: Một đoạn trong linux kernel
[7/28/2020, 9:21:07 AM] [minh.nguyen]: ``` * aes =&gt; aes-generic
* cbc(aes) =&gt; cbc(aes-generic)
* cts(cbc(aes)) =&gt; cts(cbc(aes-generic))
* rfc7539(chacha20,poly1305) =&gt; rfc7539(chacha20-generic,poly1305-generic)```
Input và output ...
[7/28/2020, 9:21:08 AM] [unrealhoang]: *out++ = *in++ nó là pattern rồi
[7/28/2020, 9:21:31 AM] [minh.nguyen]: Thề là đọc không có description ứ biết nó làm gì :arggg:
[7/28/2020, 9:23:05 AM] [unrealhoang]: nhớ pattern thì mới đọc được
[7/28/2020, 9:23:13 AM] [unrealhoang]: :omg:
[7/28/2020, 9:24:22 AM] [minh.nguyen]: Khổ là, chỉ có function này có pattern này :omg: mấy chỗ khác mỗi function một kiểu
[7/28/2020, 9:25:04 AM] [unrealhoang]: bữa đọc neovim cũng có *out++ = *in++
[7/28/2020, 9:26:49 AM] [noob]: công nhận linux đúng là mỏ vàng, bữa mới biết vụ data oriented, inheritance ở C :shake:
[7/28/2020, 9:58:50 AM] [Scott Dang]: :adore:
[7/29/2020, 9:44:55 AM] [FULLCLEARONSTAGE]: #til imperative mood: <https://en.wikipedia.org/wiki/Imperative_mood>
[7/29/2020, 12:22:37 PM] [ko luong thien]: <https://vi.wikipedia.org/wiki/Trung_Qu%E1%BB%91c_t%E1%BB%A9_%C4%91%E1%BA%A1i>
[7/29/2020, 12:26:23 PM] [huy]: wiki mention thiếu "Bè lũ bốn tên" rồi
[7/29/2020, 1:03:15 PM] [huynh.cam]: nhóm Tứ trụ thì sao?
[7/29/2020, 1:08:35 PM] [huy]: nhưng nhóm này ko phải china, hay ý a là :thinkhard:
[7/29/2020, 1:10:04 PM] [huynh.cam]: :checkered_flag::car:
[7/29/2020, 8:14:51 PM] []: &gt; Tứ đại phát minh (四大發明) của người Trung Quốc gồm la bàn, thuốc súng, nghề làm giấy và nghề in
Thế còn tơ lụa thì sao nhỉ? :thinking_face:
[7/29/2020, 8:25:27 PM] [huy]: impact của tơ lụa không rộng và quan trọng bằng impact của 4 thứ kia
[7/29/2020, 10:56:04 PM] [ko luong thien]: #til css revet !== initial !== unset <https://developer.mozilla.org/en-US/docs/Web/CSS/revert>
[7/29/2020, 10:59:47 PM] [ko luong thien]: vấn đề là nó k có cái thay thế hiệu quả :think:
[7/29/2020, 11:00:25 PM] [ko luong thien]: ví dụ giờ anh override outline bằng `button { outline: none }`, giờ với cái button `.huy` anh muốn phục hồi lại cái outline của trình duyệt (vd ở safari mac là cái blue ring) thì anh làm sao
[7/29/2020, 11:04:34 PM] [huy]: inherit?
[7/29/2020, 11:05:12 PM] [huy]: or empty string
[7/29/2020, 11:05:13 PM] [huy]: :roflrofl:
[7/29/2020, 11:06:53 PM] [huy]: unset?
[7/29/2020, 11:07:32 PM] [ko luong thien]: trap :v
[7/29/2020, 11:07:46 PM] [ko luong thien]: empty string thì invalid, nó fallback về cái trước đó
[7/29/2020, 11:07:50 PM] [ko luong thien]: inherit thì tầm bậy nhé
[7/29/2020, 11:07:59 PM] [ko luong thien]: unset nó reverse về CSS specification
[7/29/2020, 11:08:10 PM] [ko luong thien]: nhưng vấn đề là CSS specification nó không giống user agent
[7/29/2020, 11:08:39 PM] [ko luong thien]: ví dụ rõ nhất là cái h1
[7/29/2020, 11:08:52 PM] [huy]: ồ
[7/29/2020, 11:08:55 PM] [huy]: hiểu rồi
[7/29/2020, 11:08:55 PM] [ko luong thien]: h1 unset và h1 initial nó sẽ có font weight là normal, vì css specs define như thế
[7/29/2020, 11:09:03 PM] [huy]: vậy là do e làm sai rồi
[7/29/2020, 11:09:11 PM] [ko luong thien]: còn h1 is bold là user agent. Hiện tại chỉ có revert là lấy được cái của user agent
[7/29/2020, 11:09:12 PM] [huy]: từ đầu đừng có override cái top level (tag)
[7/29/2020, 11:09:38 PM] [ko luong thien]: em đang làm app enterprise chứ có phải side project đâu mà tự do thế :vayvay:
[7/29/2020, 11:11:11 PM] [huy]: ngụy biện
[7/30/2020, 12:49:24 AM] []: <https://twitter.com/frontstuff_io/status/1287423171247968256>
[7/30/2020, 2:36:24 AM] [noob]: &gt; Nothing is beyond your reach when you master the basics
càng ngày càng thấm vụ này, trong mọi lĩnh vực nếu nắm nền tảng vững thì làm gì cũng nhanh, ví dụ điển hình nhất là trương vô kị :kappa:
[7/30/2020, 2:56:25 AM] [tuan]: #til dùng <http://github.com/{username}.keys|github.com/{username}.keys> để tìm public key của người dùng. Same for gitlab
[7/30/2020, 3:02:19 AM] [tuan]: sao lại bĩu môi em :cry: @xluffy
[7/30/2020, 3:46:04 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: xài ansible, dùng cái này để pull key nhiều mà :smile:
[7/30/2020, 3:46:17 AM] [tuan]: :okay:
[7/30/2020, 4:48:03 AM] [giangnh]: anh @mquy master os chưa
[7/30/2020, 4:27:10 PM] [Quang Lương]: <https://en.wikipedia.org/wiki/Lp0_on_fire|https://en.wikipedia.org/wiki/Lp0_on_fire>
[7/31/2020, 3:14:16 AM] [anh]: <https://github.com/FiloSottile/whoami.filippo.io>
[7/31/2020, 12:17:46 PM] [ko luong thien]: <https://www.osha.gov/SLTC/etools/computerworkstations/positions.html>
[8/2/2020, 12:53:28 AM] [ko luong thien]: Forced lucid dream <https://www.sciencedirect.com/science/article/abs/pii/S1053810020300416?via%3Dihub>
[8/2/2020, 1:29:39 AM] [huy]: don’t mess with your mind. it’s dark art
[8/2/2020, 2:27:04 AM] []: #til A pointer in C is an address, which is a numeric value. Therefore, you can perform arithmetic operations on a pointer just as you can on a numeric value.
:okay:
[8/2/2020, 5:15:49 AM] [minh.nguyen]: Not exacly. Incrementing operation will move the pointer to the next memory location, not the next numeric value. For example: int *a = 3214864300, a + 1 = 3214864304. In addition, just some operations are valid (or meaningful).
[8/2/2020, 5:40:44 AM] []: I didn't mean it would move to the next numeric value though.
For arithmetic, I meant it's able to perform +, -, ++, -- and comparison such as ==, !=, &lt;, &gt;, &gt;=, etc.
Here is an example, excerpt from The C Programming Language (5.4 Address Arithmetic)
```#define ALLOCSIZE 10000
static char allocbuf[ALLOCSIZE]; /* storage for alloc*/
static char *allocp; // next free position
char *alloc(int n);
void afree(char *p);
// Return a pointer to a consecutive character position,
// which can be used by a caller of alloc for storing characters
char *alloc(int n) {
if (allocbuf + ALLOCSIZE - allocp &gt;= n) { // it's fit
allocp += n;
return allocbuf - n; // old p
} else { // not enough room
return 0;
}
}
void afree(char *p) { // Free storage pointed to by p
if (p &gt;= allocbuf &amp;&amp; p &lt; allocbuf + ALLOCSIZE) {
allocp = p;
}
}```
&gt; Tests like
```if (allocbuf + ALLOCSIZE - allocp &gt;= n) { /* it fits */```
&gt; and
```if (p &gt;= allocbuf &amp;&amp; p &lt; allocbuf + ALLOCSIZE)```
&gt; show several important facets of pointer arithmetic.
[8/2/2020, 5:53:00 AM] []: Or this example, get the length of the string using pointer arithmetic.
```int strlen(char *s) {
char *p = s;
while (s != '/0')
p++
return p - s;
}```
[8/2/2020, 6:01:04 AM] [minh.nguyen]: Yes. They can perform some arithmetic operations, but we just simply can't say they are numeric value or they can perform arithmetic operations because they are numeric values. Sorry, I'm a little bit nitpick on terminology :omg:
[8/2/2020, 6:20:41 AM] [minh.nguyen]: In addition, even they can perform `+` operation, the use cases of that operation is really limited.
```int *a;
int *b;
a + b; # invalid
a - b; # valid. Indicate the distance between them
char *c;
a - c; # Invalid, incompatible types.```
So, in my personal opinion, they have a subset arithmetic operations to indicate the special operations upon pointers. The same applies to some arithmetic operations on some data structure such as Array (in Ruby): `[1,2,3] + [4,5]` means array concatenation, they have `+` arithmetic operation, but they have no relation to numeric.
[8/2/2020, 6:26:37 AM] []: yeah, I know that, just kind of metaphor for easier remember :okay:
[8/3/2020, 7:44:17 AM] [noob]: #til http/2 multiplexing
[8/4/2020, 9:03:08 AM] [ko luong thien]: #til <https://sijinjoseph.com/programmer-competency-matrix/> tks @triet
[8/4/2020, 9:18:20 AM] [Graphic D. Thanh]: This is great one!
[8/4/2020, 10:28:19 AM] [huy]: #til Dùng regex là một tội ác
[8/4/2020, 10:32:35 AM] [ko luong thien]: I bet there is a sad story behind
[8/4/2020, 10:33:38 AM] [ko luong thien]: <https://we-build-vn.slack.com/archives/C0J7M3P8V/p1596562371392700>
[8/4/2020, 10:36:23 AM] [unrealhoang]: Y?
[8/4/2020, 10:40:52 AM] [ko luong thien]: @unrealhoang #javascript
[8/4/2020, 10:41:25 AM] [huy]: thì join vô dự án của ngưòi khác start, xong rồi requirement thay đổi, sau một cuộc bể dâu thì anh ấy thấy mình là người phải ngồi maintain cái đống regex ấy :sosad:
[8/4/2020, 10:42:39 AM] [ko luong thien]: plot twist hình như @snacky là người làm cho thanh niên kia phải ra đi đúng k :think:
[8/4/2020, 10:42:53 AM] [ko luong thien]: xong karma phải vô hốt
[8/4/2020, 10:47:16 AM] [huy]: you know too much :pepeandao:
[8/4/2020, 10:47:44 AM] [ko luong thien]: An interesting story behind matching email with regex <http://www.regular-expressions.info/email.html>
[8/5/2020, 1:55:53 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til
&gt; String literal types were introduced by TypeScript to model JavaScript behavior, it's a relatively new concept since most type systems are runtime encoding agnostic
<https://reasonml.org/blog/string-literal-types-in-reason>
[8/5/2020, 1:55:56 AM] [ko luong thien]: dạo này làm SVG ngày nào cũng #til :sosad: <https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/markerUnits>
[8/5/2020, 1:58:52 AM] [unrealhoang]: Có til phải sướng chứ
[8/5/2020, 1:59:47 AM] [ko luong thien]: true though :vayvay:
[8/5/2020, 2:17:55 AM] [minh]: Đang work with svg, đau hết cả đầu :crying:
[8/5/2020, 2:22:01 AM] [ko luong thien]: share lên #frontend đi bạn :vayvay:
[8/5/2020, 2:39:23 AM] [Graphic D. Thanh]: #til <https://speakerdeck.com/jvns/so-you-want-to-be-a-wizard/> thanks to @nguyenquangminh
[8/5/2020, 10:12:02 AM] [ko luong thien]: #til <https://developer.mozilla.org/en-US/docs/Glossary/style_origin>
[8/5/2020, 8:41:26 PM] [lhlong]: đúng là tội ác thật :disappointed:
[8/6/2020, 3:21:16 AM] [Graphic D. Thanh]: #til tên Python không phải là con trăn đâu, chính chủ bảo đó là từ tên của một chương trình truyền hình tên “Monty Python’s Flying Circus”
source: <https://simple.wikipedia.org/wiki/Python_(programming_language)>
[8/6/2020, 3:44:49 AM] [ko luong thien]: what if Monty Python is named after the animal :roflrofl:
&gt; When they wanted a name to go before that, John Cleese suggested something slithery like “Python,” while Eric Idle came up with the name “Monty” to suggest a sort of drunken British stereotype.
[8/6/2020, 3:44:51 AM] []: vậy logo của python :lang-python: là hình gì?
[8/6/2020, 3:49:58 AM] [Graphic D. Thanh]: @thien who know :joy:
at least, it’s not “con trăn” :scream:
[8/6/2020, 4:24:37 AM] [unrealhoang]: logo là con trăn mà
[8/6/2020, 5:08:31 AM] []: cái này là nói 1 đường mà làm 1 nẻo :))
[8/6/2020, 8:51:09 AM] []: monty python xem bua lam :))
[8/6/2020, 9:05:43 PM] [ryan.tran]: logo của python là 2 con trăn :lang-python:
[8/6/2020, 9:36:19 PM] [Graphic D. Thanh]: :scream_cat:
[8/6/2020, 9:49:40 PM] [tb]: #til <https://en.wikipedia.org/wiki/Order_of_magnitude#:~:text=If%20numbers%20differ%20by%20one,ten%20times%20the%20smaller%20value.|Order of magnitude>. If numbers differ by one order of magnitude, _x_ is _about_ ten times different in quantity than _y_. If values differ by two orders of magnitude, they differ by a factor of about 100
E.g: The rate of writes is almost two orders of magnitude lower than the rate of reads
[8/7/2020, 6:48:30 AM] [ko luong thien]: #til <https://en.m.wikipedia.org/wiki/Organisation_internationale_de_la_Francophonie|https://en.m.wikipedia.org/wiki/Organisation_internationale_de_la_Francophonie>
[8/7/2020, 8:01:45 AM] [minh]: #til `new Date().toLocaleDateString('vi-VN')`
<https://elijahmanor.com/format-js-dates-and-times>
[8/7/2020, 12:08:07 PM] [huy]: #til Replace *all* occurence of a substring in a string *without* messing up with the crimely regex:
```str.split(&lt;search-term&gt;).join(&lt;replacement&gt;)```
[8/7/2020, 12:13:02 PM] [ko luong thien]: How about using standard replaceAll (<https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/replaceAll>) with polyfill (<https://github.com/zloirock/core-js/blob/v3.6.5/packages/core-js/modules/esnext.string.replace-all.js>)?
[8/7/2020, 12:17:14 PM] [huy]: aint nobody got time for polyfill?
[8/7/2020, 12:20:15 PM] [ko luong thien]: just note that split and join is a little bit slower than the native one (of course, where the native one is available)
[8/7/2020, 3:50:35 PM] [noob]: #til <https://en.wikipedia.org/wiki/Restrict>
[8/7/2020, 6:22:45 PM] []: Just use replace with /g in regex
[8/7/2020, 6:53:15 PM] [unrealhoang]: Clang compile code với restrict có một số case bị lỗi
[8/7/2020, 6:53:59 PM] [unrealhoang]: Vì ít code xài restrict
[8/7/2020, 6:55:14 PM] [unrealhoang]: C semantic khó guarantee exclusive access
[8/7/2020, 9:02:22 PM] [ko luong thien]: #til from SO <https://en.wikipedia.org/wiki/Valency_(linguistics)>
[8/7/2020, 9:42:32 PM] [ko luong thien]: @nguyenhuedang that one got some limitations, like some characters are used as regex pattern. Maybe escaping works but it makes the regex even more complicated..
[8/8/2020, 12:26:52 AM] [noob]: ở C thì đa phần là do developer hết mà :yaomin:, thấy linux source code xài kha khá restrict anh dùng gcc cũng chưa dụng nhiều restrict, để lưu ý xem có vấn đề gì ko
[8/8/2020, 12:27:52 AM] [unrealhoang]: gcc thì hình như không bị bug/ít bug
[8/8/2020, 12:28:25 AM] [unrealhoang]: LLVM thì bị
[8/8/2020, 12:29:11 AM] [unrealhoang]: Tại restrict là native semantic của Rust
[8/8/2020, 12:29:44 AM] [unrealhoang]: Mà không dùng được để optimize perf
[8/8/2020, 12:30:02 AM] [noob]: mục đích restrict ở Rust là gì em :think:
[8/8/2020, 12:31:44 AM] [unrealhoang]: Cái &amp;mut của Rust chính là restrict ấy
[8/8/2020, 12:32:23 AM] [unrealhoang]: Đảm bảo exclusive access (no alias)
[8/8/2020, 12:36:13 AM] [unrealhoang]: <https://stackoverflow.com/questions/57259126/why-does-the-rust-compiler-not-optimize-code-assuming-that-two-mutable-reference|https://stackoverflow.com/questions/57259126/why-does-the-rust-compiler-not-optimize-code-assuming-that-two-mutable-reference>
[8/8/2020, 12:39:09 AM] [unrealhoang]: Ở C thì restrict là optimization hint
[8/8/2020, 12:39:48 AM] [unrealhoang]: Còn Rust thì restrict là language semantic
[8/8/2020, 9:37:12 AM] [ko luong thien]: <https://en.wikipedia.org/wiki/Mach_bands>
[8/9/2020, 1:44:21 AM] [Nguyen Dao]: #til <https://en.wikipedia.org/wiki/Law_of_large_numbers>
đại học xác suất thống kê có dạy cái này k những ae chăm học
[8/9/2020, 1:45:39 AM] [ko luong thien]: có nhé
[8/9/2020, 1:45:47 AM] [ko luong thien]: năm 1 KHTN khoa CNTT
[8/9/2020, 1:46:04 AM] [ko luong thien]: còn cái idea thì hồi cấp 3 có học :think:
[8/9/2020, 1:46:28 AM] [ko luong thien]: Toán cấp 3 hình như cũng có chương/phần về thống kê
[8/9/2020, 1:47:29 AM] [ko luong thien]: hồi đó ông thầy cấp 3 có dạy, có 2 thứ quan trọng trong đánh cược:
1. Logically tỉ lệ thắng phải at least 50%
2. Chơi đủ lâu/nhiều lần
[8/9/2020, 1:49:55 AM] [Nguyen Dao]: Thế chắc hôm đó cúp rồi :))cũng khtn đây :joy:
[8/9/2020, 1:53:15 AM] [minh]: Hình như có học qua. Cái này là dùng mẫu thử trên quần thể để tính phương sai và trung bình của xác suất thì phải
[8/9/2020, 1:53:41 AM] [minh]: Nhớ mang máng thôi chứ vô lớp ngủ suốt :doubt:
[8/9/2020, 9:53:48 AM] [tuan]: #til The Helsinki Bus Station Theory: <http://www.fotocommunity.com/info/Helsinki_Bus_Station_Theory>
[8/9/2020, 1:22:55 PM] [noob]: #til <http://c-faq.com/decl/spiral.anderson.html>
[8/9/2020, 8:21:51 PM] [ledongthuc]: đó là vì sao golang đổi lại cách left-right thôi
```str *[]rune```
[8/10/2020, 7:05:35 AM] [ko luong thien]: Not really a #til but really want to share this again <https://www.justinobeirne.com/new-apple-maps>
Texts like this are what made me rethink my choice of reading. They take days of pure writing and years of experience, and publicly available. Why wasting your time reading empty words that were put together in mere hours.
[8/10/2020, 7:57:19 AM] []: Thank anh, #til, I hate this :"&lt;
[8/10/2020, 8:22:00 AM] []: ```char (*(*x())[])()
x: function returning pointer to array[] of pointer to function returning char
char (*(*x[3])())[5]
x: array[3] of pointer to function returning pointer to array[5] of char```
I hate this :notlikethis:
[8/10/2020, 8:28:28 AM] [ledongthuc]: :roflrofl:
[8/10/2020, 8:28:42 AM] [ledongthuc]: vậy lương mới cao dc
[8/10/2020, 5:34:31 PM] [Cậu Làm Vườn]: This is why when it comes to a new topic, I prefer to find a book instead. The amount of research and time put into books usually make it much better than other writing medium.
[8/11/2020, 2:54:43 AM] [Graphic D. Thanh]: #til <https://developer.mozilla.org/en-US/docs/Web/CSS/:focus-visible>
<https://www.nomensa.com/blog/2013/why-the-focus-indicator-is-important>
[8/11/2020, 4:48:19 AM] [unrealhoang]: @ledongthuc với lại right hand side type dễ parse hơn nhiều
[8/11/2020, 4:00:41 PM] [huy]: #til thẻ `&lt;td&gt;` tức là table data, hôm nay vợ ngồi học HTMl, nói mình mới biết :sweat_smile:
[8/11/2020, 8:34:12 PM] [tay vịn của anh bán chuối - cty A tìm FE]: HTML má
[8/11/2020, 8:56:23 PM] [huy]: gõ nhanh quên bấm shift thôi mà
[8/11/2020, 9:15:34 PM] [Cá Ngừ Hoang]: thế trước anh nghĩ nó là gì :joy:
[8/11/2020, 9:19:03 PM] [__.__Sectumsempra__.__]: Nghĩ là td trong huytd :fast-omg:
[8/11/2020, 10:49:20 PM] [huy]: #til Trước 2017 thì Dropbox dùng S3 để lưu data :fast-omg: sau đó thì tự build data center, tiết kiệm được <https://www.geekwire.com/2018/dropbox-saved-almost-75-million-two-years-building-tech-infrastructure/|một đống tiền>
[8/11/2020, 11:27:08 PM] [Graphic D. Thanh]: Rủ chị Thuý vô đây chơi a Huy :smile:
[8/11/2020, 11:27:55 PM] [huy]: chị bận lắm, ko có time lướt #random đâu :omg:
[8/11/2020, 11:30:46 PM] [Graphic D. Thanh]: :aa_cry:
[8/12/2020, 12:17:05 AM] [huy]: #til Tiền nộp để được tại ngoại, sẽ được refund sau khi mọi sự hoàn thành :omg: lâu giờ đọc báo nghe nộp một triệu đô tại ngoại, cứ tưởng nộp vô là xong luôn
[8/12/2020, 12:18:25 AM] [ledongthuc]: ồ, til, vậy tiền đó giống tiền thế chân ấy nhỉ
[8/12/2020, 12:19:10 AM] [huy]: chính xác là tiền thế chân đó a
[8/12/2020, 12:19:15 AM] [ledongthuc]: :notbad: thế chẳng phải người giàu sẽ dc nhiều công bằng hơn so với người nghèo còn gì
[8/12/2020, 12:19:40 AM] [ledongthuc]: à mà thật ra lấy luôn thì nó vẫn vậy. Ok nay mới biết có vụ trả lại
[8/12/2020, 12:19:40 AM] [huy]: cũng tùy nữa, vì tại ngoại rồi cũng phải bị đem ra xử thôi
[8/12/2020, 1:37:27 AM] [huynh.cam]: thật ra thì trước khi dc xử, nghi phạm vẫn là vô tội, về bản chất ko nên nhốt con người ta
[8/13/2020, 9:13:14 AM] [usbc]: #til _<https://developer.mozilla.org/en-US/docs/Web/JavaScript/EventLoop#:~:text=Zero%20delays&amp;text=Calling%20setTimeout%20with%20a%20delay,waiting%20tasks%20in%20the%20queue.|Calling >`setTimeout`<https://developer.mozilla.org/en-US/docs/Web/JavaScript/EventLoop#:~:text=Zero%20delays&amp;text=Calling%20setTimeout%20with%20a%20delay,waiting%20tasks%20in%20the%20queue.| with a delay of >`0`<https://developer.mozilla.org/en-US/docs/Web/JavaScript/EventLoop#:~:text=Zero%20delays&amp;text=Calling%20setTimeout%20with%20a%20delay,waiting%20tasks%20in%20the%20queue.| (zero) milliseconds doesn’t execute the callback function after the given interval>._.
[8/13/2020, 9:19:24 AM] [ko luong thien]: Bonus nè cưng <https://developer.mozilla.org/en-US/docs/Web/API/Window/requestIdleCallback>
[8/13/2020, 9:20:25 AM] [ko luong thien]: Lần nào chuẩn bị nghỉ việc cũng phải ngồi coi mấy cái này :okay:
[8/13/2020, 9:23:01 AM] [usbc]: :omg:hàng của anh cao cấp quá
[8/13/2020, 9:26:10 AM] [ko luong thien]: sẵn đọc luôn <https://developer.mozilla.org/en-US/docs/Web/API/HTML_DOM_API/Microtask_guide>
[8/13/2020, 9:26:11 AM] [usbc]: à, đại khái cái này là: _This enables developers to perform background and low priority work on the main event loop, without impacting latency-critical events such as animation and input response_
[8/13/2020, 9:26:12 AM] [ko luong thien]: rồi tha hồ pv
[8/13/2020, 9:26:27 AM] [usbc]: ủa, pv ng ta hỏi mấy cai này hả a
[8/13/2020, 9:26:42 AM] [ko luong thien]: mấy chỗ nó ghét em thì nó hỏi :okay:
[8/13/2020, 9:28:46 AM] [usbc]: thế thì những chỗ nó hỏi cái này thì ko vào :yaomin:
[8/13/2020, 9:29:40 AM] [usbc]: để mai em đọc, #javascript vi diệu quá :)) luôn có những thứ mới lạ.
[8/13/2020, 9:41:52 AM] []: mấy kiến thức này cực hiệu quả cho .. kiếm việc mới
[8/13/2020, 8:17:04 PM] [Cậu Làm Vườn]: Event loop là cái fundamental của JS, nên biết vì sớm hay muốn cũng gặp phải vấn đề dính tới nó :v
[8/13/2020, 8:17:11 PM] [Cậu Làm Vườn]: #til creating function is cheap, and one probably should not try to optimize for it until measurable impact surface
[8/13/2020, 8:17:19 PM] [Cậu Làm Vườn]: Relevant:
&gt; the minute you begin worrying about tiny little optimizations, you've already gone down the wrong path.
<https://blog.codinghorror.com/the-sad-tragedy-of-micro-optimization-theater/>
[8/13/2020, 8:17:48 PM] [Cậu Làm Vườn]: Context:
<https://we-build-vn.slack.com/archives/C32HMMUAW/p1597314719387800>
[8/13/2020, 8:20:25 PM] []: đúng, nhưng kiếm việc lúc nào cũng hỏi :))
[8/13/2020, 8:21:30 PM] [usbc]: chắc chuẩn bị CV, rồi ôn lại mấy cái này, chuẩn bị đi pv :))
[8/13/2020, 8:23:26 PM] [usbc]: mà thời buổi giờ, có job nào đâu mà tìm :disappointed:
[8/13/2020, 8:31:21 PM] [minh]: Ngày xưa @snacky có chỉ em dig in vô cái này, mà tới giờ vẫn cứ ngờ ngợ do chưa có project thực tế nào sử dụng tới. Còn chênh vênh phết
[8/13/2020, 8:32:18 PM] [Cậu Làm Vườn]: Có dùng Promise không, có dùng setInterval, setTimeout không? Có dùng rAF hông? Có là dính trong này hết nhé :smoke:
[8/13/2020, 8:32:54 PM] [minh]: Có :smoke: ý là cái khúc microtask á
[8/13/2020, 8:33:00 PM] [usbc]: nào đụng tới rồi dig in vô @monodylh
[8/13/2020, 8:35:08 PM] [tay vịn của anh bán chuối - cty A tìm FE]: :+1:
[8/13/2020, 8:35:15 PM] [ledongthuc]: <http://users.ece.utexas.edu/~adnan/pike.html>
[8/13/2020, 9:01:43 PM] [trexnix]: hơi liên quan, đang đọc phần <http://pages.cs.wisc.edu/~remzi/OSTEP/threads-events.pdf|Event-based Concurrency (chương 33>) cuốn <http://pages.cs.wisc.edu/~remzi/OSTEP/|Operating Systems: Three Easy Pieces>, có nói về Event Loop, cách nó được implement bên dưới, có bài tập để tự implement, thấy khá hay.
[8/16/2020, 10:53:11 PM] [giangnh]: #til <https://www.facebook.com/1440557809300538/posts/3036696136353356/?vh=e&amp;extid=4gvbaixJNL8Ah6g6|https://www.facebook.com/1440557809300538/posts/3036696136353356/?vh=e&amp;extid=4gvbaixJNL8Ah6g6>
[8/17/2020, 12:59:11 AM] [hasagi]: #til [SQL] When using Group By without any order requirements, add extra ORDER BY NULL to eliminate redundant filesort
[8/17/2020, 1:08:45 AM] [ledongthuc]: note: mysql
[8/17/2020, 1:09:55 AM] [hasagi]: yep, mysql
[8/17/2020, 1:09:57 AM] [hasagi]: :vayvay:
[8/17/2020, 1:21:31 AM] [manhdv]: tu MySQL 8.0 thi ko can nua
```Previously (MySQL 5.7 and lower), GROUP BY sorted implicitly under certain conditions. In MySQL 8.0, that no longer occurs, so specifying ORDER BY NULL at the end to suppress implicit sorting (as was done previously) is no longer necessary. However, query results may differ from previous MySQL versions. To produce a given sort order, provide an ORDER BY clause.```
[8/17/2020, 1:24:08 AM] [manhdv]: # til: MySQL's filesort doesn't always use tmp files to sort
```A filesort operation uses temporary disk files as necessary if the result set is too large to fit in memory. ```
[8/17/2020, 1:33:21 AM] [hasagi]: mình vẫn 5.7 nha
[8/17/2020, 1:33:23 AM] [hasagi]: :cry:
[8/17/2020, 1:33:25 AM] [hasagi]: còn xa lắm
[8/17/2020, 1:34:38 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: 5.7 là 7 đó, 1 bước là lên 8
[8/17/2020, 1:37:38 AM] [hasagi]: =)) ý là chưa dám đó a
[8/17/2020, 1:37:50 AM] [hasagi]: mà có safe ko nhỉ
[8/17/2020, 1:37:51 AM] [hasagi]: :think:
[8/17/2020, 1:37:59 AM] [hasagi]: xin ít kinh nghiệm
[8/17/2020, 1:39:06 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: ko biết =))) chắc up thì qa postgres luôn cho rồi :yaomin:
[8/17/2020, 1:55:38 AM] [ledongthuc]: System’s down as plan but unexpected :slightly_smiling_face:
[8/17/2020, 2:27:00 AM] []: #til having Snap images which consume 100% of their filesystem is perfectly acceptable
<https://unix.stackexchange.com/a/406617/181326>
[8/18/2020, 4:59:18 AM] [Cậu Làm Vườn]: #til Coca is a shrub and its leaf contains a small amount of cocaine. Kola is known for its nut, which contains a small dose of caffeine.
I have a coca :point_left: | :point_right:I have a kola
Uh :point_right: :point_left:. Coca-cola.
[8/18/2020, 5:11:13 AM] [ko luong thien]: quào
[8/18/2020, 10:55:43 AM] [huy]: #til Có 2 ông Fujiko Fujio (tác giả Doraemon) - <https://www.mangaupdates.com/authors.html?id=654>
```Hiroshi Fujimoto and Motoo Abiko used to write together under the pen name of "Fujiko Fujio". After many successful comics (among which the notorious Doraemon), they broke up in 1987. Motoo Abiko continued under the name of "Fujiko Fujio (A)" and Hiroshi Fujimoto under the name of "Fujiko Fujio (F)", later renamed to "Fujiko F. Fujio".```
[8/18/2020, 3:09:03 PM] [ko luong thien]: #til <https://quan-cam.com/posts/lamport-timestamp> hay quá @hqc ơi :sosad:
[8/18/2020, 6:43:22 PM] [ko luong thien]: @hqc em hứa sẽ đi ăn sủi cáo ủng hộ bạn Cam :sosad:
[8/18/2020, 7:01:03 PM] [ko luong thien]: #til Spotify is a maitainer of CEF (Chromium Embedded Framework) <https://www.spotify.com/ro/opensource/>
[8/18/2020, 8:51:13 PM] [dangthaison91]: Cho hỏi sư huynh này có phải là Quần Cam ngày xưa trên FU forums k ợ?
[8/18/2020, 9:10:14 PM] [hasagi]: thế Javascript có race condition không?
[8/19/2020, 2:21:55 AM] [huynh.cam]: @thien Mình chỉ scratch dc surface của cái paper thôi :cry:
[8/19/2020, 2:23:20 AM] [huynh.cam]: quào:neutral_face: có một Quần Cam khác nữa hả
[8/19/2020, 6:59:46 AM] [Graphic D. Thanh]: bài viết hay quá! văn phong đơn giản dễ hiểu &lt;3
[8/19/2020, 8:07:41 PM] [tb]: #til <https://itnext.io/as-a-software-developer-why-should-you-care-about-the-monotonic-clock-7d9c8533595c|monotonic clock>, the general rule is that the wall clock is for telling time and the monotonic clock is for measuring time.
updated: more detailed :adore: <https://quan-cam.com/posts/trung-long-dao-va-dong-ho>
[8/19/2020, 8:09:58 PM] [tb]: Ồ, mới xem trong blog Quần Cam cũng có nói tới cái này rồi :omg:
[8/20/2020, 12:29:30 AM] [huy]: #til <https://vi.wikipedia.org/wiki/Quy_lu%E1%BA%ADt_ph%E1%BB%A7_%C4%91%E1%BB%8Bnh> :vn-commies:
[8/20/2020, 6:06:26 PM] [話せる森林]: #til nhiệt độ trung bình cơ thể ở Nhật là 36*C. Nhiệt độ 37*C được coi là bị ốm.
[8/20/2020, 6:07:14 PM] [ko luong thien]: cho cái ref nào anh :adore:
[8/20/2020, 6:08:06 PM] [話せる森林]: Anh hôm nay bị bắt đi khám này
[8/20/2020, 6:09:49 PM] [ko luong thien]: ồ ra thế
[8/20/2020, 6:09:54 PM] [ko luong thien]: mà bình thường anh có đo k
[8/20/2020, 6:10:08 PM] [ko luong thien]: bình thường em đo thấy cũng toàn 36
[8/20/2020, 6:10:49 PM] [minh]: Ở VN cũng vậy mà nghỉ :think:
[8/20/2020, 6:11:07 PM] [話せる森林]: Anh đo mỗi ngày trong 3 tháng nay liền. Ngày nào anh cũng báo là không sốt nhưng mà nay ông này xin nghỉ anh mới hỏi ông sếp thì bị bắt đi khám.
[8/20/2020, 6:11:11 PM] [minh]: Cty em đo nhiệt độ ra 37 là cho về cách ly luôn...
[8/20/2020, 6:12:36 PM] [ko luong thien]: bự - kanji kanji - shi - cái ga tàu - go zai ma sen - chấm
37 kanji no kanji kanji ga a ru ta me, o kanji mi wo kanji ki ta i to kanji i ma su chấm
go kanji kanji wo o ka ke shi ma su ga, yo ro shi ku o kanji i kanji shi ma su.
[8/20/2020, 6:13:01 PM] [ko luong thien]: ồ cũng hợp lý nhỉ
[8/20/2020, 6:13:06 PM] [ko luong thien]: 37 thì đi khám thật
[8/20/2020, 6:13:10 PM] [ko luong thien]: thấy VN vẫn recommend 37 is ok
[8/20/2020, 6:15:50 PM] [minh]: Lúc bình thường em chưa bao giờ đo quá 36.7, nên default cũng tự hiểu qua 37 là sốt :omg:
[8/20/2020, 6:16:07 PM] [話せる森林]: Anh là 36.8
[8/20/2020, 6:18:01 PM] [話せる森林]: 訳 là chữ dịch trong phiên dịch 翻訳 chứ không phải là chữ 駅 trạm trong ga tàu. Khác nhau là bộ thủ ở trước là bộ ngôn 言 thay vì bộ mã 馬.
[8/20/2020, 6:18:18 PM] [ko luong thien]: ồ
[8/20/2020, 6:18:19 PM] [ko luong thien]: :heart: anh
[8/20/2020, 6:21:11 PM] [Cậu Làm Vườn]: Unrelated NSFW fact: sperm creation only happenes at temperature below body temperature. &lt;- This is why animal have such an important and vulnerable organ outside of the body. Better keep it cool down there gentlemen!
&gt; Research has also shown that heat shock can damage male reproduction in warm-blooded animals too, and past work has shown that this leads to infertility in mammals.
One more reason to fight climate change :all-the-things:
[8/20/2020, 6:22:02 PM] [話せる森林]: Chữ đầu là chữ thân 申 trong bính quý canh thân. Nghĩa là nội dung sự kiện.
Chữ thứ hai là chữ tư 思 trong tư duy. Nghĩa là suy nghĩ.
[8/20/2020, 6:23:16 PM] [ko luong thien]: ありがとう先生
[8/20/2020, 6:23:41 PM] [ko luong thien]: 力丸 ủa rikimaru là cái này hở anh :)) thấy bộ gõ nó suggest
[8/20/2020, 6:25:14 PM] [話せる森林]: 大変 tai hên là đại biến. Tức là rất.
申し訳 là giải thích.
ございます là thể lịch sự của です trong câu khẳng định (câu không có động từ) đổi ます thành ません là phủ định.
→申し訳ございません không có gì biện hộ bằng xin lỗi. 大変申し訳ございません bằng rất xin lỗi ở thể lịch sự cao nhất thường nói với bề trên hoặc trong công việc.
[8/20/2020, 6:26:25 PM] [話せる森林]: 力丸 là lực hoàn, là tên một nhân vật trong game teken là cảm hứng của rikimaru trong Dota 2. Nó có nghĩa là Linh hồn mạnh mẽ. Mặc dù triết tự chả có cái gì ra nghĩa đấy cả.
[8/20/2020, 6:27:02 PM] [ko luong thien]: :adore: #til
[8/20/2020, 6:29:42 PM] [話せる森林]: @thien qua Nhật rồi hả em?
[8/20/2020, 6:30:19 PM] [ko luong thien]: chưa anh :okay: biết mỗi hiragana mà đi đâu được :okay:
[8/20/2020, 6:35:21 PM] [話せる森林]: Hồi anh qua đây anh cũng biết mỗi chào.
[8/20/2020, 6:35:48 PM] [話せる森林]: Giờ thì anh biết thêm khoảng 10 cách chào khác nữa
[8/20/2020, 6:37:23 PM] [Cậu Làm Vườn]: No Sịp is the best sịp
[8/20/2020, 6:38:09 PM] [huy]: làm vậy nó xệ xuống đó
[8/20/2020, 6:38:19 PM] [huy]: rồi mai mốt nó xệ xuống tận bàn chân
[8/20/2020, 6:38:21 PM] [huy]: đi ko nổi đâu
[8/20/2020, 6:38:34 PM] [huy]: (hồi nhỏ ông anh hù thế)
[8/20/2020, 6:40:54 PM] [minh]: Vcl :roflrofl:
[8/20/2020, 6:48:29 PM] []: It's not very NSFW until @snacky commented...
[8/20/2020, 7:05:24 PM] [manhdv]: #til `<https://github.com/some-userid.keys>` to get public key registered on GH
[8/20/2020, 7:25:18 PM] [usbc]: a dang hoc tieng Nhat ha @thien
[8/20/2020, 7:25:39 PM] [ko luong thien]: ừa tính từ lúc anh qua Nhật đợt trước thì anh học được 3 năm rồi :okay:
[8/20/2020, 7:26:27 PM] [usbc]: :omg:
[8/20/2020, 9:06:02 PM] [tuan]: bữa em #til cái này thì bị bảo là :ie: :sosad:
[8/21/2020, 12:25:32 AM] [huynh.cam]: :ie: :ie: :flag-ie:
[8/21/2020, 12:45:11 AM] [tb]: #til ADR - Architecture decision records
<https://github.blog/2020-08-13-why-write-adrs/>
<https://github.com/joelparkerhenderson/architecture_decision_record>
[8/21/2020, 2:54:44 AM] [usbc]: #til : <https://stackoverflow.com/questions/4386300/javascript-dom-how-to-remove-all-events-of-a-dom-object|element.cloneNode will destroy all event of component in ReactJS>
[8/21/2020, 2:55:18 AM] [usbc]: và giờ mình đang gặp trouble khi mất hết các event khi cloneNode :okay:
[8/21/2020, 2:56:57 AM] [usbc]: <https://stackoverflow.com/questions/58445212/inline-event-handlers-not-working-after-cloning-in-react-js|đã thử mà ko dc>
[8/21/2020, 4:47:15 AM] [usbc]: <https://developer.mozilla.org/en-US/docs/Web/API/Node/cloneNode>
[8/21/2020, 4:20:44 PM] [ko luong thien]: #til <https://developer.mozilla.org/en-US/docs/Web/API/Element/compositionstart_event> tks @viethungax
The keyword is IME
[8/21/2020, 5:23:47 PM] [Quang Lương]: Til NHẬN tin nhắn ở US mất phí. Culture shock :disappointed_relieved:
[8/21/2020, 6:23:17 PM] [huy]: vậy muốn attack đứa nào thì gửi sms cho đứa đó à :thinkhard:
[8/21/2020, 6:25:57 PM] [Quang Lương]: True. Em không hiểu cái model peering này lắm:wth:
[8/21/2020, 6:31:10 PM] [huy]: giờ mới để ý
[8/21/2020, 6:31:14 PM] [huy]: đúng là bên nhà mạng có ghi vày luôn
[8/21/2020, 6:31:15 PM] [huy]: :omg:
[8/21/2020, 8:19:35 PM] [Thang]: cả gửi và nhận đều mất tiền à
[8/21/2020, 8:32:39 PM] [minh.nguyen]: #til
• `git branch --merged`: List all branches whose tips are reachable from the specified commit (HEAD if not specified).
• `git branch --merged | egrep -v "(^\*|master|staging|blahblah)" | xargs git branch -d` : delete all merged branches on local
[8/22/2020, 7:14:22 PM] [huy]: #til *The Flutie effect* or *Flutie* factor refers to the American phenomenon of having a successful college sports team increase the exposure and prominence of a university.
[8/22/2020, 10:39:09 PM] [huy]: #til Để chụp screenshot ở một vùng màn hình tùy chọn trên Windows thì dùng tổ hợp *Windows + Shift + S*
[8/22/2020, 11:14:24 PM] [ko luong thien]: Hm
[8/22/2020, 11:14:41 PM] [ko luong thien]: Most PC keyboards have Print screen button
[8/22/2020, 11:14:55 PM] [ko luong thien]: why not bind that function to a print-related shortcut like in Linux
[8/22/2020, 11:15:09 PM] [ko luong thien]: Print: take screenshot all screen
Shift + Print: take screenshot an area
[8/22/2020, 11:17:32 PM] [huy]: my keyboard does not have print screen key
[8/22/2020, 11:20:15 PM] [ko luong thien]: There are 2 kinds of keyboards that don't have print screen key:
- Mac ones
- Mech ones
They are not Windows target users I believe :think:
But again, if you use Window Shift S to take screenshot of an area, I suppose Window S to take screenshot of the whole screen?
[8/22/2020, 11:30:36 PM] [typescriptpher]: xài pg thì lên luôn 12.3 đê, bữa mềnh mới thử 25M records write có 23s thoai :vayvay:
[8/23/2020, 2:11:29 AM] [ryan.tran]: I bind Window + Shift + S to take screenshot of an area while using Linux, since I'm used to be a Windows user. Beside that, I use Flameshot to take screen shot since it's allowed quick annotation
[8/23/2020, 6:58:05 AM] [huy]: #til byte first used to represent 'character' of text (see <https://web.archive.org/web/20170403130829/http:/www.bobbemer.com/BYTE.HTM>
[8/23/2020, 7:16:00 AM] [anh bán chuối]: :scream:
[8/23/2020, 9:42:20 PM] []: #til shairport-sync, airplay to your linux server
[8/24/2020, 9:45:57 PM] [huy]: #til Đường mòn Hồ Chí Minh kéo dài sang tận xứ San Diego ở Mỹ quốc <https://www.californiabeaches.com/attraction/ho-chi-minh-trail/|https://www.californiabeaches.com/attraction/ho-chi-minh-trail/>
[8/25/2020, 7:40:31 AM] [Graphic D. Thanh]: #til Brazil mất 10 năm chuẩn bị để giành quyền đăng cai Olympic 2016
[8/26/2020, 4:37:48 PM] [huy]: #til There might be something you don't know about Vim's registers <https://github.com/iggredible/Learn-Vim/blob/master/ch8_registers.md>
[8/26/2020, 4:47:37 PM] [ko luong thien]: More like there are always something we don't know about Vim
[8/26/2020, 4:51:24 PM] [huy]: true :pepegood:
[8/26/2020, 9:22:08 PM] [lhlong]: trên mac là *cmd + shift + 4 :D*
[8/26/2020, 10:05:07 PM] [ZeroX]: #til <https://en.wikipedia.org/wiki/Shoji> Cái cửa lùa của Nhật gọi là Shoji
[8/27/2020, 5:30:27 PM] [alias Trung.Le, as tle]: Aren't they great? I've been writing ADRs for the last 5 years. You will be surprised on how useful they could be, especially for onboarding new devs into teams
[8/27/2020, 11:56:53 PM] [тypesкяipтeя]: <https://spreadprivacy.com/privacy-risks-note-apps/>
[8/27/2020, 11:58:04 PM] [unrealhoang]: @kingbazoka_2 thread, don't spam #til
[8/27/2020, 11:58:31 PM] [huynh.cam]: TIL nước cường toan
<https://vi.wikipedia.org/wiki/N%C6%B0%E1%BB%9Bc_c%C6%B0%E1%BB%9Dng_toan|https://vi.wikipedia.org/wiki/N%C6%B0%E1%BB%9Bc_c%C6%B0%E1%BB%9Dng_toan>
[8/27/2020, 11:58:49 PM] [тypesкяipтeя]: tưởng post vô hội kín té ra pót lộn vô #til
[8/27/2020, 11:58:52 PM] [тypesкяipтeя]: :okay:
[8/27/2020, 11:58:55 PM] [huynh.cam]: TL;DR a xít
[8/28/2020, 12:37:31 AM] [ledongthuc]: :+1:
[8/28/2020, 12:38:11 AM] [ledongthuc]: tldr trộn axit để mỗi loại ăn mòn mỗi thứ khác nhau.
[8/28/2020, 12:38:35 AM] [ledongthuc]: mà vụ giả kim thuật hồi xưa, vàng thì không chế ra, nhưng đặt nhiều nền móng cho ngành hoá nhỉ
[8/28/2020, 2:27:14 AM] []: #til `tac` is :point_up_2: vs `cat` is :point_down:
[8/29/2020, 6:14:03 AM] [тypesкяipтeя]: not exactly a #til, more like #tir
```Routines speed up your life. Time will blow by quicker if you are covered in routines. What is worse, your days will become blurred - each day - too similar to the next - for you brain to hold on to distinct memories. Example: if you drive to work the same way each day - you will often not even remember the drive by 10am. That hour will be gone forever. However, if you were to take BART instead for the first time, that one particular day will last a lifetime. Try moving. Move to a different town, force yourself to get new friends, take three saxophone lessons. Your days will last.
alternative: Alarm beeps, Wake up, drive your kid to school the same way, drive your commute the same way, work with the same people, tell the same jokes, work on similar problems all day, watch netflix all weekend. You will wake up at 45 when someone in your family passes.```
[8/29/2020, 7:57:38 AM] [Cậu Làm Vườn]: I read some tidbits once upon a time about memory. Long lasting memory need anchor - something novel, some thing spontaneous, or more importantly some people to associate it with.
A year filled with these sort of experiences would appear to be vivid. And in contrast, a year filled with routines appear to pass by in a blur, as we'd have a hard time remembering the events in it.
[8/29/2020, 9:11:48 AM] [ledongthuc]: nếu đặt trong ngữ cảnh cty outsource, đấy dc gọi là quy trình. Quy trình sẽ giúp công việc dc speed up, ideally là vậy :slightly_smiling_face:
[8/29/2020, 9:47:44 AM] [usbc]: #til: convert html &lt;-&gt; markdown &lt;-&gt; json <https://github.com/markedjs/marked>
[8/29/2020, 7:42:13 PM] [ko luong thien]: #til <https://fitzgeraldnick.com/2014/01/13/hiding-implementation-details-with-e6-weakmaps.html>
[8/29/2020, 8:14:48 PM] [ZeroX]: #til PhongShading was invented by a Vietnamese Computer Graphic researcher. Hence the name Phong.
<https://en.wikipedia.org/wiki/Phong_shading>
<https://en.wikipedia.org/wiki/Bui_Tuong_Phong>
[8/29/2020, 8:16:16 PM] [Cậu Làm Vườn]: So young :crying:
[8/29/2020, 8:33:33 PM] [ZeroX]: <https://en.wiktionary.org/wiki/the_good_die_young#English>
[8/31/2020, 4:37:09 AM] [dat]: fyi google hq goi la googleplex ~ googolplex = 10^googol
[8/31/2020, 1:54:33 PM] [тypesкяipтeя]: #til Two brains are always better than one brain, don't hesitate to ask for help, especially when there are world-class brains around you. :brain:
[8/31/2020, 4:54:46 PM] [тypesкяipтeя]: #til Functional Component will always re-render <https://egghead.io/lessons/react-prevent-unnecessary-component-rerenders-with-react-memo>
[8/31/2020, 5:17:20 PM] [ko luong thien]: You should say more:
- Both Functional components and Class-based components will always re-render by default (aka if you do nothing to prevent them)
- In Class-based, you do something **internally** (shouldComponentUpdate). In Functional ones, you prevent it **externally**
This is why Functional components should be prefered: it's closer to generic programming. "shouldComponentUpdate" is React-only. Memoizing a function result is generic opimization.
[8/31/2020, 7:57:20 PM] [alias Trung.Le, as tle]: TIL <https://www.lenovo.com/us/en/laptops/thinkpad/thinkpad-x1/X1-Carbon-Gen-8-/p/22TP2X1X1C8> offers Linux as host OS
[8/31/2020, 7:59:34 PM] [ko luong thien]: It's great to see Linux being offered out-of-the-box. IIRC ThinkPad offers Fedora. Dell also has Linux models but Ubuntu-based <https://www.dell.com/en-us/work/shop/overview/cp/linuxsystems>
[8/31/2020, 10:17:55 PM] [ryan.tran]: laptop running ubuntu is the best for development :pepegood:
[8/31/2020, 10:30:52 PM] [alias Trung.Le, as tle]: ubuntu has become so bloated lately
[9/1/2020, 8:01:49 PM] [alias Trung.Le, as tle]: w00t GitHub is going to change default branch to `main`
<https://github.com/github/renaming#from-master-to-main>
[9/1/2020, 8:09:49 PM] [whyn4]: Có cảm giác giống như tìm thêm việc để làm :smile:
[9/2/2020, 7:15:25 AM] [manhdv]: fortune
<https://en.wikipedia.org/wiki/Fortune_(Unix)>
nếu muốn đọc vu vơ thì cái này cũng hay phết :smile:
[9/2/2020, 8:04:56 PM] [Vũ Long]: Hình như chương trình hóa phổ thông có dạy mà :smile:
[9/4/2020, 4:08:36 AM] [minh.nguyen]: #til git bisect: <https://lwn.net/Articles/317154/|https://lwn.net/Articles/317154/>
[9/4/2020, 7:23:34 AM] [ko luong thien]: #til <https://www.typescriptlang.org/docs/handbook/advanced-types.html#conditional-types>
[9/5/2020, 6:54:50 AM] [usbc]: #til <https://open.data.gov.vn/>
[9/5/2020, 6:56:25 AM] [usbc]: Cổng dữ liệu Quốc gia,
[9/5/2020, 9:31:33 AM] [noob]: #til <https://twitter.com/Joel_T_Crofts/status/1301791264539635712>
[9/5/2020, 12:28:42 PM] [ltpquang]: #til ai cũng có thể nhận "đỡ đầu" một kí tự Unicode :smile:
<https://unicode.org/consortium/adopted-characters.html>
[9/5/2020, 5:59:32 PM] [ko luong thien]: @tieubao sponsor cái :flag-vn: cho webuild không :v
[9/6/2020, 2:27:21 AM] [ko luong thien]: #til "Cu li" in Vietnamese is a borrowed word from Coolie <https://en.wikipedia.org/wiki/Coolie>
[9/6/2020, 9:11:02 AM] [ledongthuc]: #til ở châu phi cũng có chim cánh cụt sống.
<https://www.enchantedlearning.com/subjects/birds/printouts/Africanpenguin.shtml|https://www.enchantedlearning.com/subjects/birds/printouts/Africanpenguin.shtml>
[9/6/2020, 7:54:19 PM] []: Not as cute as those in the Nord though
<https://en.wikipedia.org/wiki/African_penguin>
[9/6/2020, 7:56:07 PM] []: <https://www.pinterest.com/pin/734509020459384068/>
[9/6/2020, 10:42:33 PM] [unrealhoang]: www
[9/6/2020, 10:45:11 PM] [Cậu Làm Vườn]: UwU
[9/6/2020, 10:53:39 PM] [Scott Dang]: www
[9/6/2020, 11:12:07 PM] []: TwT
[9/6/2020, 11:35:51 PM] [usbc]: 555 in thailand is hahaha
[9/6/2020, 11:36:33 PM] [unrealhoang]: putang ina is hello :roflrofl:
[9/6/2020, 11:39:40 PM] [unrealhoang]: my fellow Filipinos taught me that :doubt:
[9/7/2020, 11:57:47 AM] [huynh.cam]: TIL <https://en.wikipedia.org/wiki/Chlorodimethylsilane>
[9/7/2020, 6:41:30 PM] [minh]: Dota teach me this one
[9/7/2020, 6:44:58 PM] [ko luong thien]: #til <https://stackoverflow.com/questions/19897374/can-an-html5-localstorage-key-be-any-string>
[9/8/2020, 1:09:46 AM] []: gio moi thay msg
[9/8/2020, 1:09:52 AM] []: de anh coi thu
[9/8/2020, 1:10:04 AM] []: sponsor may cai nay dat’ vai lua chu ko it dau
[9/8/2020, 9:22:28 PM] [minh.nguyen]: #til Document vs Documentation: <https://english.stackexchange.com/questions/233330/how-to-distinguish-between-document-and-documentation>
[9/9/2020, 1:51:04 AM] [noob]: #til <https://www.gnu.org/software/bash/manual/html_node/index.html>
[9/9/2020, 1:51:22 AM] [noob]: gnu có nhiều manuals hay quá :pepegood:
[9/9/2020, 10:20:02 PM] []: #til <https://vi.wikipedia.org/wiki/H%E1%BB%8D_M%E1%BB%99c_lan>
[9/10/2020, 1:07:09 AM] [alias Trung.Le, as tle]: It brings back lots of memory of year 12 Chemistry T_T
[9/10/2020, 1:07:25 AM] [alias Trung.Le, as tle]: back-titration, covalent bond, etc
[9/14/2020, 10:39:29 PM] [ko luong thien]: #til <https://twitter.com/sebmarkbage/status/1096115287781400576> tks @harrisnguyen
[9/14/2020, 10:43:09 PM] [ko luong thien]: #til <https://www.merriam-webster.com/words-at-play/whose-used-for-inanimate-objects>
Merriam Webster lay vi du hay qua :roflrofl:
&gt; The mannequin, whose judgmental pose seems to imply disapproval, doesn't really care which word you use.
[9/15/2020, 12:27:54 AM] [noob]: @viethungax thường khi thằng cha render thì thằng con sẽ render (trừ khi thằng con dùng useMemo wrapper component hay đại loại vậy) vì mỗi lần render props của thằng con bị thay đổi do bản chất của jsx, dùng pattern trên thì pros thằng con không bị thay đổi
[9/15/2020, 12:56:21 AM] [ZeroX]: à, vậy lợi thế gì hơn so với usememo anh nhỉ?
[9/15/2020, 12:58:35 AM] [ZeroX]: dùng ít memory hơn chăng?
[9/15/2020, 1:02:08 AM] [Cậu Làm Vườn]: Lợi là nó diễn ra automatically, không cần sử dụng thêm special syntax gì, không cần rerun child component và hoàn toàn không có bước compare props. Cái này là optimization ở runtime của React, khi work on fiber mà gặp lại đúng cái fiber cũ nó sẽ bailout ngay lập tức.
[9/15/2020, 1:06:48 AM] [Cậu Làm Vườn]: Do trường hợp dùng HOC và render props là rất phổ biến nên họ optimize by default. Xài useMemo thì thật ra cũng vậy, but it's another thing to worry about.
[9/15/2020, 1:48:32 AM] [ZeroX]: ah alright:) đã hiểu, thank anh:)
[9/15/2020, 3:46:35 AM] []: <https://www.emojicode.org/>
[9/15/2020, 7:50:48 PM] []: Should be in #reading, but still <#C16AY670U|til>
&gt; The tendency for managers to repeat such errors in project development led Brooks to quip that his book is called "The Bible of Software Engineering", because "everybody quotes it, some people read it, and a few people go by it"
<https://en.wikipedia.org/wiki/The_Mythical_Man-Month>
[9/17/2020, 10:22:26 AM] [vthang]: <http://www.doanduyhai.com/blog/?p=2058#what_is_sasi|www.doanduyhai.com/blog/?p=2058#what_is_sasi> Dù đọc k hiểu gì mấy nhưng note lại để sau đọc. Với lại kb anh chủ blog là ai nhưng thực sự nể phục
[9/17/2020, 5:41:24 PM] [huy]: anh hai? lam cho datastax ma (datastax is Cassandra company)
[9/17/2020, 5:41:41 PM] [huy]: doc blog tu kha lau roi
[9/17/2020, 6:02:57 PM] [vthang]: Vâng giờ em mới biết đến :D
[9/17/2020, 9:36:33 PM] [ZeroX]: #til <https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ruby>
[9/17/2020, 11:56:01 PM] [lhlong]: notion dont have auto save :disappointed:
[9/18/2020, 2:00:06 AM] [trexnix]: Với lại thấy Notion chậm ghê, đang move dần notes qua Obsidian (dùng thêm Dropbox để sync/backup), đỡ phải bị vendor lock-in.
[9/18/2020, 8:47:06 AM] [alias Trung.Le, as tle]: TIL Rust `target_arch`, `target_endian`
Ref: <https://doc.rust-lang.org/reference/conditional-compilation.html>
[9/18/2020, 2:55:27 PM] [huy]: #til Build docker image trực tiếp trên heroku nhanh hơn build ở local rồi push lên
[9/18/2020, 2:55:52 PM] [huy]: <https://devcenter.heroku.com/articles/build-docker-images-heroku-yml>
[9/20/2020, 9:23:30 AM] [unrealhoang]: #til `:mksession` saves current vim session to current dir -&gt; Session.vim, restart session with `nvim -S Session.vim`
[9/20/2020, 6:10:01 PM] [alias Trung.Le, as tle]: TIL <https://about.gitlab.com/handbook/> is quite a nice doc on how GitLab runs
[9/21/2020, 7:57:42 PM] [Jun]: #til DisplayPort is better than HDMI/VGA/DVI
<https://discussions.apple.com/thread/250523353>
[9/22/2020, 5:53:22 PM] [alias Trung.Le, as tle]: a fun way to learn about HTTPS <https://howhttps.works/why-do-we-need-https/>
[9/23/2020, 1:22:00 AM] [huy]: dude. isn’t it’s been months since the last time you told me about this?
[9/23/2020, 1:22:19 AM] [ko luong thien]: That's "Curve"
[9/23/2020, 1:22:25 AM] [ko luong thien]: This time it's "Arc"
[9/23/2020, 2:36:20 AM] []: Get a room men
[9/23/2020, 5:30:11 AM] [minh]: Today I giác ngộ: Chúng ta có thể bàn về game trong #hobbies thay cho #gaming :nani:
[9/23/2020, 5:32:14 AM] [Cậu Làm Vườn]: #hobbies là safe place cho hội trồng rau, nuôi cá nhé :doubt:
[9/23/2020, 5:32:55 AM] [minh]: Vậy sao không đặt tên là #farmer thay vì #hobbies :doubt:
[9/23/2020, 6:36:16 PM] [話せる森林]: cũng giống như #gaming là safelane cho hội chăn rau nuôi chuối vậy.
[9/23/2020, 7:25:42 PM] [Goose]: cái này phức tạp thấy mồ không bao giờ nhớ nổi Anyway thì MDN viết giải thích cho mấy cái này vẫn rất clear, đặc biệt là bài này
[9/23/2020, 11:04:06 PM] [ko luong thien]: #til <https://stackoverflow.com/questions/3942878/how-to-decide-font-color-in-white-or-black-depending-on-background-color> thanks @snacky
[9/23/2020, 11:20:48 PM] [ko luong thien]: #til In 1500s you can invest in a company so it will have money to wage war and acquire new lands like Indonesia <https://en.wikipedia.org/wiki/Dutch_East_India_Company>
And of course you get a share of the profit :omg:
[9/24/2020, 6:02:11 AM] [quannt]: yeah, siêu bá chủ thế giới
[9/24/2020, 6:02:20 AM] [quannt]: apple amazon thời nay ko là gì
[9/25/2020, 1:55:40 AM] [ko luong thien]: #til Slack làm accessibility tốt thật :think: fully keyboard. Muốn xóa message chỉ cần `up &gt; delete &gt; enter`. Do Slack tự động focus vào message bên dưới nên chỉ cần focus vào message đầu tiên và loop cái `delte &gt; enter`
Đúng ra Slack nên implement thêm Shift + Delete thì sẽ skip confirmation :think:
[9/25/2020, 2:46:33 AM] [ko luong thien]: #til GitHub có table view for CSV <https://github.com/danielmiessler/SecLists/blob/master/Passwords/Default-Credentials/default-passwords.csv>
[9/25/2020, 11:05:36 AM] [Quang Lương]: TIL about taxes in London &amp; cool cities in Europe in general :shake:
[9/25/2020, 11:06:38 AM] [huy]: are these taxes cool? :roflrofl:
[9/25/2020, 11:24:07 AM] [ko luong thien]: Haha
[9/25/2020, 11:24:38 AM] [ko luong thien]: Welcome to socialism, I guess
[9/25/2020, 11:29:20 AM] [ko luong thien]: Btw you should know that some countries still have special benefit for us though. For example the 30-ruling in Netherland could reduce your tax significantly, or in Japan you can apply for a special visa that shorten your time to get permanent resident status.
[9/25/2020, 11:31:56 AM] [ko luong thien]: In Japan you can even get a part of your tax back if you decide to leave the country :sosad:
[9/25/2020, 11:32:59 AM] [Quang Lương]: Ngày trước nhận paycheck ở NYC tưởng mình ngon xong nhìn vào taxes hoá ra broke af:crying: mà giờ tính tax mấy nước châu Âu còn trừ kinh hơn :commies: :crying:
[9/25/2020, 11:33:47 AM] [Quang Lương]: Mà giờ nước nào dễ lấy vợ mua nhà sinh con hả các anh
[9/25/2020, 11:34:20 AM] [ko luong thien]: Bắc Âu với Canada, mà tùy em muốn sống kiểu gì nữa
[9/25/2020, 11:34:55 AM] [ko luong thien]: Thật ra so về saving thì làm engineer thì ở VN là dễ mua nhà nhất :shake:
[9/25/2020, 11:35:33 AM] [ko luong thien]: Nhưng nó có 1 cái limit về income as an engineer, mà anh nghĩ em pass cmnr
[9/25/2020, 11:35:36 AM] [huy]: việt nam nha
[9/25/2020, 11:36:12 AM] [huy]: sống ở vn
[9/25/2020, 11:36:15 AM] [huy]: remote cho tư bản
[9/25/2020, 11:36:19 AM] [huy]: lương tư bản
[9/25/2020, 11:36:23 AM] [huy]: thuế việt nam
[9/25/2020, 11:36:30 AM] [huy]: thời gian tư bản
[9/25/2020, 11:36:47 AM] [huy]: rảnh rang ngồi build side project như mấy anh em webuild
[9/25/2020, 11:37:33 AM] [ko luong thien]: Ờ ha, quên remote :)) thôi ngồi VN remote đi
[9/25/2020, 11:38:05 AM] [ko luong thien]: Mà webuild có mỗi @snacky rảnh mà
[9/25/2020, 11:38:11 AM] [ko luong thien]: Mà huytd có ở VN đâu
[9/25/2020, 11:38:30 AM] [huy]: ngày xưa lúc ở vn a cũng rảnh mà
[9/25/2020, 11:38:35 AM] [huy]: build đủ thứ từ nhỏ giờ
[9/25/2020, 11:38:38 AM] [ko luong thien]: Mấy thanh niên còn lại toàn hoặc là đang thất nghiệp hoặc đang bị hold visa hoặc làm cuối tuần :sosad:
[9/25/2020, 11:38:48 AM] [ko luong thien]: Ờ thì case của anh liên quan gì vn
[9/25/2020, 11:38:54 AM] [ko luong thien]: Anh đi us anh cũng y change
[9/25/2020, 11:39:28 AM] [huy]: one of my oldest side project <https://sites.google.com/site/ridgames/kongpong3d>
[9/25/2020, 11:39:32 AM] [ko luong thien]: Cơ mà ở VN có tiền mà hít CO2 gấp vài lần thì cũng k vui lắm
[9/25/2020, 4:49:50 PM] [Huy]: bây giờ ở đâu ra đường cũng phải đeo khẩu trang mà, so it's not that big of a deal anymore
[9/25/2020, 9:18:37 PM] [ledongthuc]: ^ true, có thằng bạn làm product director cho cty ở Texas, sống ở Phú Mỹ Hưng, khu tách biệt, không khí tách biệt, nhà nó 3 cái máy lọc, cũng tách biệt :okay:
Đủ tiền thì tự tạo ra môi trường cũng dc đấy
[9/26/2020, 12:05:18 AM] [huy]: #til Chúng ta có room <#CBXCKTYV7|rubylang>
[9/26/2020, 1:41:51 AM] [ZeroX]: #til movie restoration is hard
<https://www.youtube.com/watch?v=2AMSHs2adWk>
[9/27/2020, 3:42:23 AM] [huynh.cam]: <https://en.wikipedia.org/wiki/Pox_party|https://en.wikipedia.org/wiki/Pox_party>
[9/27/2020, 3:43:35 AM] [unrealhoang]: :hqc: tính join covid party à :shake:
[9/27/2020, 3:44:07 AM] [huynh.cam]: :shake: hard core lắm
[9/27/2020, 5:43:35 PM] [manhdv]: #til tuy từng thời nhiều ít khác nhau...
<https://www.crunchbase.com/person/alexis-l-quc>
[9/28/2020, 6:37:07 PM] [hasagi]: #til Timo = time and money
[9/28/2020, 8:40:11 PM] [anh]: #til <https://github.com/denysdovhan/wtfjs>
[9/29/2020, 12:15:45 AM] [ledongthuc]: #til Nga đất rộng quá :omg:
nay ngồi dòm bản đồ, Nga to đùng
[9/29/2020, 12:17:05 AM] [unrealhoang]: lớp 6 là được xài atlat rồi :thinkold:
[9/29/2020, 12:17:22 AM] [nghĩ koi]: For real? :pepeandao: :ru:
[9/29/2020, 12:17:40 AM] [ledongthuc]: :okay: dẫu biết nó bự, nhưng nay dòm nó với Thuỵ Điển, thấy nó bự quá đáng
[9/29/2020, 12:18:37 AM] [nghĩ koi]: Nó rộng nhất thế giới anh so với Thụy Điển thì đúng là quá đáng rồi :shake:
[9/29/2020, 12:19:30 AM] [ledongthuc]: TQ cũng bự nhưng so ra vẫn chỉ bằng cái nách của anh Rus :okay:
[9/29/2020, 12:40:26 AM] [dat]: anh coi bản đồ hay coi globe? tại vì projection trên bản đồ nên càng gần cực thì càng to
[9/29/2020, 12:40:54 AM] [unrealhoang]: ^
[9/29/2020, 12:41:00 AM] [dat]: greenland is much smaller than south africa but they’re appeared to be the same size on maps
[9/29/2020, 12:44:43 AM] [ledongthuc]: à thế à, anh coi trên google map. Có khi là do vậy thật
[9/29/2020, 12:55:43 AM] [dat]: yeh có nhiều cách project mà bt người ta dùng mecator chiếu vuông góc
[9/29/2020, 12:56:06 AM] [dat]: dù gì thì Nga cũng massive, nhưng k quá massive :))
[9/29/2020, 12:56:44 AM] [unrealhoang]: yeah
[9/29/2020, 12:56:51 AM] [unrealhoang]: Nga chưa được gấp đôi TQ nữa
[9/29/2020, 12:57:29 AM] [ledongthuc]: :cggt: google lừa mình, google show nó to chắc gấp 3 lần
[9/29/2020, 3:44:04 AM] [tay vịn của anh bán chuối - cty A tìm FE]: <https://en.wikipedia.org/wiki/Mercator_projection#/media/File:Worlds_animate.gif>
[9/29/2020, 3:44:50 AM] [tay vịn của anh bán chuối - cty A tìm FE]: <https://upload.wikimedia.org/wikipedia/commons/e/ee/Worlds_animate.gif>
[9/29/2020, 2:47:49 PM] [ptgamr]: #til: some powerful things you can do with TS 4.1 template literal types
<https://dev.to/phenomnominal/i-need-to-learn-about-typescript-template-literal-types-51po>
[9/29/2020, 8:29:39 PM] [alias Trung.Le, as tle]: Sáng mình có nhận đc email từ Alex gửi cho toàn bộ khách hàng về vụ downtime ở US region. Giờ mới biết CTO của DD là gốc Việt
[9/29/2020, 10:39:48 PM] []: <https://josephg.com/blog/crdts-are-the-future/>
[9/30/2020, 2:10:05 AM] [ko luong thien]: #til the `o'` in `o'clock` is `of the (clock)`
[9/30/2020, 3:11:34 AM] [alias Trung.Le, as tle]: TIL OT
[9/30/2020, 3:48:02 AM] [nakhoa]: <https://github.com/yjs/yjs>
[9/30/2020, 4:19:54 AM] []: never heard anyone says `o'clock` in real life
[9/30/2020, 4:37:33 AM] [ko luong thien]: I guess you never come to Vietnamese public school then :vayvay:
[9/30/2020, 4:38:01 AM] [ko luong thien]: you probably never heard `I'm fine thank you and you` too right :v
[9/30/2020, 4:47:58 AM] [minh.nguyen]: #til Trackpoint on Thinkpad is super convenient.
[9/30/2020, 5:18:40 AM] [unrealhoang]: ủa chứ dùng gì, am/pm hở @khoiracle
[9/30/2020, 5:19:36 AM] [unrealhoang]: hay xài millitary hundred?
[9/30/2020, 5:20:05 AM] [unrealhoang]: meet me at five hundred
[9/30/2020, 5:20:16 AM] []: thấy casually ng ta toàn nói kiểu it's 3
[9/30/2020, 5:20:57 AM] [unrealhoang]: current time thì thường trả lời không unit
[9/30/2020, 5:21:11 AM] []: yeah, còn trong ngữ cảnh muốn nói đến 1 giờ cụ thể
[9/30/2020, 5:21:19 AM] []: thì chắc vẫn dùng
[9/30/2020, 5:21:30 AM] [unrealhoang]: ví dụ I went home at five o’clock chứ nhỉ
[9/30/2020, 5:21:50 AM] []: sure
[9/30/2020, 5:21:53 AM] [unrealhoang]: còn what time is it thì đúng là o’clock hơi dư
[9/30/2020, 5:22:23 AM] []: my bad, chắc mình toàn chơi với các thanh niên trẩu
[9/30/2020, 5:22:32 AM] []: <https://youglish.com/pronounce/o%27clock/english>?
[9/30/2020, 5:22:32 AM] []: có vẻ là dùng cũng bt
[9/30/2020, 5:24:15 AM] [unrealhoang]: yeah, hoặc là dùng để chỉ direction
[9/30/2020, 5:24:37 AM] [unrealhoang]: there’s a beauty at your 10 o’clock
[9/30/2020, 5:27:22 AM] [unrealhoang]: my bad, giờ này chắc không còn ai xài “beauty”
[9/30/2020, 5:27:38 AM] [unrealhoang]: hottie/cuttie :vayvay:
[9/30/2020, 7:50:24 AM] [minh.nguyen]: #til <https://blog.golang.org/ismmkeynote>
[9/30/2020, 10:27:10 AM] [minh.nguyen]: #til String up case methods (`String#upcase` in ruby, or `strings.ToUpper` in Golang) looks up in a giant case mapping table to find corresponding upcased character. All serious programming languages, and systems embed unicode lookup tables inside.
• <https://github.com/golang/go/blob/master/src/unicode/tables.go> =&gt; Lookup table in golang
• <https://github.com/postgres/postgres/blob/master/src/include/common/unicode_norm_table.h> =&gt; Lookup table in Postgres
• Those files are generated from another standard file (<https://unicode.org/faq/casemap_charprop.html#casemap>) - 1.8MB
[9/30/2020, 10:28:47 AM] [huy]: Do you know why?
[9/30/2020, 10:36:24 AM] [minh.nguyen]: Because it's hard? No way to calculate from one case to other cases? See more at <https://www.b-list.org/weblog/2018/nov/26/case/>
[9/30/2020, 10:40:54 AM] [unrealhoang]: Because it’s the only way
[9/30/2020, 10:55:37 AM] [huy]: :pepegood:
[9/30/2020, 10:55:55 AM] [huy]: there's no mathematically way to calculate an upper case of an unicode character
[9/30/2020, 10:56:08 AM] [huy]: unicode is broken, no one can fix it
[9/30/2020, 10:58:24 AM] [unrealhoang]: Because not every language has an `uppercase`
[9/30/2020, 5:52:59 PM] [alias Trung.Le, as tle]: I used to love it so much in the old day when the trackpad was very insensitive
[9/30/2020, 7:02:32 PM] [unrealhoang]: @snacky human languages are broken, fix it first, then you can fix unicode :roflrofl:
[9/30/2020, 7:21:48 PM] [dat]: <https://www.youtube.com/watch?v=-KlDRkcsCZI>
[9/30/2020, 10:25:54 PM] [Jun]: #til Media-types <http://iana.org/assignments/media-types/media-types.xhtml|iana.org/assignments/media-types/media-types.xhtml>
[10/1/2020, 1:00:16 AM] [Goose]: #til Substring operation in Chrome V8 is not an O(n) implementation <https://mrale.ph/blog/2016/11/23/making-less-dart-faster.html>
[10/1/2020, 3:05:12 AM] [hasagi]: ccgv
[10/1/2020, 8:24:50 PM] [ko luong thien]: Có thêm thông tin k bạn :adore: như kiểu format trong file txt như thế nào? Bạn đọc bằng gì thế?
Vote viết blog bạn ơi :adore:
[10/1/2020, 8:47:18 PM] [FULLCLEARONSTAGE]: how about hdf5?
[10/1/2020, 8:47:56 PM] [unrealhoang]: cái này chắc python-related thôi @thien
[10/1/2020, 8:48:35 PM] [unrealhoang]: với ý bạn ấy là read from storage -&gt; python datastructure
[10/1/2020, 8:51:08 PM] [ko luong thien]: Ồ..
[10/1/2020, 8:55:06 PM] []: csv cũng là text file mà, thêm xử lý nữa phải chậm hơn txt chứ sao nhanh hơn được nhỉ
[10/1/2020, 9:07:25 PM] [unrealhoang]: vì nó là binary format :disappointed:
[10/1/2020, 9:07:44 PM] [unrealhoang]: chuyển từ string -&gt; decimal cực kì tốn time
[10/1/2020, 9:16:01 PM] [tl]: kết luận lại là biết thêm định dạng mới npy. và khi xử lý data dạng table, nếu cả team cùng làm liên quan đến python thì nên lưu ở npy sẽ tốt hơn csv.
[10/1/2020, 9:20:02 PM] [minh]: #til .npy ext
[10/1/2020, 9:53:06 PM] [Dz]: đó là nếu dùng thư viện numpy thôi. Vì npy là binary format của numpy
[10/1/2020, 11:08:26 PM] [unrealhoang]: #til: `:goto X` - vim/nvim command to go to X-th byte in the file
[10/2/2020, 6:29:02 AM] []: Shorter version: Xgo
[10/2/2020, 6:42:18 AM] [ko luong thien]: #til <https://www.forbes.com/cloud100> :think:
[10/2/2020, 9:51:00 PM] [huy]: #til Chrome Debugging Protocol is a piece of awesome/powerful thing that came with almost zero documentation and lot of undocumented behaviors :doubt:
[10/3/2020, 12:08:57 AM] [huynh.cam]: #til There is no evidence that sitting too close to TV is bad for the eyes. And ... my world shattered.
<https://kidshealth.org/en/parents/vision-facts-myths.html|https://kidshealth.org/en/parents/vision-facts-myths.html>
[10/3/2020, 12:33:55 AM] [ko luong thien]: Chán nhất là ba má thấy con ngồi gần thì bắt nó ngồi xa ra mà éo nghĩ là nó có khả năng bị cận
[10/3/2020, 12:34:12 AM] [ko luong thien]: Xong càng xa ra càng cố điều tiết cận càng nặng
[10/3/2020, 12:34:15 AM] [ko luong thien]: :facepalm:
[10/3/2020, 12:40:48 AM] [huy]: :shake:
[10/3/2020, 5:18:55 AM] []: Nhung ma co evidence la tre con ngoi trong nha nhieu thi de can hon
[10/3/2020, 5:19:13 AM] []: So voi bon ra vườn ra park chơi
[10/3/2020, 7:25:46 AM] [huy]: <https://en.wikipedia.org/wiki/Jugaad> Indian are so familiar with "unconventional" or "hacking" things, so they have own word for that. In another word, they will just do anything to fullfill their purpose (fake research paper etc)
[10/3/2020, 7:26:00 AM] [huy]: source <https://pulkitsharma07.github.io/2020/10/02/hacktoberfest-india/>
[10/3/2020, 11:36:43 AM] [huy]: #til CSS Grid is f*cking awesome :all-the-things: why don't I use it earlier :okay:
[10/3/2020, 6:45:55 PM] [typescriptpher]: #til <https://developer.mozilla.org/en-US/docs/Web/HTTP/CSP>
[10/3/2020, 8:47:36 PM] [sai]: bài viết đáng suy ngẫm thật
[10/4/2020, 3:58:21 AM] [huy]: <https://blog.jessfraz.com/post/battery-day/> tesla has apple like event for battery called "battery day" :facepalm:
[10/4/2020, 4:54:51 AM] [typescriptpher]: #til <https://developer.mozilla.org/en-US/docs/Web/Security/Subresource_Integrity>
[10/4/2020, 7:15:14 PM] [Graphic D. Thanh]: :shake:
[10/5/2020, 12:34:33 AM] []: cần tut thẻ xanh thụy điển :adore:
[10/5/2020, 12:35:28 AM] [ledongthuc]: confirmed
[10/5/2020, 12:35:46 AM] [huynh.cam]: confirmed
[10/5/2020, 12:35:53 AM] [huynh.cam]: thật ra là 490 ngày
[10/5/2020, 12:36:16 AM] [huynh.cam]: lúc vợ đẻ bạn dc cho thêm 10 ngày để be around
[10/5/2020, 12:37:27 AM] [noob]: đề nghị anh @hqc chia sẻ quá trình đẻ để <@U240KFCLS> thêm gato :troll:
[10/5/2020, 12:37:51 AM] [ledongthuc]: khi trẻ lớn vẫn được nghỉ có lương luôn nha. Nó là cái khác <https://www.forsakringskassan.se/privatpers/foralder/vard_av_barn_vab/!ut/p/z0/04_Sj9CPykssy0xPLMnMz0vMAfIjo8ziTTxcnA3dnQ28_V2dnQwczYw9A31M3QxNAoz1g1Pz9AuyHRUBSsx4rQ!!/>
[10/5/2020, 12:39:04 AM] [dat]: real communism :adore:
[10/5/2020, 12:39:09 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: Bữa xem cái video của ông VinhDK Đan Mạch thấy cũng đc nghỉ quá trời
[10/5/2020, 12:40:07 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: <https://www.youtube.com/watch?v=aKTmF-c9mME>
chắc cũng same same
[10/5/2020, 12:40:17 AM] [huy]: nghỉ nhiều thế còn công việc thì gay cấn, anh em ko áy náy à
[10/5/2020, 12:41:13 AM] [ledongthuc]: thật ra là, mọi người đều dc nghỉ như nhau. Nên áy náy gì đâu. Tiền cho gov trả nên cty ko phải lo.
Kiểu xoay vòng thôi, ông này đẻ, xong thì ông kia đẻ.
[10/5/2020, 12:41:22 AM] [ledongthuc]: nghỉ nhiều thấy tội cty quá thì wfh cũng dc
[10/5/2020, 12:41:44 AM] [ledongthuc]: lúc đó sẽ thấy ngồi ko chán quá, nên làm cho vui. Chứ ko phải làm vì đồng tiền
[10/5/2020, 12:41:48 AM] [Uvuvwevwevwe Onyetenyevwe Ugwemubwem Ossas]: như cái video ông kia nói, thì nếu chồng đi làm, để vợ nghỉ phần chồng thì nghỉ cả đống ngày, tính ra hơn 1 năm :shake:
[10/5/2020, 12:43:49 AM] [ledongthuc]: thật ra 1 phần là vì, bên này sinh đẻ, ông bà không có join. nên ba mẹ phải có nhiều ngày nghỉ để handle dc
[10/5/2020, 12:45:25 AM] [huy]: uhm cũng hợp lý
[10/5/2020, 12:45:27 AM] [huy]: ko có ông bà ở cùng
[10/5/2020, 12:45:32 AM] [huy]: thì vc cũng cần nhiều thời gian
[10/5/2020, 12:45:35 AM] [huy]: mà ông bà ko join à
[10/5/2020, 12:45:37 AM] [huy]: sao quái thế
[10/5/2020, 12:45:48 AM] [ledongthuc]: thường là ko. Ít nhất với người bên này
[10/5/2020, 12:46:16 AM] [ledongthuc]: còn người Châu Á mình ở bên này thường là có. Nhưng thường sau sinh thôi. Chứ trong bệnh viện nó ko cho lúc nhúc người đâu
[10/5/2020, 12:48:39 AM] [huynh.cam]: oh thấy đẻ xong ông bà vô thăm chút xíu rồi "Alright son, tự xử nhé"
[10/5/2020, 12:51:46 AM] [huynh.cam]: còn quá trình đẻ thì hoàn toàn free nhé, toàn hành trình mình chỉ tốn 300 SEK
[10/5/2020, 12:52:07 AM] [huynh.cam]: nghĩ lại sướng quá, để rủ vợ đẻ thêm đứa nữa
[10/5/2020, 12:59:05 AM] [huy]: (cầm cái mấy bill lên, lẩm nhẩm tính lại, tổng 60k, để xuống, ùnfollow thread)
[10/5/2020, 1:01:18 AM] [ledongthuc]: @hqc bữa tui cũng mới bảo vợ: “Bx ơi, bạn anh mới bảo đẻ đã lắm”
Vợ said: “Vậy kêu bạn anh đẻ đi”
=))))
[10/5/2020, 4:00:08 AM] [tl]: #til The T-Shaped Approach To Building a 21st Century Career <https://medium.com/personal-growth/the-t-shaped-approach-to-building-a-21st-century-career-764bdbbcbb4b>
[10/5/2020, 6:35:14 AM] [minh.nguyen]: #til A little :ie:, but truly inspiring: <http://antirez.com/news/134>
&gt; Open source is different, it’s an artifact, it’s a transposition in code of what you really want to do, of what you feel software should be, or just of all your fun and joy, or even anger you are feeling while coding. And you want it to rock, to be perfect, and you can’t sleep at night if there is a fucking heisenbug
[10/6/2020, 6:54:39 AM] [Cậu Làm Vườn]: #til <https://en.wikipedia.org/wiki/Law_of_conservation_of_complexity>
[10/6/2020, 6:54:58 AM] [Cậu Làm Vườn]: aka Tesler's law
[10/6/2020, 11:00:18 AM] [ptgamr]: #til <https://twitter.com/rasbt/status/1313302732879659009?s=20>
[10/6/2020, 11:00:56 AM] [ptgamr]: That is a very clever use of GAN, woow!
[10/6/2020, 11:16:54 AM] [huy]: impressive to see an increasing usage of hardware level AI
[10/6/2020, 11:17:55 AM] [huy]: imagine one day, graphics card can go beyond 4k or 8k by using less GPU power, because they can use AI to improve image quality
[10/6/2020, 11:17:56 AM] [huy]: :shake:
[10/6/2020, 7:40:34 PM] [tay vịn của anh bán chuối - cty A tìm FE]: <https://www.nvidia.com/en-us/geforce/news/nvidia-dlss-2-0-a-big-leap-in-ai-rendering/|https://www.nvidia.com/en-us/geforce/news/nvidia-dlss-2-0-a-big-leap-in-ai-rendering/>
[10/6/2020, 8:23:53 PM] [usbc]: #til <https://stackoverflow.com/questions/37949981/call-child-method-from-parent|call method of children from parent component in react>
[10/6/2020, 8:29:44 PM] [usbc]: this is anti pattern
[10/6/2020, 8:47:43 PM] [usbc]: :omg:
[10/6/2020, 8:48:10 PM] [stronglong]: :clap: quá khủng, bandwidth giảm 100 lần
[10/7/2020, 10:04:24 AM] [typescriptpher]: #til Simple but powerful, mềnh đang xài cái này mần nhiều trò siêu vui <http://jsonpatch.com/> :vayvay:
[10/7/2020, 9:28:32 PM] [tl]: #til business isn’t busyness
[10/7/2020, 10:29:37 PM] [alias Trung.Le, as tle]: rm the f word
[10/7/2020, 11:42:24 PM] [huynh.cam]: :notbad: <http://wiki.open311.org/JSON_and_XML_Conversion/|http://wiki.open311.org/JSON_and_XML_Conversion/>
[10/7/2020, 11:47:22 PM] [huynh.cam]: vậy mà trước giờ toàn đi tự chế
[10/7/2020, 11:49:50 PM] [usbc]: mấy cục này e toàn để backend quy định :))
[10/8/2020, 12:00:21 AM] [usbc]: à mà nảy sinh ra vấn đề, thường thì mọi người để cái cục json này do bên nào quyết định chính nhỉ ? #career-talk
[10/8/2020, 12:06:16 AM] [vthu]: :oh:
[10/8/2020, 12:26:23 AM] [huynh.cam]: API thường mình để ng xài quyết định
[10/8/2020, 1:38:52 AM] [sonhnguyenn]: <http://github.com/basgys/goxml2json|github.com/basgys/goxml2json>
trước giờ xài thằng này đại :))
[10/8/2020, 10:29:09 AM] [tay vịn của anh bán chuối - cty A tìm FE]: #til Stenography :oh::oh::oh:
<https://www.youtube.com/watch?v=egLLsM9wN50>
[10/8/2020, 10:29:21 AM] [tay vịn của anh bán chuối - cty A tìm FE]: <https://www.facebook.com/BuzzFeedVideo/videos/696040218007938>
[10/9/2020, 1:34:23 AM] [tl]: #til Bra–ket notation is a *notation* for linear algebra and linear operators on complex vector spaces together with their dual space both in the finite-dimensional and infinite-dimensional case. It is specifically designed to ease the types of calculations that frequently come up in quantum mechanics. <http://www.physics.unlv.edu/~bernard/phy721_99/tex_notes/node6.html>
[10/9/2020, 2:17:52 AM] [nghĩ koi]: #til bnb is an abbreviation for bed and breakfast :thinkcry:
[10/9/2020, 2:18:30 AM] [sonhnguyenn]: what is the other abbreviation for bnb?
[10/9/2020, 2:19:54 AM] [nghĩ koi]: Never thought of its meaning before :thinkcry:
[10/9/2020, 10:40:53 AM] [typescriptpher]: #til Clik <https://en.wikipedia.org/wiki/Cilk>
[10/10/2020, 2:37:53 AM] [tuan]: #til nodejs load file lâu vl :sosad: prettier chạy thì nhanh nhưng load thì lâu
[10/10/2020, 2:40:36 AM] [ko luong thien]: could that be because of nodejs?
[10/10/2020, 2:41:07 AM] [tuan]: it's actually nodejs
[10/10/2020, 2:41:41 AM] [tuan]: :sosad:
[10/10/2020, 2:46:35 AM] [ko luong thien]: would deno be better? In term of file IO?
[10/10/2020, 2:49:29 AM] [Cậu Làm Vườn]: &gt; it's actually nodejs
How come? :thinkhard:
[10/10/2020, 2:52:08 AM] [tuan]: actually trying to invoke prettier CLI from nvim and notice a significant delay compare to CoC
[10/10/2020, 2:52:12 AM] [Cậu Làm Vườn]: &gt; prettier chạy thì nhanh nhưng load thì lâu
Cái này nghĩa là long startup time?
[10/10/2020, 2:53:51 AM] [tuan]: which lead me to trace down why this happens :sosad: found out that CoC is written in JS, so prettier is only load once.
Invoking prettier via CLI will require nodejs to load all modules and files everytime, which causing the delay
[10/10/2020, 2:54:29 AM] [tuan]: eventually, some folk run prettier as a daemon to avoid load time
<https://github.com/josephfrazier/prettier_d>
fuck my life, trying to get away from js :sosad:
[10/10/2020, 2:54:54 AM] [Cậu Làm Vườn]: That makes sense then
[10/10/2020, 2:54:56 AM] [Cậu Làm Vườn]: <https://github.com/prettier/prettier/issues/443#issuecomment-274698935>
[10/10/2020, 2:55:35 AM] [tuan]: :arggg: cannot afford a 0.3s delay everytime i run format from vim
[10/10/2020, 2:56:47 AM] [Cậu Làm Vườn]: :vscode: :all-the-things:
[10/11/2020, 8:21:30 AM] [Cậu Làm Vườn]: #til <https://developer.mozilla.org/en-US/docs/Web/Security/Subresource_Integrity>
[10/11/2020, 8:22:23 AM] [ko luong thien]: Interesting, could you share how come you learn this?
[10/11/2020, 8:22:50 AM] [ko luong thien]: I learned this myself just several weeks ago thank to @eyeball :adore:
[10/11/2020, 8:23:24 AM] [Cậu Làm Vườn]: <https://shkspr.mobi/blog/2020/10/please-stop-using-cdns-for-external-javascript-libraries/>
:omg:
[10/11/2020, 8:27:23 AM] [ko luong thien]: để cầm đi khoe sếp xin tăng lương. Dạo này nghèo quá
[10/11/2020, 9:02:54 AM] [noob]: hình trên có vụ gì vậy @thien
[10/11/2020, 8:01:54 PM] [tuan]: đã chuyển qua `deno fmt` :sosad: sống chung vs lũ
[10/11/2020, 9:30:05 PM] [ZeroX]: #til <https://lucloi.vn> Knowyourmeme version Vietnam
[10/11/2020, 9:44:22 PM] [Cậu Làm Vườn]: Ồ, deno rust based nên startup nhanh hơn nhỉ? :think:
[10/12/2020, 3:15:53 AM] [hieu.huynh]: <https://fuckyousunday.com/> fck you every fucking day :arggg: fml :okay:
[10/12/2020, 3:20:29 AM] [ko luong thien]: #til <https://stackoverflow.com/a/41108752/6621213>
[10/13/2020, 11:01:01 PM] [huy]: #til Short guide about `tabindex` <https://webaim.org/techniques/keyboard/tabindex>
[10/14/2020, 2:28:13 AM] [minh.nguyen]: #til Thinking for Programmers - <https://channel9.msdn.com/Events/Build/2014/3-642>
[10/15/2020, 6:39:00 AM] []: <https://twitter.com/arurkuo/status/1316217582882521092?s=20>
[10/15/2020, 10:39:21 AM] [tl]: #til <https://en.wikipedia.org/wiki/October_surprise>
[10/15/2020, 7:47:03 PM] [ZeroX]: #til those weird characters at the bottom of the passport are for the machine to read :omg:
<https://en.wikipedia.org/wiki/Machine-readable_passport>
[10/15/2020, 9:45:20 PM] []: #til <https://linux.die.net/man/1/nc>
[10/15/2020, 10:18:26 PM] [FULLCLEARONSTAGE]: #til The origin of dotfiles is due to a bug in `ls`. Unix creators wanted `ls` to hide `.` and `..` but due to a bug in `ls`, it hid all the files and directories starting with a dot. Many people exploited this bug and it became a “feature”.
<http://xahlee.info/UnixResource_dir/writ/unix_origin_of_dot_filename.html>
[10/15/2020, 10:39:30 PM] []: :til-en: Vận động hành lang là một nghề
<https://vi.wikipedia.org/wiki/Vận_động_hành_lang>
[10/16/2020, 3:59:24 AM] [ryan.tran]: Bữa nay mới biết repo này, resource bổ ích
<https://github.com/zalopay-oss>
[10/16/2020, 11:12:54 AM] [cuonglm]: #til creating temporary file POSIXLY via <https://pubs.opengroup.org/onlinepubs/9699919799/functions/mkstemp.html>
```tmpfile=$(echo 'mkstemp(tmpl)' | m4 -D tmpl="${TMPDIR:-/tmp}/tempXXXX")```
[10/21/2020, 9:40:49 AM] [minh.nguyen]: #til Edge đã có mặt trên Linux: <https://www.microsoftedgeinsider.com/en-us/download/>
[10/23/2020, 1:54:09 AM] [typescriptpher]: <https://vi.wikipedia.org/wiki/L%E1%BB%85_c%C6%B0%E1%BB%9Bi_ng%C6%B0%E1%BB%9Di_Vi%E1%BB%87t#Nh%E1%BB%AFng_l%E1%BB%85_c%C6%B0%E1%BB%9Bi_%C4%91%E1%BA%B7c_bi%E1%BB%87t> Quý Thầy sẽ tụng kinh, trì chú, đọc lời dạy của Ðức Phật theo như trong tinh thần của "kinh Thiện Sanh". Sau đó hai người đọc lời phát nguyện trước <https://vi.wikipedia.org/wiki/Tam_b%E1%BA%A3o|Tam bảo> và sau cùng là lễ trao nhẫn cho nhau. Sau phần tụng kinh lễ Phật, cô dâu chú rể đến lễ ông bà và cảm ơn những người tham dự cũng như đón nhận những lời chúc tụng hoặc quà cưới và cuối cùng là tiệc trà Ðạo vị<https://vi.wikipedia.org/wiki/L%E1%BB%85_c%C6%B0%E1%BB%9Bi_ng%C6%B0%E1%BB%9Di_Vi%E1%BB%87t#cite_note-17|[17]>.Lễ cưới tổ chức theo kiểu này gọi là "*Lễ Hằng Thuận*"
[10/23/2020, 1:55:21 AM] [unrealhoang]: thầy đi dạy chưa mà đã lo cưới xin thế này :vayvay:
[10/23/2020, 1:59:44 AM] [typescriptpher]: thầy đang nộp đơn vinuni roài :roflrofl:
[10/24/2020, 7:14:03 AM] [tl]: #til <https://en.wikipedia.org/wiki/Swiss_cheese_model#:~:text=In%20the%20Swiss%20cheese%20model,and%20position%20across%20the%20slices>.
[10/27/2020, 12:05:34 AM] [Jun]: #til <https://github.com/sapegin/mrm>
[10/27/2020, 1:17:56 PM] [huy]: #til <edge://surf>
[10/28/2020, 8:27:17 PM] [stronglong]: getting old ..
[10/28/2020, 8:38:51 PM] [usbc]: #til <https://edition.cnn.com/travel/article/experts-guide-to-italian-hand-gestures/index.html|:pinching_hand:> In Italy this gesture tends to be used in disagreement, frustration, or disbelief and can mean “What do you want?” or “What are you saying?”
[10/28/2020, 9:26:36 PM] [usbc]: ủa ? ai xoá mất comment của mình rồi ?
[10/28/2020, 9:26:45 PM] [usbc]: :sosad:
[10/29/2020, 12:13:00 AM] [usbc]: :100:
[10/29/2020, 12:17:16 PM] [ko luong thien]: dạo này vacation toàn học những cái non tech :roflrofl:
<https://en.wikipedia.org/wiki/History_of_breakfast>
&gt; Breakfast is the first meal taken after rising from a night's sleep, most often eaten in the early morning before undertaking the day's work. It was not until the 15th century that "breakfast" came into use in written English to describe a morning meal,[1]:6 which literally means to break the fasting period of the prior night; in Old English the term was morgenmete meaning "morning meal."[2]
[10/29/2020, 12:21:46 PM] [huy]: technically breakfast có thể dùng để chỉ bữa ăn đầu tiên sau khi nhịn ăn, bất kể sáng trưa chiều tối
[10/29/2020, 12:55:23 PM] [ko luong thien]: Thread
[10/29/2020, 1:35:05 PM] [huy]: thread
[10/29/2020, 10:59:00 PM] [ryan.tran]: #til `sort` trong `python` dùng thuật toán gọi là là `Timsort` <https://en.wikipedia.org/wiki/Timsort>
[10/29/2020, 11:27:12 PM] [tay vịn của anh bán chuối - cty A tìm FE]: V8 cũng xài timsort đó
[10/30/2020, 12:16:05 AM] []: Swift cũng xài Timsort luôn
[10/30/2020, 1:57:00 AM] [nghĩ koi]: Spark cũng rứa :nod:
[10/30/2020, 2:28:28 AM] [usbc]: #til : <https://developer.mozilla.org/en-US/docs/Web/API/Window/postMessage|method safely enables cross-origin communication between Window objects; e.g., between a page and a pop-up that it spawned, or between a page and an iframe embedded within it.>
[10/30/2020, 2:45:27 AM] [ko luong thien]: FYI it's been used for auth :v
[10/30/2020, 2:46:27 AM] [usbc]: quao
[10/30/2020, 2:47:07 AM] [ryan.tran]: <https://en.wikipedia.org/wiki/Tim_Peters_(software_engineer)> :thinkhard:
[10/30/2020, 2:47:35 AM] [usbc]: cái case của em là listener từ cái iframe, mà nó bị block do cái same origin thế là e tìm tới cái này
[10/30/2020, 2:52:46 AM] [usbc]: quao:
&gt; *Always provide a specific `targetOrigin`, not `*`, if you know where the other window’s document should be located. Failing to provide a specific target discloses the data you send to any interested malicious site.*
[10/30/2020, 2:57:52 AM] [ko luong thien]: Yeah
[10/30/2020, 10:31:30 PM] [Graphic D. Thanh]: :thumbsup:
[11/1/2020, 8:23:51 AM] [minh.nguyen]: #til Mẽo có FAANG thì Trung Quốc có BATX: Baidu, Alibaba, Tencent, Xiaomi,
[11/1/2020, 8:26:40 AM] [minh]: đất nước tỉ dân có khác =)))
[11/1/2020, 8:56:41 AM] [huy]: việt nam có gì
[11/1/2020, 8:56:46 AM] [huy]: VV :all-the-things:
[11/1/2020, 8:56:52 AM] [huy]: Vin VNG
[11/1/2020, 8:57:19 AM] [minh]: Viettel :yaomin:
[11/1/2020, 9:02:57 AM] [huy]: VVV
[11/1/2020, 9:13:52 AM] [dat]: FPT
[11/1/2020, 9:13:59 AM] [dat]: :yaomin:
[11/1/2020, 6:25:26 PM] [ngankilo]: tháy VNG to vl ra, khi mà sang TQ thì hơn 300 cty lớn bé doanh thu tầm VNG, thế mới thấy tụi nó nguy hiểm vl
[11/3/2020, 12:44:15 AM] [usbc]: #til : :ie: <https://stackoverflow.com/questions/27928372/react-router-urls-dont-work-when-refreshing-or-writing-manually>
[11/5/2020, 5:59:12 AM] [noob]: #til <https://twitter.com/housecor/status/1324342348667592704>
[11/5/2020, 6:17:52 AM] [Dz]: #til chợ bán side project <https://www.sideprojectors.com/#/>
[11/5/2020, 6:21:00 AM] [xuan]: @snacky
[11/5/2020, 6:21:08 AM] [minh]: @snacky
[11/5/2020, 7:07:21 AM] [unrealhoang]: @snacky
[11/5/2020, 7:43:11 AM] [ko luong thien]: @snacky
[11/5/2020, 9:19:03 AM] [ledongthuc]: #til pawn, rook, knight, bishop…
[11/5/2020, 7:44:55 PM] [Charlie Brown]: #til <https://www.amazon.com/System-Design-Interview-insiders-Second/dp/B08CMF2CQF>
```An effective system design interview gives strong signals about a person's ability to collaborate, to work under pressure, and to resolve ambiguity
constructively. The ability to ask good questions is also an essential skill, and many interviewers specifically look for this skill.
The final design is less important compared to the work you put in the design process. This allows you to demonstrate your design skill, defend your design choices, and respond to feedback in a constructive manner.```
[11/5/2020, 10:37:27 PM] [tb]: Good to read: <https://opensource.guide/>
[11/5/2020, 11:07:13 PM] [vthu]: #til The *nullish coalescing operator (`??`)* is a logical operator that returns its right-hand side operand when its left-hand side operand is `null` or `undefined`, and otherwise returns its left-hand side operand.
[11/6/2020, 12:12:55 AM] [usbc]: #til :ie: Slack doesn’t allow you to block other users.
[11/6/2020, 12:26:53 AM] [minh]: <http://www.reactiongifs.com/r/but-why.gif|http://www.reactiongifs.com/r/but-why.gif>
[11/6/2020, 12:27:30 AM] [usbc]: i tried my best to block @huynhminhtufu in my mind, but i cannt ’cause you’re already in my heart.
[11/6/2020, 12:57:57 AM] []: :roflrofl:
[11/6/2020, 12:58:37 AM] []: same @hsbc
[11/6/2020, 1:02:38 AM] []: bye @huynhminhtufu
[11/6/2020, 1:10:42 AM] [Tu Huynh]: :why:
[11/6/2020, 2:33:53 AM] [__.__Sectumsempra__.__]: Chặn được thì đã chặn @hieu.huynh lâu rồi :doubt:
[11/6/2020, 9:37:44 AM] [noob]: #til function prototype vs function declaration :nod:
[11/8/2020, 7:14:12 AM] [Jun]: please give more detail :V
[11/9/2020, 7:14:38 AM] []: Dùng QuickTime có thể mirror iPhone screen lên MacBook, tiện cho việc sharing screen on call.
[11/9/2020, 7:25:21 AM] [minh]: Mọi người react :ie: nhiều vậy, em xài windoze nên không biết cái này :kappa: thanks for your information
[11/9/2020, 7:29:44 AM] []: :ie: nghĩa là mọi người giờ mới biết đó e
[11/9/2020, 7:29:56 AM] []: còn :baby_chick: là mọi người quá gà đó e
[11/9/2020, 7:30:14 AM] []: :smirk:
[11/9/2020, 7:30:27 AM] [Vy]: anh lại tự luyến
[11/9/2020, 7:33:13 AM] [Tu Huynh]: :roflrofl:
[11/9/2020, 7:53:41 AM] [Beta]: :roflrofl:
[11/9/2020, 8:50:30 AM] [ko luong thien]: #til
[11/10/2020, 12:44:00 AM] [usbc]: vậy thì để hạ cánh được vào tim anh thì đáp ở sân nào ?
[11/10/2020, 2:55:37 AM] [Tu Huynh]: :cggt:
[11/10/2020, 3:20:08 AM] []: lần cuối bạn ơi, mình ko muốn làm thân
[11/10/2020, 4:30:31 AM] []: Bạn có biệt tài nói ngược đúng ko nhỉ
[11/10/2020, 4:34:00 AM] [usbc]: anh noi ngc thi co’ @nghai.dev
[11/10/2020, 8:13:10 AM] [ShinaBR2]: til: <https://wizardzines.com/>
[11/11/2020, 7:33:20 AM] [giangnh]: tin người vkl, tuổi trẻ chưa trải sự đời
[11/11/2020, 7:35:45 AM] [ko luong thien]: em như cái chiếu mới mua :okay:
[11/12/2020, 6:24:31 PM] [Tu Huynh]: #TIL <https://serverfault.com/questions/78048/whats-the-difference-between-ip-address-0-0-0-0-and-127-0-0-1|https://serverfault.com/questions/78048/whats-the-difference-between-ip-address-0-0-0-0-and-127-0-0-1>
[11/12/2020, 7:09:51 PM] [Tu Huynh]: có biết ko mà :ie: hả :chicken: @hsbc
[11/12/2020, 7:43:26 PM] [usbc]: :)) t
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment