Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000| { "path": "/content/geometrixx/my-first-jinja-page", | |
| "properties": [ | |
| { "name": "jcr:primaryType", | |
| "value": "cq:Page" }], | |
| "nodes": [ | |
| { "path": "jcr:content", | |
| "properties": [ | |
| { "name": "jcr:primaryType", | |
| "value": "cq:PageContent"}, |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000| ${GOPATH//://bin:}/bin |
| from django.core.serializers.json import DjangoJSONEncoder | |
| from django.template import Library | |
| from json import dumps as json_dumps | |
| register = Library() | |
| @register.filter | |
| def json(data): | |
| """ |
| #!/usr/bin/python | |
| # -*- coding: utf-8 -*- | |
| from flask import request, url_for | |
| from flask.ext.api import FlaskAPI, status, exceptions | |
| app = FlaskAPI(__name__) | |
| notes = { |
| FROM adminer:4.7.1 | |
| # WATCH OUT WHEN UPGRADING, THE SED BELOW MIGHT STOP WORKING | |
| MAINTAINER marek@cilf.cz | |
| USER root | |
| RUN apk add autoconf gcc g++ make libffi-dev openssl-dev | |
| RUN pecl install mongodb | |
| RUN echo "extension=mongodb.so" > /usr/local/etc/php/conf.d/docker-php-ext-mongodb.ini |
PlantUML is a really awesome way to create diagrams by writing code instead of drawing and dragging visual elements. Markdown is a really nice documentation tool.
Here's how I combine the two, to create docs with embedded diagrams.
Get the command-line PlantUML from the download page or your relevant package manager.
macOS has ncurses version 5.7 which does not ship the terminfo description for tmux. There're two ways that can help you to solve this problem.
Instead of tmux-256color, use screen-256color which comes with system. Place this command into ~/.tmux.conf or ~/.config/tmux/tmux.conf(for version 3.1 and later):