Stash current changes
- git > Stash > Stash (Include Untracked)
Create stash as patch
git stash show "stash@{0}" -p > changes.patchApply patch
| git branch --format ' %(refname:short)' | xargs -n1 -I {} git branch -d {} |
| { | |
| "workbench.startupEditor": "newUntitledFile", | |
| "editor.fontSize": 16, | |
| "editor.lineHeight": 1.8, | |
| "javascript.suggest.autoImports": true, | |
| "javascript.updateImportsOnFileMove.enabled": "always", | |
| "editor.rulers": [ | |
| 80, | |
| 120 | |
| ], |
| git rev-parse --show-toplevel |
| // Main | |
| function combineReducers(reducerDict) { | |
| const _initialState = getInitialState(reducerDict); | |
| return function(state = _initialState, action) { | |
| return Object.keys(reducerDict).reduce((acc, curr) => { | |
| let slice = reducerDict[curr](state[curr], action); | |
| return { ...acc, [curr]: slice }; | |
| }, state); | |
| }; | |
| } |
| const tls = require('tls'); | |
| const fs = require('fs'); | |
| /* | |
| To generate a valid certificate in command line: | |
| openssl req -x509 -newkey rsa:2048 -keyout keytmp.pem -out cert.pem -days 365 | |
| openssl rsa -in keytmp.pem -out key.pem | |
| */ | |
| const options = { |
| 'use strict'; | |
| /** | |
| * Lambda@Edge to log CloudFront event and context. | |
| * Note: this runs in Lambda@Edge which means it runs in a variety | |
| * of regions, the region closest to the browser making the request. | |
| * So be sure and check other regions if you don't see the logs in | |
| * CloudWatch in the region you normally use. | |
| * | |
| * https://medium.com/@jbesw/postcards-from-lambda-the-edge-11a43f215dc1 |
| " FZF.vim now supports this command out of the box | |
| " so this code is no longer needed. | |
| command! -bang -nargs=* Rg | |
| \ call fzf#vim#grep( | |
| \ 'rg --column --line-number --hidden --ignore-case --no-heading --color=always '.shellescape(<q-args>), 1, | |
| \ <bang>0 ? fzf#vim#with_preview({'options': '--delimiter : --nth 4..'}, 'up:60%') | |
| \ : fzf#vim#with_preview({'options': '--delimiter : --nth 4..'}, 'right:50%:hidden', '?'), | |
| \ <bang>0) |
| # This is a sample build configuration for JavaScript. | |
| # Check our guides at https://confluence.atlassian.com/x/14UWN for more examples. | |
| # Only use spaces to indent your .yml configuration. | |
| # ----- | |
| # You can specify a custom docker image from Docker Hub as your build environment. | |
| image: node:8.10 | |
| pipelines: | |
| default: | |
| - step: |
If you are running ArchLinux, run the following command instead (see here for why):
echo fs.inotify.max_user_watches=524288 | sudo tee /etc/sysctl.d/40-max-user-watches.conf && sudo sysctl --system
Then paste it in your terminal and press on enter to run it.