start new:
tmux
start new with session name:
tmux new -s myname
MSYS2 is a minimalist linux/unix shell environment for Windows.
Quote: "A modern replacement for MSYS bringing recent versions of the GNU toolchains, Git and other common Unix command line tools to the Windows platform"
Do all the steps listed here: http://msys2.github.io/
(troubleshooting guide here: https://github.com/msys2/msys2/wiki/MSYS2-installation )
import _ from 'lodash'; | |
type ConfusingObject = { [key: string]: any }; | |
const processData = (data: ConfusingObject): ConfusingObject => { | |
const deepClonedData = _.cloneDeep(data); | |
_.forEach(deepClonedData, (value, key) => { | |
if (_.isArray(value)) { | |
deepClonedData[key] = _.chain(value).map(_.toString).sort().value(); | |
} else if (_.isPlainObject(value)) { |
type MaybePromise<T> = T | Promise<T>; | |
type ConfusedFunction = <T>(arg: MaybePromise<T>) => Promise<MaybePromise<T>>; | |
const fetchData: ConfusedFunction = async (data) => { | |
const resolveData = await new Promise(resolve => setTimeout(() => resolve(data), 1000)); | |
return typeof resolveData === 'number' ? Promise.resolve(resolveData) : resolveData; | |
}; | |
(async () => { | |
const confusingArray = [fetchData(10), Promise.resolve(20), 30]; |
If a project has to have multiple git repos (e.g. Bitbucket and Github) then it's better that they remain in sync.
Usually this would involve pushing each branch to each repo in turn, but actually Git allows pushing to multiple repos in one go.
If in doubt about what git is doing when you run these commands, just