- Microservices
- Maintaining Legacy code
- Managing tech debt
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
# reset changes to a file | |
# http://stackoverflow.com/a/1817774 | |
# | |
## Clone | |
## Clone only a single (feature) branch (from large repos) | |
git clone <repo> -b <branch> --single-branch --depth=1 | |
# checkout a Pull request locally - https://help.github.com/articles/checking-out-pull-requests-locally/ | |
# Fetch the reference to the pull request based on its ID number, creating a new branch |
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
# add self-signed cert to keychain (used by Chrome etc) | |
# Get the self-signed cert file by clicking on the lock icon in chrome and dragging it to desktop | |
# http://www.robpeck.com/2010/10/google-chrome-mac-os-x-and-self-signed-ssl-certificates/ | |
sudo security add-trusted-cert -d -r trustRoot -k /Library/Keychains/System.keychain <self-signed cert> | |
# ldd equivalent | |
# https://discussions.apple.com/thread/309193?start=0&tstart=0 | |
otool -L <bin> |
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 | |
# scp-speed-test.sh | |
# Author: Alec Jacobson alecjacobsonATgmailDOTcom | |
# http://www.alecjacobson.com/weblog/?p=635 | |
# | |
# Test ssh connection speed by uploading and then downloading a 10000kB test | |
# file (optionally user-specified size) | |
# | |
# Usage: | |
# ./scp-speed-test.sh user@hostname [test file size in kBs] |
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
// To execute Go code, please declare a func main() in a package "main" | |
// given an arbitrary input, find the substring that is closest to, but not greater than 1.00 where a=0.01 and z=0.26 | |
// exit on finding 1.00 | |
// if over or under keep scanning till end of string | |
// ascii only input - check and sanitize | |
// ignore uppercase - only process a-z | |
// g = 20 | |
// i = 25 |
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
# list files from a rpm file on disk without extracting it | |
# source: http://stackoverflow.com/a/18787544 | |
rpmx(){ | |
rpm_file=$1 | |
rpm2cpio $rpm_file | cpio -idmv | |
} | |
# uninstalling package with issues | |
# http://serverfault.com/a/613258 | |
yum clean all && rpm --rebuilddb |
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
// [Config options are not reflected in results · Issue #1183 · dequelabs/axe-core](https://github.com/dequelabs/axe-core/issues/1183) | |
const AxeBuilder = require("axe-webdriverjs") | |
const webDriver = require("selenium-webdriver") | |
// Config options for axe | |
// Ref: https://github.com/dequelabs/axe-core/blob/develop/doc/API.md#options-parameter | |
const axeConfig = { | |
runOnly: { | |
type: "tag", | |
values: ["wcag2aa"] |
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
[ | |
{ | |
"help": "Buttons must have discernible text", | |
"nodes": [ | |
{ | |
"all": [], | |
"failureSummary": "Fix all of the following:\n Element is in tab order and does not have accessible text\n\nFix any of the following:\n Element has a value attribute and the value attribute is empty\n Element has no value attribute or the value attribute is empty\n Element does not have inner text that is visible to screen readers\n aria-label attribute does not exist or is empty\n aria-labelledby attribute does not exist, references elements that do not exist or references elements that are empty\n Element's default semantics were not overridden with role=\"presentation\"\n Element's default semantics were not overridden with role=\"none\"\n Element has no title attribute or the title attribute is empty", | |
"impact": "critical", | |
"html": "<button class=\"ui-datepicker-trigger\" type=\"button\">\n<!-- <img title=\"...\" alt=\"...\" src=\"/redesign/assets/demo-sites/mars/images/calend |
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
// Executed on "Your Account › Your Orders" page | |
// TODO: | |
// * replace console.log with actual summation | |
// * Pagination - navigate to all pages | |
const currency = "CDN" | |
const re = new RegExp('[0-9]+\.[0-9]+') | |
const list = document.getElementsByClassName("value") | |
for (let i of list) { |