This file contains hidden or 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
material/templates/.icons/fontawesome | |
├── LICENSE.txt | |
├── brands | |
│ ├── 42-group.svg | |
│ ├── 500px.svg | |
│ ├── accessible-icon.svg | |
│ ├── accusoft.svg | |
│ ├── adn.svg | |
│ ├── adversal.svg | |
│ ├── affiliatetheme.svg |
This file contains hidden or 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
ab-testing.svg | |
abacus.svg | |
abjad-arabic.svg | |
abjad-hebrew.svg | |
abugida-devanagari.svg | |
abugida-thai.svg | |
access-point-check.svg | |
access-point-minus.svg | |
access-point-network-off.svg | |
access-point-network.svg |
This file contains hidden or 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
1001tracklists.svg | |
1password.svg | |
2k.svg | |
365datascience.svg | |
3m.svg | |
42.svg | |
4chan.svg | |
4d.svg | |
500px.svg | |
7zip.svg |
This file contains hidden or 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
"""OpenAI の Assistant stream API を使う | |
Usage: | |
python -m pip install 'openai==1.14.0' | |
export OPENAI_API_KEY='...' | |
python openai_assistant_stream.py | |
See: https://platform.openai.com/docs/assistants/overview?context=with-streaming | |
""" |
This file contains hidden or 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
# Ignore | |
xattr -w 'com.apple.fileprovider.ignore#P' 1 my-directory | |
# Disable ignoring | |
xattr -d 'com.apple.fileprovider.ignore#P' my-directory | |
# My aliases | |
alias dropbox-exclude="xattr -w 'com.apple.fileprovider.ignore#P' 1" | |
alias dropbox-include="xattr -d 'com.apple.fileprovider.ignore#P'" |
This file contains hidden or 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
#!/usr/bin/env python3 | |
"""Prefix lines with natural numbers.""" | |
import sys | |
from typing import Literal | |
NUMBER_SUFFIX = "." | |
def main() -> str | Literal[0]: | |
if sys.stdin.isatty(): |
This file contains hidden or 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
/** | |
* Wait for the specified milliseconds. | |
*/ | |
async function waitFor(msec) { | |
await new Promise((resolve) => setTimeout(resolve, msec)); | |
} |
This file contains hidden or 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
<?php | |
/** | |
* `WP_HTML_Tag_Processor` Modifies attributes in an HTML document for tags matching a query. | |
*/ | |
$html = '<span><img src="hello.webp" alt="hello"></span>'; | |
// Create an instance | |
$tags = new WP_HTML_Tag_Processor( $html ); |
This file contains hidden or 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
// Function: | |
async function saveFile(fh, content) { | |
const stream = await fh.createWritable(); | |
await stream.write(content, {type: "text/plain"}); | |
await stream.close(); | |
} | |
// Usage: | |
const content = 'Hello world'; | |
const fh = await window.showSaveFilePicker(); |
This file contains hidden or 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
# Exclude log records for internal dummy connections. | |
SetEnvIf Remote_Addr "127\.0\.0\.1" loopback | |
CustomLog ${APACHE_LOG_DIR}/access.log combined env=!loopback |