# https://developer.aliyun.com/article/110806
sudo apt-get update
sudo apt-get install ca-certificates curl
sudo install -m 0755 -d /etc/apt/keyrings
sudo curl -fsSL https://mirrors.aliyun.com/docker-ce/linux/debian/gpg -o /etc/apt/keyrings/docker.asc
sudo chmod a+r /etc/apt/keyrings/docker.asc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export const fetchAsBlob = url => fetch(url) | |
.then(response => response.blob()); | |
export const convertBlobToBase64 = blob => new Promise((resolve, reject) => { | |
const reader = new FileReader; | |
reader.onerror = reject; | |
reader.onload = () => { | |
resolve(reader.result); | |
}; | |
reader.readAsDataURL(blob); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Reasonably efficient pagination without OFFSET | |
-- SQLite version (Adapted from MS SQL syntax) | |
-- Source: http://www.phpbuilder.com/board/showpost.php?p=10376515&postcount=6 | |
SELECT foo, bar, baz, quux FROM table | |
WHERE oid NOT IN ( SELECT oid FROM table | |
ORDER BY title ASC LIMIT 50 ) | |
ORDER BY title ASC LIMIT 10 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Website you intended to retrieve for users. | |
const upstream = 'api.openai.com' | |
// Custom pathname for the upstream website. | |
const upstream_path = '/' | |
// Website you intended to retrieve for users using mobile devices. | |
const upstream_mobile = upstream | |
// Countries and regions where you wish to suspend your service. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
property defaultSlideDuraton : 2 | |
property pauseBeforeSpeaking : 0 -- 1.5 | |
property stoppingStatement : "[[slnc 1000]] Stopping presentation." | |
-- my startRecordScreen | |
tell application "QuickTime Player" | |
activate | |
set newScreenRecording to new screen recording | |
tell newScreenRecording | |
start |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Source: https://twitter.com/calebporzio/status/1151876736931549185 | |
<div class="flex"> | |
<aside class="h-screen sticky top-0"> | |
// Fixed Sidebar | |
</aside> | |
<main> | |
// Content | |
</main> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"version":1,"resource":"file:///Users/fq/workspace.books/tek_commerce_and_humankind_2/src/chapters/different_life.md","entries":[{"id":"gNyV.md","timestamp":1657091957666},{"id":"9Wm8.md","timestamp":1657091994585},{"id":"rWrU.md","timestamp":1657092198062},{"id":"czaM.md","timestamp":1657092282114},{"id":"IcPm.md","timestamp":1657092305666},{"id":"kVky.md","timestamp":1657092322227},{"id":"N2Sj.md","timestamp":1657092376489},{"id":"ehOG.md","timestamp":1657092475226},{"id":"TEDx.md","timestamp":1657092485247},{"id":"crGG.md","timestamp":1657092518926},{"id":"V3mT.md","timestamp":1657092635402},{"id":"2AI5.md","timestamp":1657092667155},{"id":"J2eq.md","timestamp":1657092743759},{"id":"a36n.md","timestamp":1657092765447},{"id":"y3G7.md","timestamp":1657092832188},{"id":"Vlw4.md","timestamp":1657092872535},{"id":"VPuQ.md","timestamp":1657092935024},{"id":"wb4g.md","timestamp":1657092960999},{"id":"rkB7.md","timestamp":1657092987525},{"id":"x57R.md","source":"Workspace Edit","timestamp":1657092995836},{"id":"I |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type D=Double;def w(x:D,y:D,a:D)={val(i,j)=(x-a,y-8);Math.sqrt(i*i+j*j)< 8};val l:Stream[Char]="love".toStream#:::l;val c=l.toIterator;def p(b:Boolean)=print(if(b)c.next else' ');for(y<-0 to 24){for(x<-0 to 32){if(y>7)p((16-x).abs< 24-y)else p(w(x,y,8)|w(x,y,24))};println} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
哪有什么岁月静好,无非是有人替你寻衅滋事罢了,比如老罗与暖气片的故事 |
NewerOlder