LVM on LUKS Arch installation with systemd-boot
Sources:
| class TemplateLiteral: | |
| __slots__ = ("raw_template", "parsed_template", "field_values", "format_specifiers") | |
| def __new__(cls, raw_template, parsed_template, field_values, format_specifiers): | |
| self = super().__new__(cls) | |
| self.raw_template = raw_template | |
| if len(parsed_template) == 0: | |
| raise ValueError("'parsed_template' must contain at least one value") | |
| self.parsed_template = parsed_template | |
| self.field_values = field_values |
| PEP: 501 | |
| Title: General purpose string template literals | |
| Version: $Revision$ | |
| Last-Modified: $Date$ | |
| Author: Nick Coghlan <[email protected]>, Nick Humrich <[email protected]> | |
| Status: Draft | |
| Type: Standards Track | |
| Content-Type: text/x-rst | |
| Requires: 498 | |
| Created: 08-Aug-2015 |
LVM on LUKS Arch installation with systemd-boot
Sources:
| const { Client } = require('pg') | |
| const client = new Client({user: 'postgres', 'database': 'postgres'}) | |
| client.connect() | |
| client.query('BEGIN', [], (err,res) => { | |
| console.log(err ? err.stack : res.rows[0]) | |
| }) | |
| client.query('CREATE TABLE if not exists foo ( id text, bar double precision )', [], (err,res) => { |
| import asyncio | |
| import aiopg | |
| import aiopg.sa | |
| import asyncpg | |
| import asyncpgsa | |
| import sqlalchemy as sa | |
| pg_tables = sa.Table( | |
| 'pg_tables', sa.MetaData(), | |
| sa.Column('schemaname'), |
| import functools | |
| import inspect | |
| from timeit import timeit | |
| class Bob: | |
| __slots__ = ('a',) | |
| def __init__(self): | |
| self.a = 5 |
| """Script to download free O'Reilly ebooks.""" | |
| import asyncio | |
| import os | |
| import re | |
| import sys | |
| import aiohttp | |
| filename_matcher = re.compile(r'http://www.oreilly.com/(.*)/free/(.*).csp') | |
| session = None |
| import asyncio | |
| from multiprocessing.pool import ThreadPool | |
| from timeit import timeit | |
| from functools import partial | |
| pool = ThreadPool(processes=400) | |
| loop = asyncio.get_event_loop() | |
| def fib(x): |
| from timeit import timeit | |
| import asyncio | |
| import requests | |
| from threading import Thread | |
| import aiohttp | |
| client = aiohttp.ClientSession() | |
| import tornado.ioloop | |
| from tornado.httpclient import AsyncHTTPClient | |
| urls = ['http://www.google.com', 'http://www.yandex.ru', 'http://www.python.org'] | |
| def handle_response(response): | |
| if response.error: | |
| print("Error:", response.error) | |
| else: | |
| url = response.request.url | |
| data = response.body |