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
function *processObj(obj) { | |
if (!obj) { | |
return; | |
} | |
if (typeof obj === 'object') { | |
for (const key of Object.keys(obj)) { | |
yield *processData(obj[key]); | |
} | |
} else { |
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
function isMediaRecorderMimeTypeSupported(type) { | |
return new Promise((resolve, reject) => { | |
navigator.mediaDevices.getUserMedia({ audio: true }).then(function (stream) { | |
try { | |
var options = {mimeType: type}; | |
new MediaRecorder(stream, options); | |
resolve('supported'); | |
} catch (e) { | |
reject('not supported'); | |
} |
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
"%USERPROFILE%\.babun\cygwin\bin\mintty.exe" /bin/sh -lc 'cd "`cygpath "%V"`"; bash' |
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
# | |
# Place this code to your .profile, .bashrc, .bash_profile or whatever | |
# | |
program_exists () { | |
type "$1" &> /dev/null ; | |
} | |
if program_exists go; then |
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
C:\cygwin\bin\bash.exe --login -i -c 'cd "/cygdrive/c/Users/user1/projects";bash' |
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
#!/bin/bash | |
sed -i "$ a\LS_COLORS='di=0;35' ; export LS_COLORS" ~/.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
// Get latest | |
git pull | |
// Git submit (automatically adds files) | |
git commit -a -m "commit message" | |
git push | |
// Delete branch | |
git branch -d branch_name |
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
((javax.swing.plaf.basic.BasicInternalFrameUI) getUI()).setNorthPane(null); | |
setBorder(null); |
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
find . -name 'core.*' | xargs rm |