OSDN Git Service

Regular updates
authorErik <erikgronwal@users.osdn.me>
Tue, 14 Mar 2023 14:55:05 +0000 (23:55 +0900)
committerErik <erikgronwal@users.osdn.me>
Tue, 14 Mar 2023 14:55:05 +0000 (23:55 +0900)
72 files changed:
_data/google_analytics.yml
angularjs.md
ansible.md
applinks.md
arel.md
bookshelf.md
browser-sync.md
browserify.md
bundler.md
capybara.md
cask-index.md
circle.md
clip.md
command_line.md
commander.js.md
devise.md
divshot.md
do.md
elixir-metaprogramming.md
emacs.md
ember.md
express.md
firefox.md
flux.md
git-tricks.md
google_analytics.md
gulp.md
hledger.md
ios-provision.md
koa.md
kramdown.md
ledger-examples.md
ledger-format.md
ledger-periods.md
ledger-query.md
less.md
linux.md
lua.md
machinist.md
make-assets.md
makefile.md
middleman.md
minitest.md
mocha-html.md
mocha-tdd.md
mocha.md
modernizr.md
nodejs-fs.md
nodejs-process.md
nodejs.md
nopt.md
pacman.md
parsimmon.md
perl-pie.md
phoenix-ecto@1.2.md
plantuml.md
postgresql.md
projectionist.md
pry.md
python.md
qjs.md
ractive.md
rails-controllers.md
rails-forms.md
rails-helpers.md
rails-i18n.md
rails-migrations.md
rails-plugins.md
rails-routes.md
rails-tricks.md
tape.md
weinre.md

index b8f12bb..abe0409 100644 (file)
@@ -1,3 +1,4 @@
 enabled: true
 hostname: devhints.io
-id: "UA-106902774-1"
+id: "G-N7TC6B227L"
+# id: "UA-106902774-1"
index c028555..e41ef7b 100644 (file)
@@ -1,7 +1,19 @@
 ---
 title: Angular.js
 category: JavaScript libraries
+tags: [Archived]
+archived: This describes an older version of Angular.
+layout: 2017/sheet
 ---
+
+### About
+{: .-intro}
+
+ * <https://github.com/angular/angular-seed>
+ * <https://angularjs.org/>
+
+### ng-app
+
 ```html
     <html ng-app="nameApp">
 ```
@@ -88,7 +100,3 @@ In HTML will use `<name></name>` to render your template `<h1>Hello</h1>`
         })
     });
 ```
-References:
-
- * https://github.com/angular/angular-seed
- * https://angularjs.org/
index 5a311d1..22d1431 100644 (file)
@@ -1,12 +1,18 @@
 ---
 title: Ansible
 category: Ansible
+layout: 2017/sheet
 ---
 
 {% raw %}
 
 ## Getting started
 
+### About
+{: .-intro}
+
+- <https://www.ansible.com/>
+
 ### Hosts
 
     $ sudo mkdir /etc/ansible
@@ -20,7 +26,9 @@ category: Ansible
 
     $ ansible-playbook playbook.yml
 
-## Tasks
+## Playbook files
+
+### Tasks
 
     - hosts: all
       user: root
@@ -39,7 +47,7 @@ category: Ansible
     handlers:
       - include: db.yml user=timmy
 
-## Handlers
+### Handlers
 
     handlers:
       - name: start apache2
@@ -51,7 +59,7 @@ category: Ansible
         notify:
           - start apache2
 
-## Vars
+### Vars
 
     - host: lol
       vars_files:
@@ -63,7 +71,7 @@ category: Ansible
           file: state=directory path=${project_root}/home/.ssh/
           only_if: "$vm == 0"
 
-## Roles
+### Roles
 
     - host: xxx
       roles:
@@ -91,9 +99,4 @@ category: Ansible
     vars:
       local_home: "{{ lookup('env','HOME') }}"
 
-## References
-
-  * [Intro](http://www.ansibleworks.com/docs/intro_configuration.html)
-  * [Modules](http://www.ansibleworks.com/docs/modules.html)
-
 {% endraw %}
index 432a9b4..29e4f1c 100644 (file)
@@ -1,8 +1,14 @@
 ---
 title: Applinks
 category: HTML
+layout: 2017/sheet
 ---
 
+### About
+
+- <http://applinks.org/>
+
+### Applinks
 
     <meta property="al:ios:url" content="applinks://docs" />
     <meta property="al:ios:app_store_id" content="12345" />
diff --git a/arel.md b/arel.md
index 2d5b35d..58e24fc 100644 (file)
--- a/arel.md
+++ b/arel.md
@@ -1,8 +1,16 @@
 ---
 title: Arel
 category: Rails
+layout: 2017/sheet
 ---
 
+### About
+{: .-intro}
+
+Arel is an SQL abstraction library built into Ruby on Rails.
+
+* <https://github.com/rails/arel>
+
 ### Tables
 
 ```rb
@@ -123,7 +131,3 @@ all_time      = photos_with_credits.count
 this_month    = photos_with_credits.where(photos[:created_at].gteq(Date.today.beginning_of_month))
 recent_photos = photos_with_credits.where(photos[:created_at].gteq(Date.today.beginning_of_month)).limit(5)
 ```
-
-## Reference
-
-* <http://github.com/rails/arel>
index 2c9f2c4..1b70e59 100644 (file)
@@ -1,11 +1,13 @@
 ---
 title: Bookshelf.js
 category: JavaScript libraries
+layout: 2017/sheet
 ---
 
 Model
 -----
 
+### Model
 ```js
 Summary = bookshelf.Model.extend({
   tableName: 'summaries',
index 459a908..577b082 100644 (file)
@@ -1,12 +1,15 @@
 ---
 title: Browsersync
 category: JavaScript libraries
+layout: 2017/sheet
 ---
 
-```
-npm i -g browser-sync
-```
-{:.terminal}
+### About
+{: .-intro}
+
+`npm i -g browser-sync`
+
+* [browsersync.io](https://browsersync.io)
 
 ### Start a server
 
@@ -20,7 +23,3 @@ browser-sync start --server <path> --files='**/*.html, **/*.css'
   --port=N
   --proxy="http://127.0.0.1:3000"
 ```
-
-### Reference
-
-* [browsersync.io](http://browsersync.io)
index 09385a9..d820266 100644 (file)
@@ -1,8 +1,20 @@
 ---
 title: Browserify
 category: JavaScript libraries
+layout: 2017/sheet
+tags: [Archived]
+archived: Browserify has not been in active development.
 ---
 
+### About
+{: .-intro}
+
+Browserify is a bundler for JavaScript.
+
+- <https://browserify.org/>
+
+### Usage
+
     browserify input.js
       -o output.js
       -t coffeeify
index 0d33b00..96fefbe 100644 (file)
@@ -1,6 +1,7 @@
 ---
 title: Bundler
 category: Ruby
+layout: 2017/sheet
 ---
 
 ### Commands
index 8dd4973..04b0737 100644 (file)
@@ -122,11 +122,11 @@ In RSpec, you can use `page.should` assertions.
 expect(page).to have_no_button('Save')   # OK
 ```
 ```ruby
-expect(page).not_to have_button('Save')  # Bad
+expect(page).not_to have_button('Save')  # OK
+```
+```ruby
+!expect(page).to have_button('Save')  # Bad
 ```
-
-Use `should have_no_*` versions with RSpec matchers because
-`should_not have_*` doesn't wait for a timeout from the driver.
 
 ## RSpec
 
index bbdc7d4..e098b01 100644 (file)
@@ -1,10 +1,11 @@
 ---
 title: Caskroom index
+layout: 2017/sheet
+tags: [Archived]
+archived: This sheet may have outdated information.
 ---
 
 
-# Caskroom
-
 
 #### A
 
index 0f6cf36..5c8c557 100644 (file)
--- a/circle.md
+++ b/circle.md
@@ -1,9 +1,15 @@
 ---
 title: CircleCI
 category: Devops
+layout: 2017/sheet
 ---
 
-## circle.yml
+### About
+{: .-intro}
+
+- <https://circleci.com/docs/config-sample>
+
+### circle.yml
 
 * __machine__: adjusting the VM to your preferences and requirements
 * __checkout__: checking out and cloning your git repo
@@ -14,7 +20,7 @@ category: Devops
 
 See: <https://circleci.com/docs/configuration>
 
-## Sample
+### Sample
 
 ```yml
 ## Customize the test machine
@@ -91,5 +97,3 @@ notify:
     # A list of hashes representing hooks. Only the url field is supported.
     - url: https://someurl.com/hooks/circle
 ```
-
-See: <https://circleci.com/docs/config-sample>
diff --git a/clip.md b/clip.md
index 5337d38..b228f20 100644 (file)
--- a/clip.md
+++ b/clip.md
@@ -2,7 +2,6 @@
 title: Command Line Interface Pages
 category: CLI
 layout: 2017/sheet
-tags: [Featured]
 updated: 2023-02-23
 keywords:
   - CLI
index 36cba17..b2d8296 100644 (file)
@@ -1,8 +1,12 @@
 ---
 title: Command line stuff
+layout: 2017/sheet
 ---
 
 ## List (ls)
+{: .-three-column}
+
+### Usage
 
     ls [options] [paths]
 
@@ -18,14 +22,12 @@ title: Command line stuff
 |---
 | `-F` | Add / after directories |
 | `-G` | Color |
-{:.shortcuts}
 
 ### Options
 
 | `-R` | Recurse |
 | `-a` | Include hidden (dotfiles) |
 | `-A` | Include hidden (but not . and ..) |
-{:.shortcuts}
 
 ### Sorting
 
@@ -39,11 +41,11 @@ title: Command line stuff
 | `-c` | sort by time status was changed |
 |---
 | `-h` | Human-readable size (3k) |
-{:.shortcuts}
-
-<br>
 
 ## Tail
+{: .-three-column}
+
+### Usage
 
     tail [-F | -f | -r] [-bN | -cN | -nN] [file ...]
 
@@ -52,7 +54,6 @@ title: Command line stuff
 | `-f` | follow |
 | `-F` | follow by filename (accounts for log rotation) |
 | `-r` | Reverse order |
-{:.shortcuts}
 
 ### Options
 
@@ -60,11 +61,13 @@ title: Command line stuff
 | `-cN` | N bytes |
 | `-nN` | N lines |
 | `+N`  | Start from line N |
-{:.shortcuts}
 
 <br>
 
 ## Sudo
+{: .-three-column}
+
+### Usage
 
 ```
 sudo [options] <command>
@@ -73,7 +76,6 @@ sudo [options] <command>
 ### Listing
 
 | `-l` | List allowed commands |
-{:.shortcuts}
 
 ### Options
 
@@ -84,17 +86,14 @@ sudo [options] <command>
 | `-n` | Don't prompt for password |
 | `-P` | Preserve group vector |
 | `-S` | Read password from stdin |
-{:.shortcuts}
 
 ### File descriptors
 
 | `-C fd` | Close all open file descriptors |
-{:.shortcuts}
 
 ### Prompt
 
 | `-p prompt` | Custom prompt (-p "%p password:") |
-{:.shortcuts}
 
 ### Interactive
 
@@ -105,38 +104,33 @@ sudo [options] <command>
 |----
 | `-u user` | run as this user |
 | `-g group` | run as this group |
-{:.shortcuts}
 
 ### Timestamp
 
 | `-v` | revalidate timestamp for 5 mins |
 | `-k` | invalidate timestamp |
 | `-K` | just like -k |
-{:.shortcuts}
-
-<br>
 
 ## wc (Word count)
+{: .-three-column}
+
+### wc
 
 ```
 ... | wc [options]
 ```
 
+### Options
+
 | `-c` | Bytes |
 | `-l` | Lines |
 | `-m` | Characters (incl multi-byte) |
 | `-w` | Words |
-{:.shortcuts}
-
-<br>
-
-## Search-and-replace in all files
-
-    perl -p -i -e 's/hello/HELLO/g' **/*
-
-<br>
 
 ## Grep
+{: .-three-column}
+
+### Usage
 
 ```
 grep [options] [pattern] [file ...]
@@ -164,9 +158,15 @@ grep [options] [pattern] [file ...]
 | `-r, -R` | --recursive |
 | `-v` | --invert-match |
 | `-i` | --ignore-case |
-{:.shortcuts}
 
 ### Synonyms
 
     egrep  =>  grep -E
     fgrep  =>  grep -F
+
+## Other recipes
+{: .-three-column}
+
+### Search-and-replace in all files
+
+    perl -p -i -e 's/hello/HELLO/g' **/*
index 444dba6..bcde24c 100644 (file)
@@ -1,8 +1,14 @@
 ---
 title: Commander.js
 category: JavaScript libraries
+layout: 2017/sheet
 ---
 
+### About
+{: .-intro}
+
+- <https://github.com/tj/commander.js/>
+
 ### Initialize
 
     var cli = require('commander');
index 59dba01..f10b6f1 100644 (file)
--- a/devise.md
+++ b/devise.md
@@ -1,12 +1,17 @@
 ---
 title: Devise
+layout: 2017/sheet
 ---
 
+### About
+{: .-intro}
+
 [Devise](https://github.com/plataformatec/devise) is a flexible authentication 
 gem.
 
-Installation
-------------
+- <https://github.com/plataformatec/devise>
+
+### Installation
 
 Rails 3: Add the following to your Gemfile
 
@@ -27,8 +32,7 @@ Generate devise for your model
 
     $ rails generate devise:views
 
-Helpers
--------
+### Helpers
 
     user_signed_in?
     current_user
@@ -38,8 +42,7 @@ Helpers
     edit_user_registration_path (Edit registration)
     new_user_registration_path (Register new user)
 
-Controller stuff
-----------------
+### Controller stuff
 
     before_filter :authenticate_user!
 
@@ -123,8 +126,11 @@ Routing
 Test helpers
 ------------
 
+### Test helpers
+
     include Devise::TestHelpers
-    https://github.com/plataformatec/devise/blob/1094ba65aac1d37713f2cba71f9edad76b5ca274/lib/devise/test_helpers.rb
 
     sign_in @user
     sign_out @user
+
+See: <https://github.com/plataformatec/devise/blob/1094ba65aac1d37713f2cba71f9edad76b5ca274/lib/devise/test_helpers.rb>
index c1d6511..62f1fe5 100644 (file)
@@ -1,9 +1,18 @@
 ---
 title: Divshot
+layout: 2017/sheet
+tags: [Archived]
+archived: Divshot is no longer in operation.
 ---
 
 ## Getting started
 
+### About
+
+Divshot was a static hosting platform.
+
+- <https://divshot.com/>
+
 ### Install divshot-cli
 
 ```
diff --git a/do.md b/do.md
index 008fadb..6be106b 100644 (file)
--- a/do.md
+++ b/do.md
@@ -1,8 +1,12 @@
 ---
 title: Do gem
 category: Ruby libraries
+layout: 2017/sheet
 ---
 
+### About
+{: .-intro}
+
  * [DAddYE/do](https://github.com/DAddYE/do)
 
 ### Connection
index f588996..78e4f63 100644 (file)
@@ -1,9 +1,10 @@
 ---
 title: Elixir metaprogramming
 category: Elixir
+layout: 2017/sheet
 ---
 
-## Kernel
+### Kernel
 
 Most of these magic is defined in [Kernel.SpecialForms](http://devdocs.io/elixir/elixir/kernel.specialforms).
 
index 49bc15b..a821a04 100644 (file)
--- a/emacs.md
+++ b/emacs.md
@@ -1,6 +1,7 @@
 ---
 title: Emacs
 category: CLI
+layout: 2017/sheet
 ---
 
 ### Movements
index f8d077f..0aa5318 100644 (file)
--- a/ember.md
+++ b/ember.md
@@ -1,6 +1,9 @@
 ---
 title: Ember.js
 category: JavaScript libraries
+layout: 2017/sheet
+tags: [Archived]
+archived: This sheet describes an older version of Ember.
 ---
 
 {% raw %}
index c35f10a..e46b6a0 100644 (file)
@@ -1,6 +1,7 @@
 ---
 title: Express.js
 category: JavaScript libraries
+layoute: 2017/sheet
 ---
 
 ### Settings
index ac3b768..a8d1bcb 100644 (file)
@@ -1,5 +1,8 @@
 ---
 title: Firefox
+layout: 2017/sheet
+tags: [Archived]
+archived: This sheet has not been updated with newer Firefox releases.
 ---
 
 ### [Firefox 31](https://www.mozilla.org/en-US/firefox/31.0/releasenotes/) (July 2014)
diff --git a/flux.md b/flux.md
index b3aaa13..876ac01 100644 (file)
--- a/flux.md
+++ b/flux.md
@@ -1,9 +1,19 @@
 ---
 title: Flux architecture
 category: React
+layout: 2017/sheet
 ---
 
-## Architecture
+## About
+
+### About
+{: .-intro}
+
+Flux is an architecture for building client-side web applications.
+
+* [In-Depth Overview](https://facebook.github.io/flux/docs/in-depth-overview/) _(facebook.github.io)_
+
+### Architecture
 
 * __Dispatchers__ receive *actions* that get dispatched to its listeners.
 
index 6e61058..b358fdc 100644 (file)
@@ -1,15 +1,16 @@
 ---
 title: Git tricks
 category: Git
+layout: 2017/sheet
 ---
 
-## Refs
+### Refs
 
     HEAD^       # 1 commit before head
     HEAD^^      # 2 commits before head
     HEAD~5      # 5 commits before head
 
-## Branches
+### Branches
 
     # create a new branch
       git checkout -b $branchname
@@ -31,7 +32,7 @@ category: Git
     # go back to previous branch
       git checkout -
       
-## Collaboration
+### Collaboration
 
     # Rebase your changes on top of the remote master
       git pull --rebase upstream master
@@ -43,6 +44,8 @@ category: Git
 Submodules
 ----------
 
+### Submodules
+
     # Import .gitmodules
       git submodule init
 
@@ -70,6 +73,8 @@ Diff
 Log options
 -----------
 
+### Options
+
     --oneline
       e11e9f9 Commit message here
 
@@ -131,13 +136,13 @@ Misc
 
     git bisect reset  # abort
 
-## Searching
+### Searching
 
     git log --grep="fixes things"  # search in commit messages
     git log -S"window.alert"       # search in code
     git log -G"foo.*"              # search in code (regex)
 
-## GPG Signing
+### GPG signing
 
     git config set user.signingkey <GPG KEY ID>       # Sets GPG key to use for signing
 
index 9351a07..7f743f5 100644 (file)
@@ -1,5 +1,8 @@
 ---
 title: Google Analytics
+layout: 2017/sheet
+tags: [Archived]
+archived: This sheet describes an older version of Google Analytics (UA).
 ---
 
 ### Pageview
@@ -27,5 +30,7 @@ title: Google Analytics
 
     // Scope = 1 (visitor), 2 (session), 3 (page, default)
 
-https://developers.google.com/analytics/devguides/collection/gajs/gaTrackingCustomVariables
-https://developers.google.com/analytics/devguides/collection/gajs/eventTrackerGuide
+### References
+
+- <https://developers.google.com/analytics/devguides/collection/gajs/gaTrackingCustomVariables>
+- <https://developers.google.com/analytics/devguides/collection/gajs/eventTrackerGuide>
diff --git a/gulp.md b/gulp.md
index ad090b3..890be70 100644 (file)
--- a/gulp.md
+++ b/gulp.md
@@ -1,8 +1,13 @@
 ---
 title: Gulp
 category: JavaScript libraries
+layout: 2017/sheet
+tags: [Archived]
+archived: The information on this sheet may possibly be outdated.
 ---
 
+### Available plugins
+
  * gulp-ruby-sass
  * gulp-autoprefixer
  * gulp-minify-css
index 3927e8f..5913bf3 100644 (file)
@@ -1,18 +1,26 @@
 ---
 title: Hledger
 category: Ledger
+layout: 2017/sheet
 ---
 
-## Reporting
+### About
+{: .-intro}
+
+- <https://hledger.org>
+- <https://hledger.org/quickstart.html>
+
+### Reporting
 
 ```
 hledger bal {query}
 hledger reg {query}
 ```
-{:.large.terminal}
 
 ## Query
 
+### Queries
+
 Queries are used on all commands (`bal`, `reg`, etc). [(docs)](http://hledger.org/manual.html#queries)
 
 ```
index bab3337..ac61090 100644 (file)
@@ -1,5 +1,6 @@
 ---
 title: iOS Provisioning Profiles
+layout: 2017/sheet
 ---
 
 ### Types of profiles
diff --git a/koa.md b/koa.md
index fd9c877..f5902e4 100644 (file)
--- a/koa.md
+++ b/koa.md
@@ -1,8 +1,16 @@
 ---
 title: Koa
 category: JavaScript libraries
+layout: 2017/sheet
 ---
 
+### About
+{: .-intro}
+
+Koa is a web framework for Node.js.
+
+- <https://koajs.com/>
+
 ### Reference
 
 ```js
index 6b76527..50c9c96 100644 (file)
@@ -1,8 +1,16 @@
 ---
 title: Kramdown
 category: Markup
+layout: 2017/sheet
 ---
 
+### About
+{: .-intro}
+
+Kramdown is a Markdown parser in Ruby.
+
+- <https://kramdown.gettalong.org/>
+
 ### Configuration
 
  * `parse_block_html` - process kramdown syntax inside blocks
index 2575947..c7892ae 100644 (file)
@@ -1,9 +1,10 @@
 ---
 title: Ledger examples
 category: Ledger
+layout: 2017/sheet
 ---
 
-Inspecting transactions:
+### Inspecting transactions
 
     # show me expenses for october (--period)
       ledger r Expenses -p oct
@@ -21,7 +22,7 @@ Inspecting transactions:
       ledger r mastercard -p "january"
       ledger r mastercard -b 01/25 -e 01/31
 
-Graphing:
+### Graphing
 
     # Graph my bank account balance, monthly
       ledger r Savings -M
@@ -32,14 +33,14 @@ Graphing:
     # ...what's the average per month?
       ledger r Expenses -M -n --average
 
-Simple:
+### Simple
 
     # what did I do yesterday?
     # ..list transactions on this day
       ledger r -p 01/26
       ledger r -p yesterday
 
-Switches:
+### Switches
 
     # what's everything I got in USD? (--exchange)
       ledger b Assets -X USD
index b30e91f..8ce10bd 100644 (file)
@@ -1,8 +1,10 @@
 ---
 title: Ledger format
 category: Ledger
+layout: 2017/sheet
 ---
 
+### Example
 ```
 2015/01/01 Pay rent
   Assets:Savings     -$300
@@ -32,6 +34,9 @@ Flags:
 ```
 
 ## Accounts
+
+### Accounts
+
 Only relevant with `--strict` or `--pedantic`
 
 ```
@@ -47,6 +52,8 @@ account Expenses:Food
 
 ## Others
 
+### Others
+
 ```
 D $1,000.00     ; set default commodity
 
index 6e0e76c..96c470a 100644 (file)
@@ -1,11 +1,19 @@
 ---
 title: Ledger periods
 category: Ledger
+layout: 2017/sheet
 ---
 
+### About
+{: .-intro}
+
+- <https://ledger-cli.org/3.0/doc/ledger3.html#Period-Expressions>
+
+### Usage
+
     [INTERVAL] [BEGIN] [END]
 
-Interval:
+#### Intervals
 
     every day
     every week
@@ -25,17 +33,17 @@ Interval:
     quarterly
     yearly
 
-Begin:
+#### Begin
 
     from <SPEC>
     since <SPEC>
 
-The end time can be either of:
+#### End
 
     to <SPEC>
     until <SPEC>
 
-Spec:
+### Spec
 
     2004
     2004/10
@@ -47,8 +55,6 @@ Spec:
     next week
     last week
 
-Examples:
+### Examples
 
     $ ledger r -p "since last month"
-
-See: http://ledger-cli.org/3.0/doc/ledger3.html#Period-Expressions
index 32b5248..a976a5c 100644 (file)
@@ -4,6 +4,10 @@ category: Ledger
 layout: 2017/sheet
 ---
 
+### About
+
+- <https://ledger-cli.org/3.0/doc/ledger3.html#Complex-expressions>
+
 ### Query characters
 
 | Query           | Description |
@@ -23,8 +27,3 @@ layout: 2017/sheet
 ledger r @taco
 ledger r comment =~ /landline/
 ```
-
-## References
-{: .-one-column}
-
-- <http://ledger-cli.org/3.0/doc/ledger3.html#Complex-expressions>
diff --git a/less.md b/less.md
index e9d722a..462eeee 100644 (file)
--- a/less.md
+++ b/less.md
@@ -1,5 +1,6 @@
 ---
 title: Less.js
+layout: 2017/sheet
 ---
 
 ### Functions
index f38b398..61efb00 100644 (file)
--- a/linux.md
+++ b/linux.md
@@ -1,5 +1,6 @@
 ---
 title: Linux
+layout: 2017/sheet
 ---
 
 ### Read/Write/Execute a file
diff --git a/lua.md b/lua.md
index ab95424..05029f4 100644 (file)
--- a/lua.md
+++ b/lua.md
@@ -1,14 +1,22 @@
 ---
 title: Lua
+layout: 2017/sheet
 ---
 
-## Comments
+## Basic examples
+
+### References
+
+- <https://www.lua.org/pil/13.html>
+- <http://lua-users.org/wiki/ObjectOrientedProgramming>
+
+### Comments
 
     -- comment
     --[[ Multiline
          comment ]]
 
-## Invoking functions
+### Invoking functions
 
     print()
     print("Hi")
@@ -21,7 +29,7 @@ title: Lua
     f{x=10, y=20}           <-->     f({x=10, y=20})
     type{}                  <-->     type({})
 
-## Tables / arrays
+### Tables / arrays
 
     t = {}
     t = { a = 1, b = 2 }
@@ -35,7 +43,7 @@ title: Lua
     print(array[2])       -- "b" (one-indexed)
     print(#array)         -- 4 (length)
 
-## Loops
+### Loops
 
     while condition do
     end
@@ -57,7 +65,7 @@ title: Lua
       if condition then break end
     end
 
-## Conditionals
+### Conditionals
 
     if condition then
       print("yes")
@@ -67,12 +75,12 @@ title: Lua
       print("no")
     end
 
-## Variables
+### Variables
 
     local x = 2
     two, four = 2, 4
 
-## Functions
+### Functions
 
     function myFunction()
       return 1
@@ -100,7 +108,7 @@ title: Lua
 
     doAction('write', "Shirley", "Abed")
 
-## Lookups
+### Lookups
 
     mytable = { x = 2, y = function() .. end }
 
@@ -118,8 +126,9 @@ title: Lua
     function X:y(z) .. end
     function X.y(self, z) .. end
 
-## Metatables
+## More concepts
 
+### Metatables
 
     mt = {}
 
@@ -136,7 +145,7 @@ title: Lua
 
     print(myobject)
 
-## Classes
+### Classes
 
     Account = {}
 
@@ -161,7 +170,7 @@ title: Lua
     a = Account:new(9000)
     a:withdraw(200)    -- method call
 
-## Constants
+### Constants
 
     nil
     false
@@ -169,6 +178,8 @@ title: Lua
 
 ## Operators (and their metatable names)
 
+### Relational
+
     -- Relational (binary)
     -- __eq  __lt  __gt  __le  __ge
        ==    <     >     <=    >=
@@ -182,12 +193,15 @@ title: Lua
     -- __unm (unary minus)
        -
 
+### Logic
+
     -- Logic (and/or)
     nil and false  --> nil
     false and nil  --> false
     0 and 20       --> 20
     10 and 20      --> 20
 
+### Tables
 
     -- Length
     -- __len(array)
@@ -209,8 +223,9 @@ title: Lua
     -- Call
     -- __call(func, ...)
 
+## API
 
-## API: Global functions  [(ref)](http://lua.gts-stolberg.de/en/Basis.php)
+### API: Global Functions
 
     dofile("hello.lua")
     loadfile("hello.lua")
@@ -233,7 +248,7 @@ title: Lua
     tonumber("34")
     tonumber("8f", 16)
 
-## API: Strings
+### API: Strings
 
     'string'..'concatenation'
 
@@ -258,7 +273,7 @@ title: Lua
     s:byte()
     s:format()
 
-## API: Tables
+### API: Tables
 
     table.foreach(t, function(row) ... end)
     table.setn
@@ -269,7 +284,7 @@ title: Lua
     table.sort
     table.remove(t, 4)
 
-## API: Math [(ref)](http://lua-users.org/wiki/MathLibraryTutorial)
+### API: Math
 
     math.abs     math.acos    math.asin       math.atan    math.atan2
     math.ceil    math.cos     math.cosh       math.deg     math.exp
@@ -281,7 +296,7 @@ title: Lua
     math.sqrt(144)
     math
 
-## API: Misc
+### API: Misc
 
     io.output(io.open("file.txt", "w"))
     io.write(x)
@@ -293,8 +308,3 @@ title: Lua
     file:read()
     file:lines()
     file:close()
-
-## Reference
-
-  https://www.lua.org/pil/13.html
-  http://lua-users.org/wiki/ObjectOrientedProgramming
index 6d93b81..4762fc9 100644 (file)
@@ -1,8 +1,17 @@
 ---
 title: Machinist
 category: Ruby libraries
+layout: 2017/sheet
+tags: [Archived]
+archived: Machinist has not been in active development since 2013.
 ---
 
+### About
+
+Machinist is a fixture management library for Ruby.
+
+- <https://github.com/notahat/machinist>
+
 ### Installing
 
     # Gemfile
index 0e1ca97..cc4e2fa 100644 (file)
@@ -1,9 +1,11 @@
 ---
 title: Make for assets
-hljs_languages: [makefile]
+layout: 2017/sheet
+tags: [Archived]
+archived: This sheet may be listing practices that are outdated.
 ---
 
-## Basic compiling
+### Basic compiling
 
 ```makefile
 bin := ./node_modules/.bin
@@ -14,7 +16,7 @@ build/%.js: src/%.coffee
     @$(bin)/coffee < $^ > $@
 ```
 
-## Stylus + Autoprefixer
+### Stylus + Autoprefixer
 
     bin := ./node_modules/.bin
     stylus := $(bin)/stylus
@@ -28,18 +30,18 @@ build/%.js: src/%.coffee
     %.css: %.styl $(styl_files)
         @$(stylus) $< | $(autoprefixer) -b "> 1%" > $@
 
-## Hint
+### Hint
 
     hint:
        $(js_files)
 
-## Watching
+### Watching
 
     watch:
         @echo "... watching for changes"
         @while true; do make -s; sleep 1; done
 
-## Browserify
+### Browserify
 
     js_files := $(shell find web/ -name "*.js")
 
index cb5d8bc..af3ddcf 100644 (file)
@@ -5,7 +5,7 @@ layout: 2017/sheet
 category: CLI
 ---
 
-## Var assignment
+### Var assignment
 
 ```makefile
 foo  = "bar"
@@ -19,7 +19,7 @@ foo != echo fooo   # exec shell command and assign to foo
 
 `=` expressions are only evaluated when they're being used.
 
-## Magic variables
+### Magic variables
 
 ```makefile
 out.o: src.c src.h
@@ -38,7 +38,7 @@ also:
   $(@D) # target directory
 ```
 
-## Command prefixes
+### Command prefixes
 
 | Prefix | Description                                 |
 | ------ | ------------------------------------------- |
@@ -54,14 +54,14 @@ build:
 -include .depend
 ```
 
-## Find files
+### Find files
 
 ```makefile
 js_files  := $(wildcard test/*.js)
 all_files := $(shell find images -name "*")
 ```
 
-## Substitutions
+### Substitutions
 
 ```makefile
 file     = $(SOURCE:.cpp=.o)   # foo.cpp => foo.o
@@ -71,7 +71,7 @@ outputs  = $(patsubst %.c, %.o, $(wildcard *.c))
 assets   = $(patsubst images/%, assets/%, $(wildcard images/*))
 ```
 
-## More functions
+### More functions
 
 ```makefile
 $(strip $(string_var))
@@ -80,7 +80,7 @@ $(filter %.less, $(files))
 $(filter-out %.less, $(files))
 ```
 
-## Building files
+### Building files
 
 ```makefile
 %.o: %.c
@@ -88,13 +88,13 @@ $(filter-out %.less, $(files))
   foo $^
 ```
 
-## Includes
+### Includes
 
 ```makefile
 -include foo.make
 ```
 
-## Options
+### Options
 
 ```sh
 make
@@ -104,7 +104,7 @@ make
   -j, --jobs=N   # parallel processing
 ```
 
-## Conditionals
+### Conditionals
 
 ```makefile
 foo: $(objects)
@@ -115,14 +115,14 @@ else
 endif
 ```
 
-## Recursive
+### Recursive
 
 ```makefile
 deploy:
   $(MAKE) deploy2
 ```
 
-## Further reading
+### Further reading
 
 - [isaacs's Makefile](https://gist.github.com/isaacs/62a2d1825d04437c6f08)
 - [Your Makefiles are wrong](https://tech.davis-hansson.com/p/make/)
index 49102f5..1fce64f 100644 (file)
@@ -1,8 +1,13 @@
 ---
 title: Middleman 3
 category: JavaScript libraries
+layout: 2017/sheet
+tags: [Archived]
+archived: This guide is for Middleman v3.
 ---
 
+### About
+
 **NB:** This is for Middleman 3, not Middleman 4+.
 
 ### Compass config
index f78201f..d8dbb22 100644 (file)
@@ -1,6 +1,7 @@
 ---
 title: Minitest
 category: Ruby
+layout: 2017/sheet
 ---
 
 ### Usage
index 79c9915..b1bb6f1 100644 (file)
@@ -1,10 +1,15 @@
 ---
 title: Mocha HTML
 category: JavaScript libraries
+layout: 2017/sheet
 ---
 
+### About
+
 This is a mocha template that loads js/css from cdn.
 
+### Template
+
 ```html
 <!doctype html>
 <html>
index 11e0a1a..09d6fb3 100644 (file)
@@ -1,6 +1,7 @@
 ---
 title: Mocha.js TDD interface
 category: JavaScript libraries
+layout: 2017/sheet
 ---
 
 ### TDD
index 1ea97ae..e5fea23 100644 (file)
--- a/mocha.md
+++ b/mocha.md
@@ -1,6 +1,7 @@
 ---
 title: Mocha.js
 category: JavaScript libraries
+layout: 2017/sheet
 ---
 
 ### BDD
index f8c8658..7943cf4 100644 (file)
@@ -1,6 +1,9 @@
 ---
 title: Modernizr
 category: JavaScript libraries
+layout: 2017/sheet
+tags: [Archived]
+archived: Modernizr is no longer in active development.
 ---
 
 ### Script
index 84d4f39..56bc919 100644 (file)
@@ -1,6 +1,7 @@
 ---
 title: fs
 category: Node.js
+layout: 2017/sheet
 ---
 
 ### Reading
index af3f91a..580e416 100644 (file)
@@ -1,6 +1,7 @@
 ---
 title: process
 category: Node.js
+layout: 2017/sheet
 ---
 
 ### Streams
index 165cbbb..cf96438 100644 (file)
--- a/nodejs.md
+++ b/nodejs.md
@@ -1,9 +1,10 @@
 ---
 title: Node.js API
 category: Node.js
+layout: 2017/sheet
 ---
 
-## Globals
+### Globals
 
     __filename
     __dirname
@@ -21,14 +22,14 @@ category: Node.js
         }
     });
 
-## Snippets
+### Snippets
 
     info = require('../package.json')
     info.version
 
     process.stdout.write(util.inspect(objekt, false, Infinity, true) + '\n');
 
-## Spawn - passthru the in/out
+### Spawn - passthru the in/out
 
     var spawn = require('child_process').spawn;
     var proc = spawn(bin, argv, { stdio: 'inherit' });
diff --git a/nopt.md b/nopt.md
index 0da5afd..8147827 100644 (file)
--- a/nopt.md
+++ b/nopt.md
@@ -1,8 +1,16 @@
 ---
 title: Nopt
 category: JavaScript libraries
+layout: 2017/sheet
 ---
 
+### About
+{: .-intro}
+
+- <https://www.npmjs.org/package/nopt>
+
+### Example
+
 ```js
 var args = require('nopt')({
   foo: [String, null],
@@ -46,5 +54,3 @@ if (args.version) {
   process.exit(0);
 }
 ```
-
-https://www.npmjs.org/package/nopt
index 585b16e..432c854 100644 (file)
--- a/pacman.md
+++ b/pacman.md
@@ -2,13 +2,19 @@
 title: Pacman
 category: Linux
 updated: 2018-07-07
-intro: |
-  Pacman is the package manager for Arch linux and its derivatives.
+layout: 2017/sheet
 ---
 
 ## Commands
 {: .-three-column}
 
+### About
+{: .-intro}
+
+Pacman is the package manager for Arch Linux and its derivatives.
+
+- <https://wiki.archlinux.org/title/pacman>
+
 ### Common commands
 
 | Command                 | Description                       |
index f2884c0..e4c4ac3 100644 (file)
@@ -1,8 +1,10 @@
 ---
 title: Parsimmon
 category: JavaScript libraries
+layout: 2017/sheet
 ---
 
+### Basic usage
 ```js
 const P = require('parsimmon')
 
@@ -11,7 +13,7 @@ P.regexp(/[a-z]+/)
 //=> { status: true, value: ['hello'] }
 ```
 
-## Atoms
+### Atoms
 
 ```js
 P.regexp(/[a-z]+/)
@@ -23,7 +25,7 @@ P.optWhitespace
 P.eof
 ```
 
-## Combinators
+### Combinators
 
 ```js
 P.seq(a, b, c)             // sequence of these
@@ -41,13 +43,13 @@ a.atMost(10)
 a.atLeast(10)
 ```
 
-## Formatting
+### Formatting
 
 ```js
 P.seq(P.number, P.oneOf('+-*/'), P.number)
 .map(([left, oper, right]) => ({ oper, left, right }))
 ```
 
-## Reference
+### Reference
 
 - <https://github.com/jneen/parsimmon/blob/master/API.md>
index 541f82f..88032d2 100644 (file)
@@ -1,8 +1,14 @@
 ---
 title: Perl-pie
 category: Development
+layout: 2017/sheet
 ---
 
+### About
+{: .-intro}
+
+Use `perl` to search and replace across many files.
+
 ### Search and replace
 
 ```sh
index 19f9f39..134106c 100644 (file)
@@ -2,18 +2,23 @@
 title: "Phoenix: Ecto models"
 category: Elixir
 deprecated: true
+layout: 2017/sheet
+tags: [Archived]
+archived: This is for Phoenix 1.2 and below. [Phoenix 1.3 has a new API.](./phoenix-ecto@1.3).
 ---
 
-This is for Phoenix 1.2 and below. [Phoenix 1.3 has a new API.](phoenix-ecto@1.3.html).
+### About
 
-## Generating
+This is for Phoenix 1.2 and below. [Phoenix 1.3 has a new API.](./phoenix-ecto@1.3).
+
+### Generating
 
 ```
 $ mix phoenix.gen.html Profile profiles email:string age:integer
 $ mix phoenix.gen.html User users email:string hashed_password:string
 ```
 
-## Schema
+### Schema
 
 ```elixir
 defmodule User do
@@ -30,7 +35,7 @@ defmodule User do
 end
 ```
 
-## Changesets
+### Changesets
 
 ```elixir
 def changeset(user, params \\ :empty) do
index d1f7ea6..cf432c2 100644 (file)
@@ -1,7 +1,15 @@
 ---
 title: PlantUML
+layout: 2017/sheet
 ---
 
+### About
+{: .-intro}
+
+PlantUML is a markup language for creating diagrams.
+
+- <https://plantuml.com/>
+
 ### Format
 
     @startuml
index d67899e..0debd9e 100644 (file)
@@ -1,15 +1,16 @@
 ---
 title: PostgreSQL
 category: Databases
+layout: 2017/sheet
 ---
 
-Replace anything within `<placeholder>` accordingly
-
 ### Console
 
     $ psql #logs in to default database & default user
     $ sudo -u <rolename:postgres> psql #logs in with a particular user
 
+Replace anything within `<placeholder>` accordingly
+
 ### Commands
 
  * Show roles: `\du`
index db8e61a..118384e 100644 (file)
@@ -1,8 +1,10 @@
 ---
 title: Projectionist
 category: Vim
+layout: 2017/sheet
 ---
 
+### Basic usage
 
 ```json
 /* .projectionist.vim */
@@ -16,7 +18,7 @@ category: Vim
   }
 ```
 
-## Available options
+### Available options
 
 ```js
 {
@@ -35,7 +37,7 @@ category: Vim
 }
 ```
 
-## Commands
+### Commands
 
 | Command | Description |
 |---------|-------------|
@@ -53,8 +55,7 @@ category: Vim
 | `:Lcd` | cd to root using :lcd |
 |---------|-------------|
 | `:ProjectDo {cmd}` | run command in root |
-{:.shortcuts}
 
-## Reference
+### Reference
 
 See [vim-projectionist](https://github.com/tpope/vim-projectionist).
diff --git a/pry.md b/pry.md
index 618a7a3..fcb0a3c 100644 (file)
--- a/pry.md
+++ b/pry.md
@@ -1,8 +1,16 @@
 ---
 title: Pry
 category: Ruby libraries
+layout: 2017/sheet
 ---
 
+### About
+{: .-intro}
+
+Pry is a runtime development console for Ruby.
+
+- <https://github.com/pry/pry>
+
 ### cd
 
 ```
index 8750057..fd85dfb 100644 (file)
--- a/python.md
+++ b/python.md
@@ -1,6 +1,7 @@
 ---
 title: Python
 category: Python
+layout: 2017/sheet
 ---
 
 ### Tuples (immutable)
diff --git a/qjs.md b/qjs.md
index 379f067..8160d58 100644 (file)
--- a/qjs.md
+++ b/qjs.md
@@ -1,8 +1,15 @@
 ---
 title: Q.js
 category: JavaScript libraries
+layout: 2017/sheet
 ---
 
+### About
+{: .-intro}
+
+* <https://github.com/kriskowal/q>
+* <https://github.com/kriskowal/q/wiki/API-Reference>
+
 ### Creating promises (Q.promise)
 
     Q.promise (ok, fail) =>
@@ -69,7 +76,3 @@ category: JavaScript libraries
 
   .catch (e) ->
     console.error "Oh well", e
-
-### Reference
-
- * https://github.com/kriskowal/q/wiki/API-Reference
index 61e40a3..ce2d320 100644 (file)
@@ -1,10 +1,19 @@
 ---
 title: Ractive.js
 category: JavaScript libraries
-vim: ft=javascript
+layout: 2017/sheet
 ---
 
 {% raw %}
+
+### About
+{: .-intro}
+
+Ractive is a UI library for JavaScript.
+
+- <https://ractive.js.org/>
+- <https://ractivejs.org/>
+
 ### [Initialization](http://docs.ractivejs.org/latest/options)
 
     new Ractive({
index 8e00a3a..e08056e 100644 (file)
@@ -1,6 +1,7 @@
 ---
-title: Controllers
+title: Rails controllers
 category: Rails
+layout: 2017/sheet
 ---
 
 ### Common stuff
index 6bda336..d1f9c90 100644 (file)
@@ -1,11 +1,13 @@
 ---
-title: Form helpers
-hljs_languages: [haml]
+title: Rails form helpers
 category: Rails
+layout: 2017/sheet
 ---
 
 ## Form builder
 
+### Form builder
+
 ```haml
 - form_for @post do |f|
 ```
index 623e22f..a562283 100644 (file)
@@ -1,6 +1,7 @@
 ---
-title: Helpers
+title: Rails helpers
 category: Rails
+layout: 2017/sheet
 ---
 
 ### Date
index cf51c12..e180efb 100644 (file)
@@ -1,8 +1,18 @@
 ---
-title: i18n
+title: Rails i18n
 category: Rails
+layout: 2017/sheet
 ---
 
+### References
+
+ * <http://guides.rubyonrails.org/i18n.html>
+ * <http://rails-i18n.org/wiki>
+ * <https://github.com/svenfuchs/i18n>
+ * <https://github.com/svenfuchs/rails-i18n/blob/master/rails/locale/en.yml>
+
+### Example
+
 ```rb
 t('my.messages.hello')
 
@@ -12,7 +22,8 @@ t(:hello, scope: [:my, :messages])
 
 t('my.messages.hello', default: "Hello")
 ```
-{:.light}
+
+#### YAML
 
 ```yml
 en:
@@ -26,7 +37,8 @@ en:
 ```rb
 t('hello', name: "John")
 ```
-{:.light}
+
+#### YAML
 
 ```yml
 hello: "Hello %{name}"
@@ -38,7 +50,8 @@ hello: "Hello %{name}"
 # from the 'books/index' view
 t('.title')
 ```
-{:.light}
+
+#### YAML
 
 ```yml
 en:
@@ -53,7 +66,8 @@ en:
 t(:inbox, count: 1)  #=> 'one message'
 t(:inbox, count: 2)  #=> '2 messages'
 ```
-{:.light}
+
+#### YAML
 
 ```yml
 inbox:
@@ -69,7 +83,8 @@ inbox:
 l(Time.now)
 l(Time.now, format: :short)
 ```
-{:.light}
+
+#### YAML
 
 ```yml
 en:
@@ -85,7 +100,8 @@ en:
 ```rb
 l(Date.today)
 ```
-{:.light}
+
+#### YAML
 
 ```yml
 en:
@@ -104,7 +120,8 @@ en:
 User.model_name.human            #=> "User"
 Child.model_name.human(count: 2) #=> "Children"
 ```
-{:.light}
+
+#### YAML
 
 ```yml
 en:
@@ -121,7 +138,8 @@ en:
 ```rb
 User.human_attribute_for :name   #=> "Name"
 ```
-{:.light}
+
+#### YAML
 
 ```yml
 en:
@@ -138,7 +156,8 @@ en:
 ```rb
 error_messages_for(...)
 ```
-{:.light}
+
+#### YAML
 
 ```yml
 activerecord:
@@ -150,6 +169,8 @@ activerecord:
             blank: "Please enter a name."
 ```
 
+### Scopes
+
 Possible scopes (in order):
 
 ```yml
@@ -181,7 +202,8 @@ validates
 form_for @post do
   f.label :body
 ```
-{:.light}
+
+#### YAML
 
 ```yml
 helpers:
@@ -197,7 +219,8 @@ helpers:
 form_for @post do
   f.submit
 ```
-{:.light}
+
+#### YAML
 
 ```yml
 helpers:
@@ -223,14 +246,14 @@ number_to_rounded(3.14, precision: 0) #=> "3"
 number_to_human(12_000)               #=> "12 Thousand"
 number_to_human_size(12345)           #=> "12.3 kb"
 ```
-{:.light}
 
 ### Delimited
 
 ```rb
 number_to_delimited(n)
 ```
-{:.light}
+
+#### YAML
 
 ```yml
 number:
@@ -266,7 +289,8 @@ number:
 ```rb
 number_to_percentage(n)
 ```
-{:.light}
+
+#### YAML
 
 ```yml
 number:
@@ -278,6 +302,8 @@ number:
 
 ## Programmatic access
 
+### Programmatic access
+
 ```rb
 I18n.backend.store_translations :en, ok: "Ok"
 I18n.locale = :en
@@ -288,11 +314,3 @@ I18n.available_locales
 I18n.translate :ok   # aka, I18n.t
 I18n.localize date   # aka, I18n.l
 ```
-{:.light}
-
-## Reference
-
- * http://guides.rubyonrails.org/i18n.html
- * http://rails-i18n.org/wiki
- * https://github.com/svenfuchs/i18n
- * https://github.com/svenfuchs/rails-i18n/blob/master/rails/locale/en.yml
index b1b4392..67289ff 100644 (file)
@@ -1,6 +1,7 @@
 ---
-title: Migrations
+title: Rails migrations
 category: Rails
+layout: 2017/sheet
 ---
 
 ### Automatically make migrations
index bc98e3b..9339d2f 100644 (file)
@@ -1,10 +1,10 @@
 ---
 title: Rails plugins
 category: Rails
+layout: 2017/sheet
 ---
 
-Generate a plugin
------------------
+### Generate a plugin
 
 Generate a Rails Engine plugin:
 
@@ -13,10 +13,14 @@ Generate a Rails Engine plugin:
 Initializers
 ------------
 
+### Initializers
+
 * [Rails::Railtie](http://edgeapi.rubyonrails.org/classes/Rails/Railtie.html)
 * [EngineYard blog 
   post](http://www.engineyard.com/blog/2010/extending-rails-3-with-railties/)
 
+### Initializer method
+
 Subclass Railtie and provide an `initializer` method.
 
     module NewPlugin
@@ -36,8 +40,12 @@ Subclass Railtie and provide an `initializer` method.
 Custom routes
 -------------
 
+### Custom routes
+
 * [ActionDispatch::Routing::Mapper](http://api.rubyonrails.org/classes/ActionDispatch/Routing/Mapper.html)
 
+### Creating routes
+
 To create custom `routes.rb` keywords:
 
     # # routes.rb:
@@ -65,6 +73,8 @@ Example with a block:
 Custom generators
 -----------------
 
+### Custom generators
+
 * [Guide: generators](http://guides.rubyonrails.org/generators.html)
 * [ActiveRecord::Generators::Base](http://api.rubyonrails.org/classes/ActiveRecord/Generators/Base.html)
 
@@ -118,6 +128,8 @@ When invoking `rails g XXX:YYY`:
 ActiveModel 'acts as'
 ---------------------
 
+### acts as
+
     # yaffle/lib/yaffle/acts_as_yaffle.rb
     module Yaffle
       module ActsAsYaffle
index 1745ba0..0986efa 100644 (file)
@@ -1,9 +1,12 @@
 ---
 title: Routes
 category: Rails
+layout: 2017/sheet
 ---
 
-## Multiple resources (`resources`)
+## Resources
+
+### Multiple resources (`resources`)
 
     resources :photos
 
index cbcde34..7fc4b50 100644 (file)
@@ -1,8 +1,13 @@
 ---
 title: Rails tricks
 category: Rails
+layout: 2017/sheet
+tags: [Archived]
+archived: This sheet may describe practices that might be outdated.
 ---
 
+### Sass source maps
+
 in config/environments/development.rb:
 
     # Source maps for Sass
@@ -12,7 +17,7 @@ in config/environments/development.rb:
     # Don't break apart
     config.assets.debug = false
 
-Partial locals
+### Partial locals
 
     <%= render 'article', full: true %>
     <%= render 'article' %>
@@ -21,12 +26,12 @@ Partial locals
       ...
     <% end %>
 
-HTML in i18n
+### HTML in i18n
 
     en:
       read_more_html: "read <b>more</b>..."
 
-Exception handling:
+### Exception handling
 
     # config/application.rb
     config.exceptions_app = self.routes
@@ -40,25 +45,25 @@ Exception handling:
       end
      end
 
-Rails updating:
+### Rails updating
 
     rake rails:update
 
-Distinct pluck:
+### Distinct pluck
 
     Article.distinct.pluck('author')
 
-Relation#merge
+### Relation#merge
 
     scope :with_drafts, -> {
       uniq.joins(:articles).merge(Article.draft)
     }
 
-Order
+### Order
 
     scope :recent, -> { order created_at: :desc }
 
-Group by month
+### Group by month
 
     .group("to_char(created_at, 'YYYY-MM')")
     .group("to_char(created_at, 'YYYY-MM')").count
diff --git a/tape.md b/tape.md
index 379bad5..0bf05e7 100644 (file)
--- a/tape.md
+++ b/tape.md
@@ -1,8 +1,11 @@
 ---
 title: Tape
 category: JavaScript libraries
+layout: 2017/sheet
 ---
 
+### Example
+
 ```js
 test('things', (t) => {
   t.plan(1)
index 5560615..5e4442c 100644 (file)
--- a/weinre.md
+++ b/weinre.md
@@ -5,6 +5,7 @@ layout: 2017/sheet
 tags: [Archived]
 intro: |
   [weinre](https://www.npmjs.com/package/weinre) is a remote Web inspector. Note that it has been deprecated since 2016.
+archived: Weinre has been deprecated since 2016.
 ---
 
 ### Usage