This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if which swiftlint >/dev/null; then | |
swiftlint | |
else | |
echo "warning: SwiftLint not installed, download from https://github.com/realm/SwiftLint" | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
free -h | |
sudo fallocate -l 1G /swapfile | |
sudo chmod 600 /swapfile | |
sudo mkswap /swapfile | |
sudo swapon /swapfile | |
free -h |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var date1 = new Date() | |
var date2 = new Date(2016, 10, 6); // Date(2016, 10, 6) is Nov. 6, 2016 | |
var data1_ms = date1.getTime(); | |
var data2_ms = date2.getTime(); | |
// Then, calculate the milliseconds difference between the two dates. | |
var difference_ms = date2_ms - date1_ms; | |
// Finally, convert the difference back to days in which we should | |
// divide the milliseconds by one day’s milliseconds: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Keybase proof | |
I hereby claim: | |
* I am shaneqi on github. | |
* I am shaneqi (https://keybase.io/shaneqi) on keybase. | |
* I have a public key whose fingerprint is B475 5105 CD5D 9A51 670D 4986 6C74 57BA 133E 4636 | |
To claim this, I am signing this object: |
NewerOlder