See how a minor change to your commit message style can make you a better programmer.
Format: <type>(<scope>): <subject>
<scope>
is optional
; 1 2 3 4 5 6 7 | |
;01234567890123456789012345678901234567890123456789012345678901234567890 | |
;======================================================================= | |
;+---------------------------------------------------------------------+ | |
;| | | |
;| Example using brk() system call for dynamic memory allocations. | | |
;| | | |
;| DON'T CONFUSE that brk() used in C Function is different with brk() | | |
;| systemcall (systemcall 45 for x86 ASM). | | |
;| | |
... | |
{ | |
services.samba = { | |
enable = true; | |
syncPasswordsByPam = true; | |
# You will still need to set up the user accounts to begin with: | |
# $ sudo smbpasswd -a yourusername |
# Alternative to a doubly-nested loop | |
# Imagine I want to perform an operation on a data frame | |
# once for each combination of two variables, such as Country and Year | |
# I can do this with a nested loop, or I can do this with (among other | |
# things) lapply() | |
# Generate random data: | |
allCountries <- LETTERS[1:10] | |
allYears <- 1990:2012 |
' Disables Vanguard from starting when you boot your computer | |
Call CreateObject("Shell.Application").ShellExecute("cmd.exe", "/c ""sc config vgc start= disabled & sc config vgk start= disabled""", "", "runas") |
// ==UserScript== | |
// @name Bilibili VIP | |
// @namespace http://tampermonkey.net/ | |
// @version 0.1 | |
// @description 不给叔叔送钱 | |
// @author You | |
// @match *://www.bilibili.com/bangumi/play/* | |
// @match *://www.bilibili.com/video/* | |
// @connect api.bilibili.com | |
// @icon https://www.bilibili.com/favicon.ico |
export const assign = (...objs) => Object.assign({}, ...objs) | |
export const assign2 = (...objs) => { | |
objs.unshift({}); | |
let len = objs.length; | |
while (--len > 0) | |
for (let i in objs[len]) | |
objs[0][i] = objs[len][i] | |
return objs[0] | |
} | |
// no spread operator overhead, raw arguments access, obj[0] *is* mutated! |
I'm working on a way to connect data to a user interface | |
in a way that is flexible, | |
yet still easy for end-users to work with. | |
This has been one of the biggest challenges for me. | |
## References: | |
* https://hackernoon.com/how-to-decouple-state-and-ui-a-k-a-you-dont-need-componentwillmount-cc90b787aa37 | |
* https://webpack.js.org/guides/code-splitting/ |