Picked up a book cause that worked for C++ and Ruby
It wants me to skip the first section if I'm experienced but I kinda don't want to?
ag -G '\.rb$' --no-multiline -l '(^|^[^#]*(\s+|\.))(module_|class_|instance_)?eval(\s|\()' | | |
awk -F/ '{ count[$1]++ } END { for(tld in count) print tld ": " count[tld]; } ' | | |
sort -n -k 2 -r |
class ClassMethodClient | |
def self.get_thing | |
"thing" | |
end | |
def self.put_thing(thing) | |
nil | |
end | |
end |
#### these options use the eigenclass #### | |
## def on an identifier | |
my_object = Object.new | |
def my_object.foo | |
puts "foo" | |
end |
#!/usr/bin/env ruby | |
require_relative './kv_logger.rb' | |
logger = KVLogger.new(STDOUT) | |
logger.info "sup" | |
logger = logger.with_tags(tag: 'info') | |
logger.warn "with tags!" |
#!/usr/bin/env bash | |
GIT_ROOT=$(git rev-parse --git-dir) | |
rm -rf ${GIT_ROOT}/hooks/* |
#!/usr/bin/env bash | |
bundle exec rubocop --force-exclusion --only-recognized-file-types -A $(git diff --name-only $(git merge-base develop HEAD) | xargs -I _ bash -c 'if test -f _; then echo _; fi') |
// curl https://api.weather.gov/alerts/active?point=40.7892,-124.1645 | |
{ | |
"@context": [ | |
"https://geojson.org/geojson-ld/geojson-context.jsonld", | |
{ | |
"@version": "1.1", | |
"wx": "https://api.weather.gov/ontology#", | |
"@vocab": "https://api.weather.gov/ontology#" | |
} |
package main | |
import ( | |
"fmt" | |
) | |
// an object is a function that returns its methods, which have names | |
type object func() map[string]method | |
type method func(args ...interface{}) []interface{} |
[Unit] | |
Description=Create docker network for nitter | |
Conflicts=umount.target | |
Requires=systemd-udevd.service | |
After=systemd-udevd.service | |
Before=nitter-server.service | |
Before=nitter-redis.service | |
[Service] | |
Type=oneshot |