This file contains 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
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
public class PercentRounder | |
{ | |
public class PercentInfo | |
{ | |
public int Index; | |
public int Percent; |
This file contains 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 supportsNativeSmoothScroll = 'scrollBehavior' in document.documentElement.style; | |
function scrollToView(elem) { | |
if(supportsNativeSmoothScroll){ | |
// https://caniuse.com/#feat=mdn-api_window_scrollto | |
// As of publish date of this gist, | |
// this is only supported in 52% browsers, | |
// So, the next section (`else{`) is a fallback | |
window.scrollTo({ | |
behavior: 'smooth', |
This file contains 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 | |
TARGET_DIR=/opt/repos/third-parties | |
HG_GIT_VERSION=${1:-default} | |
HG_RELEASE_VERSION=${2:-5.5.2} | |
HG_REPO_VERSION=${3:-stable} | |
TORTOISEHG_VERSION=${4:-stable} | |
update() { | |
# Update packages |