See how a minor change to your commit message style can make you a better programmer.
Format: <type>(<scope>): <subject>
<scope> is optional
| # Works with "darwin" and "linux" | |
| OS := $(shell uname | tr '[:upper:]' '[:lower:]') | |
| ARCH := $(shell uname -m) | |
| # Create a local bin | |
| BIN := /usr/local/bin | |
| # Most of the binaries just grab the latest version. | |
| # For better, or for worse! | |
| TERRAFORM_VERSION := 1.0.6 |
| FROM lambci/lambda:build-python3.7 | |
| WORKDIR /root | |
| RUN yum -y update | |
| RUN curl ftp://ftp.unixodbc.org/pub/unixODBC/unixODBC-2.3.5.tar.gz -O && \ | |
| tar xvzf unixODBC-2.3.5.tar.gz && \ | |
| cd unixODBC-2.3.5 && \ | |
| ./configure --sysconfdir=/opt/python --disable-gui --disable-drivers --enable-iconv --with-iconv-char-enc=UTF8 --with-iconv-ucode-enc=UTF16LE --prefix=/home && \ | |
| make install && \ | |
| cd .. && \ | |
| mv /home/* . && \ |
| # use https://github.com/lambci/docker-lambda to simulate a lambda environment | |
| docker run -it --rm --entrypoint bash -e ODBCINI=/opt/odbc.ini -e ODBCSYSINI=/opt/ lambci/lambda:build-python3.7 | |
| # download and install unixODBC | |
| # http://www.unixodbc.org/download.html | |
| curl ftp://ftp.unixodbc.org/pub/unixODBC/unixODBC-2.3.7.tar.gz -O | |
| tar xzvf unixODBC-2.3.7.tar.gz | |
| cd unixODBC-2.3.7 | |
| ./configure --sysconfdir=/opt --disable-gui --disable-drivers --enable-iconv --with-iconv-char-enc=UTF8 --with-iconv-ucode-enc=UTF16LE --prefix=/opt |
| $schema: 'https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#' | |
| contentVersion: 1.0.0.0 | |
| parameters: | |
| logicAppName1: | |
| type: string | |
| metadata: | |
| description: Name of the Logic App. | |
| logicAppName2: | |
| type: string | |
| metadata: |
| function Prompt { | |
| <# | |
| .Synopsis | |
| Your custom PowerShell prompt | |
| # borrowing heavily from https://dbatools.io/prompt but formatting the execution time without using the DbaTimeSpanPretty C# type | |
| .Description | |
| Custom prompt that includes the following features: |
| #lowercase letters/numbers only | |
| -join ((48..57) + (97..122) | Get-Random -Count 32 | % {[char]$_}) | |
| # all characters | |
| -join ((33..126) | Get-Random -Count 32 | % {[char]$_}) |
| import contextlib | |
| import OpenSSL.crypto | |
| import os | |
| import requests | |
| import ssl | |
| import tempfile | |
| @contextlib.contextmanager | |
| def pfx_to_pem(pfx_path, pfx_password): | |
| ''' Decrypts the .pfx file to be used with requests. ''' |
| <# | |
| .SYNOPSIS | |
| Creates random password string of length 1 to 100. | |
| .DESCRIPTION | |
| Creates random password with ability to choose what characters are in the string and the length, the symbols can be specificlly defined. | |
| .EXAMPLE | |
| New-RandomPassword -Length 8 -Lowercase | |
| In this example, a random string that consists of 8 lowercase charcters will be returned. | |
| .EXAMPLE | |
| New-RandomPassword -Length 15 -Lowercase -Uppercase -Numbers -Symbols |