Based off of: http://docs.sequelizejs.com/en/1.7.0/articles/express/
Create and initialize your a directory for your Express application.
$ mkdir sequelize-demo
Based off of: http://docs.sequelizejs.com/en/1.7.0/articles/express/
Create and initialize your a directory for your Express application.
$ mkdir sequelize-demo
# This tells kubecfg to read its config from the local directory | |
export KUBECONFIG=./kubeconfig | |
# Looking at the cluster | |
kubectl get nodes | |
kubectl get pods --namespace=kube-system | |
# Running a single pod | |
kubectl run --generator=run-pod/v1 --image=gcr.io/kuar-demo/kuard-amd64:1 kuard | |
kubectl get pods |
/** | |
* This gist was inspired from https://gist.github.com/homam/8646090 which I wanted to work when uploading an image from | |
* a base64 string. | |
* This code is used in my startup, Zired. | |
* Web: http://zired.io | |
*/ | |
// You can either "yarn add aws-sdk" or "npm i aws-sdk" | |
const AWS = require('aws-sdk') |
{ | |
"name": "application", | |
"version": "1.0.0", | |
"description": "", | |
"main": "server.js", | |
"scripts": { | |
"dev": "nodemon server.js", | |
"build": "webpack", | |
"start": "node ./node_modules/webpack-dev-server/bin/webpack-dev-server.js --port 8000", | |
"test": "jest", |
//require("babel-register"); | |
//module.exports = require("./webpack.config.babel"); | |
import webpack from "webpack"; | |
import path from 'path'; | |
import CleanWebpackPlugin from 'clean-webpack-plugin'; | |
import HtmlWebpackPlugin from "html-webpack-plugin"; | |
{ | |
"root": true, | |
"extends": [ | |
"eslint:recommended", | |
"plugin:import/errors", | |
"plugin:import/warnings" | |
], | |
"parserOptions": { | |
"ecmaVersion": 7, | |
"sourceType": "module" |
import React, { Component } from 'react'; | |
import { reduxForm, Field } from 'redux-form'; | |
class Signin extends Component { | |
onSubmit({ email, password }) { | |
console.log(email); | |
console.log(password); | |
} | |
renderField(field) { |
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
# Example of `adapter' design pattern | |
# Copyright (C) 2011 Radek Pazdera | |
# This program is free software: you can redistribute it and/or modify | |
# it under the terms of the GNU General Public License as published by | |
# the Free Software Foundation, either version 3 of the License, or | |
# (at your option) any later version. |
For each machine running xmodmap
will give you the mapping and keycode, take a look first then write the script. I use ubuntu and mac keyboard. The below maps both left and right control and super.
Create an .Xmodmap file in your Linux home directory, with the following contents, then execute xmodmap .Xmodmap
clear control
clear mod4
keycode 37 = Super_L
keycode 105 = Super_R
# Call scopes directly from your URL params: | |
# | |
# @products = Product.filter(params.slice(:status, :location, :starts_with)) | |
module Filterable | |
extend ActiveSupport::Concern | |
module ClassMethods | |
# Call the class methods with names based on the keys in <tt>filtering_params</tt> | |
# with their associated values. For example, "{ status: 'delayed' }" would call |