One Paragraph of project description goes here
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.
| AllCops: | |
| RunRailsCops: true | |
| # Commonly used screens these days easily fit more than 80 characters. | |
| Metrics/LineLength: | |
| Max: 120 | |
| # Too short methods lead to extraction of single-use methods, which can make | |
| # the code easier to read (by naming things), but can also clutter the class | |
| Metrics/MethodLength: |
| #!/bin/sh | |
| # | |
| # This script is used on a QNAP TS-269 PRO. https://www.en0ch.se/qnap-and-rsync/ | |
| # | |
| # You have to change: | |
| # 1. $SHAREUSR | |
| # 2. $EXCLUDES (if you want o change the name of the file servername.excludes) | |
| # 3. $SOURCE & $DESTINATION | |
| # 4. user@yourserver.se for the mysqldump | |
| # 5. --password=SUPERSECRET |
| {% comment %} | |
| * | |
| * This loop loops through a collection called `collection_name` | |
| * and sorts it by the front matter variable `date` and than filters | |
| * the collection with `reverse` in reverse order | |
| * | |
| * To make it work you first have to assign the data to a new string | |
| * called `sorted`. | |
| * | |
| {% endcomment %} |
| module AuthRequestHelper | |
| def http_auth_as(username, password, &block) | |
| @env = {} unless @env | |
| old_auth = @env['HTTP_AUTHORIZATION'] | |
| @env['HTTP_AUTHORIZATION'] = ActionController::HttpAuthentication::Basic.encode_credentials(username, password) | |
| yield block | |
| @env['HTTP_AUTHORIZATION'] = old_auth | |
| end | |
| def auth_get(url, params={}, env={}) |
| # app/models/experience.rb | |
| # | |
| # == Schema Information | |
| # | |
| # Table name: experiences | |
| # | |
| # id :integer not null, primary key | |
| # title :string | |
| # description :text | |
| # created_at :datetime not null |
| var OFF = 0, WARN = 1, ERROR = 2; | |
| module.exports = exports = { | |
| "env": { | |
| "es6": true | |
| }, | |
| "ecmaFeatures": { | |
| // env=es6 doesn't include modules, which we are using | |
| "modules": true |