This is an unofficial manual for the couchdb Python module I wish I had had.
pip install couchdb
| redis: | |
| image: redis | |
| postgres: | |
| image: postgres | |
| environment: | |
| - POSTGRES_PASSWORD=sentry | |
| - POSTGRES_USER=sentry | |
| volumes: | |
| - /var/lib/postgresql/data |
| 'use strict'; | |
| var http = require( "http" ), | |
| pathUtils = require( "path" ), | |
| express = require( "express" ), | |
| app = express(), | |
| PORT = process.env.PORT || 5000, | |
| appDir = pathUtils.resolve( __dirname, "client" ); | |
| app.use( express.static( appDir ) ); |
| fastcgi_param QUERY_STRING $query_string; | |
| fastcgi_param REQUEST_METHOD $request_method; | |
| fastcgi_param CONTENT_TYPE $content_type; | |
| fastcgi_param CONTENT_LENGTH $content_length; | |
| fastcgi_param SCRIPT_NAME $fastcgi_script_name; | |
| fastcgi_param REQUEST_URI $request_uri; | |
| fastcgi_param DOCUMENT_URI $document_uri; | |
| fastcgi_param DOCUMENT_ROOT $document_root; | |
| fastcgi_param SERVER_PROTOCOL $server_protocol; |
| /** | |
| * Prints a line of non-ASCII text as a series of images. | |
| * All doc.text methods can be replaced with this method. | |
| * Works like doc.text but requires a fontsize (default is 10). | |
| * | |
| * Add function to jsPDF instance (do not overwrite doc.text): | |
| * var doc = new jsPDF(); | |
| * doc.alttext = nonASCIItext; | |
| * | |
| * @param {Number} x Horizontal placement |
| /* | |
| Incredibly simple Node.js and Express application server for serving static assets. | |
| Given as an example from the React Router documentation (along with examples | |
| using nginx and Apache): | |
| - https://github.com/ReactTraining/react-router/blob/master/docs/guides/Histories.md#browserhistory | |
| */ | |
| const express = require('express'); | |
| const path = require('path'); |
| /* | |
| Incredibly simple Node.js and Express application server for serving static assets. | |
| Given as an example from the React Router documentation (along with examples | |
| using nginx and Apache): | |
| - https://github.com/ReactTraining/react-router/blob/master/docs/guides/Histories.md#browserhistory | |
| */ | |
| const express = require('express'); | |
| const path = require('path'); |
| #how to specify an ssh key to use when cloning a repo in Mac | |
| ssh-agent bash -c 'ssh-add /Users/UR_USERNAME/.ssh/UR_PRIVATE_KEY; git clone git@DAS_GIT_URL' | |
| #!/usr/bin/env bash | |
| #################################################################################### | |
| # Slack Bash console script for sending messages. | |
| #################################################################################### | |
| # Installation | |
| # $ curl -s https://gist.githubusercontent.com/andkirby/67a774513215d7ba06384186dd441d9e/raw --output /usr/bin/slack | |
| # $ chmod +x /usr/bin/slack | |
| #################################################################################### | |
| # USAGE | |
| # Send message to slack channel/user |
| (r'^articles/(?P<year>\d{4}/?$, 'main.views.year'), | |
| # When a use case comes up that a month needs to be involved as | |
| # well, you add an argument in your regex: | |
| (r'^articles/(?P<year>\d{4}/(?P<month>\d{2})/?$, 'main.views.year_month'), | |
| # That works fine, unless of course you want to show something | |
| # different for just the year, in which case the following case can be | |
| # used, making separate views based on the arguments as djangoproject |
This is an unofficial manual for the couchdb Python module I wish I had had.
pip install couchdb