YYYY-MM-dd
- @fulano
- @ciclano
#!/bin/bash | |
command_exists () { | |
type "$1" &> /dev/null ; | |
} | |
export GITHUB_REPO="user/repo" | |
export GITHUB_USERNAME=$(cat ~/.githubrc 2> /dev/null | grep user.login | cut -d ":" -f2 | xargs) | |
export GITHUB_PASSWORD=$(cat ~/.githubrc 2> /dev/null | grep user.password | cut -d ":" -f2 | xargs) | |
if [ -z "$GITHUB_USERNAME" ] |
#!/bin/bash | |
export GITHUB_REPO="user/repo" | |
export GITHUB_USERNAME=$(cat ~/.githubrc 2> /dev/null | grep user.login | cut -d ":" -f2 | xargs) | |
export GITHUB_PASSWORD=$(cat ~/.githubrc 2> /dev/null | grep user.password | cut -d ":" -f2 | xargs) | |
if [ -z "$GITHUB_USERNAME" ] | |
then | |
read -p "Type your Github username: " GITHUB_USERNAME | |
echo "user.login: $GITHUB_USERNAME" >> ~/.githubrc | |
fi |
aws iam attach-user-policy --user-name [username] --policy-arn arn:aws:iam::aws:policy/AWSCodeCommitFullAccess | |
aws iam attach-user-policy --user-name [username] --policy-arn arn:aws:iam::aws:policy/IAMReadOnlyAccess | |
aws iam attach-user-policy --user-name [username] --policy-arn arn:aws:iam::aws:policy/IAMSelfManageServiceSpecificCredentials |
/* | |
* Marc's Basic Mashup template | |
* @owner Marc J. Greenberg | |
*/ | |
String.prototype.format = function () { var args = arguments; return this.replace(/\{\{|\}\}|\{(\d+)\}/g, function (m, n) { if (m == "{{") { return "{"; } if (m == "}}") { return "}"; } return args[n]; }); }; | |
String.prototype.startsWith = function (s) { return (this.match("^" + s) == s); }; | |
String.prototype.endsWith = function (s) { return (this.match(s + "$") == s); }; | |
var getQueryVariable = function (variable) { | |
var query = window.location.search.substring(1), vars = query.split('&'); |
// Set Analysis: last 30 days | |
Count({$<DateCreated={">=$(=Date(max(DateCreated)-30, 'DD/MM/YYYY'))"}>}DateCreated) | |
// Set Analysis: all Entries opened today and in the general support category | |
Count({1<[DateCreated.autoCalendar.Date]={'$(=Today())'},[Category]={'General Support'}>}EntryId) | |
// Set Analysis: all Entries opened yesterday and in the general support category | |
Count({1<[DateCreated.autoCalendar.Date]={'$(=Date(Today()-1))'},[Category]={'General Support'}>}EntryId) |
let vStartOf2ndPreviousQuarter = Date(Floor(QuarterStart(Today(), -2)), 'YYYY-MM-DD'); | |
let vStartOf2ndPreviousQuarterNum = Num(Date(Floor(QuarterStart(Today(), -2)), 'YYYY-MM-DD')); | |
let vStartOfPreviousQuarter = Date(Floor(QuarterStart(Today(), -1)), 'YYYY-MM-DD'); | |
let vStartOfPreviousQuarterNum = Num(Date(Floor(QuarterStart(Today(), -1)), 'YYYY-MM-DD')); | |
let vStartOfCurrentQuarter = Date(Floor(QuarterStart(Today())), 'YYYY-MM-DD'); | |
let vStartOfCurrentQuarterNum = Num(Date(Floor(QuarterStart(Today())), 'YYYY-MM-DD')); | |
let vStartOfPreviousMonth = Date(Floor(MonthStart(Today(), -1)), 'YYYY-MM-DD'); |