mkdir project_foo
cd project_foo
git clone --bare git@github.com:yourorg/project_foo.git .bare
echo "gitdir: ./.bare" > .git
Now edit .bare/config, adding fetch = +refs/heads/*:refs/remotes/origin/* below [remote "origin"]
| javascript: Promise.all([import('https://unpkg.com/turndown@6.0.0?module'), import('https://unpkg.com/@tehshrike/readability@0.2.0'), ]).then(async ([{ | |
| default: Turndown | |
| }, { | |
| default: Readability | |
| }]) => { | |
| /* Optional vault name */ | |
| const vault = ""; | |
| /* Optional folder name such as "Clippings/" */ |
| from boto3.session import Session | |
| from botocore.auth import SigV4Auth | |
| from botocore.awsrequest import AWSRequest | |
| from botocore.credentials import Credentials | |
| from http.client import HTTPConnection, HTTPSConnection | |
| import json | |
| import os | |
| from urllib.parse import urlparse | |
| def sigv4_request( |
| #!/usr/bin/lua5.1 | |
| --- Async/Await for Lua 5.1 | |
| -- This script implements async/await functions for Lua, allowing tasks to | |
| -- be queued and scheduled independently. | |
| -- | |
| -- This is just an example and has a bunch of issues, isn't tested, isn't | |
| -- even actually used anywhere; I basically just got bored and had one of | |
| -- those "what if?" type ideas 6 hours ago. | |
| local co_create = coroutine.create |
| import React, { useRef, useEffect } from 'react'; | |
| import * as d3 from 'd3'; | |
| interface IProps { | |
| data?: number[]; | |
| } | |
| /* Component */ | |
| export const MyD3Component = (props: IProps) => { | |
| /* The useRef Hook creates a variable that "holds on" to a value across rendering |
| import { withLeaflet, GridLayer } from "react-leaflet"; | |
| import L from "leaflet"; | |
| class Grid extends GridLayer { | |
| createLeafletElement() { | |
| const { url, cacheName } = this.props; | |
| const Layer = L.TileLayer.extend({ | |
| createTile: (coords, done) => { | |
| const { x, y, z } = coords; |
| import boto3 | |
| import os | |
| import requests | |
| from botocore.auth import SigV4Auth | |
| from requests_aws4auth import AWS4Auth | |
| from elasticsearch import RequestsHttpConnection | |
| class AWSRequestsHttpConnection(RequestsHttpConnection): |
| # Auto list fields from django models - from https://djangosnippets.org/snippets/2533/#c5977 | |
| import inspect | |
| from django.utils.html import strip_tags | |
| from django.utils.encoding import force_text | |
| def process_docstring(app, what, name, obj, options, lines): | |
| # This causes import errors if left outside the function | |
| from django.db import models |