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
3. 2. 1. 7 6 5 6 7 1. | |
7 6 5 4 3 4 2 1. 3. 5. | |
4. 3. 1. 3. 2. 1. 6 1. | |
5. 4. 6. | |
5. 4. 3. 1. 2 7 1. 3. | |
5. 5. 6. 4. 5. 3. 1. 1.. | |
1.. 7. 1.. 7. 1.. 1. 7 5. 2. | |
3. 1. 1.. 7. 6. 7. 3. 5. 6. | |
4. 3. 2. 4. 3. 2. 1. 7 6 5 | |
4 3 2 4 3 2 1. 2. 3. |
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
for dir in */; do; | |
year=`echo $dir | sed 's/\([0-9]\{4\}\).*/\1/'` | |
month=`echo $dir | sed 's/[0-9]\{4\}\([0-9]\{2\}\).*/\1/'` | |
echo "year $year" | |
echo "month $month" | |
exiftool -P -overwrite_original_in_place "-datetimeoriginal=$year:$month:01 12:00:00" "$dir"/* | |
done |
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/heroku_app_env | |
------ | |
#!/bin/bash | |
apps=$(heroku apps --all --json --space trailhead | jq -r '.[] | "\(.name)"' | egrep $1) | |
for app in ${apps[@]}; do | |
echo $app | |
heroku config --app $app | egrep $2 | |
echo |
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
#!/usr/bin/env ruby | |
# this script will delete ECR images that are older than N days | |
require 'date' | |
require 'json' | |
# customize this script | |
repo = 'passport' | |
delete_if_older_than = 180 # days |
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
alias Db.Salesforce.{FieldMapping, Organization, SObjectType} | |
alias Db.Repo | |
import Ecto.Query | |
mappings = | |
from( | |
[fm, o, t, f, af] in FieldMapping.joined_query(), | |
where: t.name == "lead", | |
select: [af.name, t.name, o.code, fragment("group_concat(?)", f.field)], | |
group_by: [af.name, t.name, o.code], |
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
#!/usr/bin/env ruby | |
# this script will delete ECR images that are older than N days | |
require 'date' | |
require 'json' | |
# customize this script | |
repo = ARGV[0] | |
delete_if_older_than = ARGV[1].to_i # days |
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
>> { "foo": "bar" } | |
SyntaxError: unexpected token: ':'[Learn More] debugger eval code:1:7 | |
>> var baz = { "foo": "bar" } | |
undefined | |
>> baz | |
Object { foo: "bar" } |
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
What do accountants suffer from that ordinary people don't? Depreciation | |
Where do homeless accountants live? In a tax shelter | |
It's accrual world | |
How does Santa's accountant value his sleigh? Net Present Value | |
While talking about journal entries "dear journal, been talking about accounting for hours, FML" | |
There's no accounting for taste - or taste for accounting. One of those | |
What did Scotty say when Kirk asked him to process payroll? Account do it captain | |
What does the accountant say before getting off the subway? Mind the GAAP | |
Our accounting team is a credit to the company | |
We're all just COGS in the journal entry |
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
Goal is to get people with the following traits: | |
Good technical communication | |
Good reaction to feedback | |
Eager to learn | |
NOT looking for: | |
ability to solve arbitrary white board problems in a short time | |
ability to write code outside their normal editor | |
memorization of algorithms to common coding challenges | |
These questions require the interviewer to do a little prep work ahead of |
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
result = Message.all.map do |m| | |
body = JSON.parse(m.body) | |
action = m.action | |
date = if m.action == 'new_customer_return' | |
body["customer_return"]["receipt_date"] | |
elsif m.action == 'shipment_shipped' | |
body["shipped_at"] | |
elsif action == 'shipment_canceled' | |
body["canceled_at"] | |
elsif action == 'order_fulfilled' |
NewerOlder