- Weekly Agenda (created on a different day, and embedded with
/Block Reference
) - [[Morning Questions]]
- {{[[slider]]}} How many hours of sleep did I get?
- What's one thing top of mind today?
- What's the one thing I need to get done today to make progress?
- Review #[[Index: Questions]] #values
- Agenda
- {{[[TODO]]}} Morning walk #goal-health #habit
- {{[[TODO]]}} Check calendar for scheduled events
- {{[[TODO]]}} Morning focus hour
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
traceroute 1.1.1.1 | |
traceroute to 1.1.1.1 (1.1.1.1), 64 hops max, 52 byte packets | |
1 10.249.192.1 (10.249.192.1) 10.257 ms 2.956 ms 3.158 ms | |
2 99-50-95-198.lightspeed.wlfrct.sbcglobal.net (99.50.95.198) 5.318 ms 5.032 ms 4.296 ms | |
3 104-189-208-1.lightspeed.clmboh.sbcglobal.net (104.189.208.1) 7.523 ms 10.622 ms 5.433 ms | |
4 71.151.141.238 (71.151.141.238) 6.387 ms 7.150 ms 7.824 ms | |
5 71.158.32.162 (71.158.32.162) 7.544 ms * * | |
6 71.158.32.171 (71.158.32.171) 7.652 ms 7.426 ms 6.287 ms | |
7 12.83.38.9 (12.83.38.9) 8.661 ms 6.480 ms | |
12.83.38.17 (12.83.38.17) 9.814 ms |
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
require 'pry' | |
require 'socket' | |
class PageMe | |
def initialize(server:, pager:, port: 444) | |
@server = server | |
@pager = pager | |
@port = port | |
end |
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
while true; do date; sleep 5; 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
def | |
puts "zero width space method" | |
end | |
|
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
require 'csv' | |
filename = "/tmp/csv_test.csv" | |
things_to_write = [ | |
{a: "a", b: "b", c: "c"}, | |
{c: "c", b: "b", a: "a", does_not: "exist"}, | |
{a: "a", c: "c"} | |
] | |
CSV.open(filename, "wb", headers: things_to_write.first.keys) do |csv| | |
things_to_write.each do |thing| |
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
# Assumes the database container is named 'db' | |
DOCKER_DB_NAME="$(docker-compose ps -q db)" | |
DB_HOSTNAME=db | |
DB_USER=postgres | |
LOCAL_DUMP_PATH="path/to/local.dump" | |
docker-compose up -d db | |
docker exec -i "${DOCKER_DB_NAME}" pg_restore -C --clean --no-acl --no-owner -U "${DB_USER}" -d "${DB_HOSTNAME}" < "${LOCAL_DUMP_PATH}" | |
docker-compose stop db |
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
gem 'elasticsearch', '>= 1.0.15' | |
gem 'elasticsearch-model' | |
gem 'elasticsearch-rails' | |
gem 'patron' | |
gem 'faraday_middleware-aws-signers-v4' | |
gem 'searchkick' |
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
params = {} | |
params[:start_date] = "2017/08/03" | |
params[:end_date] = "2017/08/05" | |
start_date = Date.parse(params[:start_date]) | |
end_date = Date.parse(params[:end_date]) | |
dates = (start_date..end_date).step(1.day).map { |date| | |
date.strftime('%y-%m-%d') | |
} |
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
company_names = ["Tekfly", "Yabox", "Vinder", "Skiptube", "Fivespan"] | |
company_names.each do |company_name| | |
puts "#{company_name}" | |
end |
NewerOlder