howto

How to find large files in Git history: a one-liner

One liner: git rev-list --objects --all \ | git cat-file --batch-check='%(objecttype) %(objectname) %(objectsize) %(rest)' \ | sed -n 's/^blob //p' \ | sort --numeric-sort --key=2 \ | cut -c 1-12,41- \ | $(command -v gnumfmt || echo numfmt) --field=2 --to=iec-i --suffix=B --padding=7 --round=nearest Credit SO: https://stackoverflow.com/a/42544963/88814

How to view Git changes on a single branch since its creation

The command: git log --oneline master..feature/some-branch Will show commits on feature branch since it was forked off master. Suppose you have a repo that looks like this: base - A - B - C - D (master) \ \- X - Y - Z (myBranch) Verify the repo status: > git checkout master Already on 'master' > git status ; git log --oneline On branch master nothing to commit, working directory clean d9addce D 110a9ab C 5f3f8db B 0f26e69 A e764ffa base and for myBranch:

How to remove "other search engines" from Chrome

Open the Chrome search engine settings page: chrome://settings/searchEngines Selector for topmost “Remove search engine” button in “Other search engines” list: document.querySelector("body > settings-ui").shadowRoot .querySelector("#main").shadowRoot .querySelector("settings-basic-page").shadowRoot .querySelector("#basicPage > settings-section.expanded > settings-search-page").shadowRoot .querySelector("#pages > settings-subpage > settings-search-engines-page").shadowRoot .querySelector("#otherEngines").shadowRoot .querySelector("#frb0").shadowRoot .querySelector("#delete"); You can repeatedly call the selector and “click()” on the button. document.querySelector("body > settings-ui").shadowRoot .querySelector("#main").shadowRoot .querySelector("settings-basic-page").shadowRoot .querySelector("#basicPage > settings-section.expanded > settings-search-page").shadowRoot .querySelector("#pages > settings-subpage > settings-search-engines-page").

How-to: Git clean up .orig files generated after conflict resolution

Preamble After a merge conflict resolution you're often left with files ending with .orig extension. I have them added to my global .gitignore. Hence I can't easily get rid of them with regular: git clean -fd. Solution git clean has -e argument for a regular expression to match files. To preview what will happen: git clean -e '!*.orig' --dry-run To actually delete the files: git clean -e '!*.orig' -f It's that simple.

Auto Resize Guest VM Desktop running under VMWare

In VMWare Workstation guest OS desktop doesn't auto-resize to fill host OS window after first reboot. Solution.