This file contains hidden or 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
[ -f /etc/hosts ] && echo "Found" || echo "Not found" |
This file contains hidden or 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
sudo chown -R $(whoami) /usr/local/share/man/man7 | |
brew install wget | |
# ios | |
wget https://sourceforge.net/projects/opencvlibrary/files/opencv-ios/3.4.1/opencv-3.4.1-ios-framework.zip | |
unzip -a opencv-3.4.1-ios-framework.zip | |
cd ios | |
cp -r ./../opencv2.framework ./ | |
cd .. |
This file contains hidden or 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
netstat -vanp tcp | grep 3000 | |
sudo lsof -i tcp:3000 | |
kill -9 PID | |
kill $(lsof -t -i :YOUR_PORT_NUMBER) | |
echo 'free-port() { kill "$(lsof -t -i :$1)"; } | |
kill-port() { kill -kill "$(lsof -t -i :$1)"; }' \ | |
>> ~/.bashrc && source ~/.bashrc |
This file contains hidden or 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
letter-spacing: -17px; | |
line-height: 311px; | |
overflow: hidden; | |
left: -45px; | |
clip: rect(85px 450px 395px 45px); |
This file contains hidden or 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
let n = 0; | |
const pro = () => { | |
return Promise.resolve(++n); | |
}; | |
const stored = pro(); | |
stored.then(a => console.log(a)); | |
stored.then(a => console.log(a)); | |
stored.then(a => console.log(a)); | |
// --------------------- |
This file contains hidden or 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
const START_LISTENING_GAME_STATE_CHANGE = 1000 * 60 * 5; | |
const value = Number(configData && key && configData[key]); | |
const { data: {viewer: {content: {videos = {}} = {}} = {}} = {},} = response; |
This file contains hidden or 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
width: 100, | |
height: scoreboardHeight, | |
borderBottomWidth: scoreboardHeight, | |
borderLeftColor: COLORS.CLEAR_COLOR, | |
borderRightColor: COLORS.CLEAR_COLOR, | |
borderStyle: "solid", | |
position: "absolute" | |
}, | |
leftTrapezoid: { | |
borderLeftWidth: 0, |
This file contains hidden or 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
32 * 20 / 100 = 6.4 === 6.4 * 100 / 32 | |
32 * 90 / 100 = 28.8 === 28.8 * 100 / 32 |