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
import { showHUD, Clipboard } from "@raycast/api"; | |
import OpenAI from 'openai'; | |
import dotenv from 'dotenv'; | |
dotenv.config({ path: '~/.zshrc' }); | |
const openai = new OpenAI({ | |
apiKey: process.env.OPENAI_API_KEY ?? '', | |
}); |
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
ddb-parallel-scan (96%) [224/250] [time:196ms] [total (fetched/scanned/table-size):908/34853064/36298819] +3ms | |
ddb-parallel-scan (96%) [145/250] [time:216ms] [total (fetched/scanned/table-size):920/34854754/36298819] +8ms | |
ddb-parallel-scan (96%) [210/250] [time:232ms] [total (fetched/scanned/table-size):920/34856457/36298819] +5ms | |
ddb-parallel-scan (96%) [211/250] [time:223ms] [total (fetched/scanned/table-size):920/34858126/36298819] +3ms |
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
const {parallelScanAsStream} = require('@shelf/dynamodb-parallel-scan'); | |
(async () => { | |
const stream = await parallelScanAsStream( | |
{ | |
TableName: 'files', | |
FilterExpression: 'attribute_exists(#fileSize)', | |
ExpressionAttributeNames: { | |
'#fileSize': 'fileSize', | |
}, |
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
const {parallelScan} = require('@shelf/dynamodb-parallel-scan'); | |
(async () => { | |
const items = await parallelScan( | |
{ | |
TableName: 'files', | |
FilterExpression: 'attribute_exists(#fileSize)', | |
ExpressionAttributeNames: { | |
'#fileSize': 'fileSize', | |
}, |
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
import {parallelScan} from './src'; | |
(async () => { | |
console.time('fetch'); | |
const data = await parallelScan( | |
{ | |
TableName: 'notifications', | |
FilterExpression: '#updatedAt > :updatedAt and #senderId = :senderId', | |
ExpressionAttributeNames: { |
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 bash | |
# | |
# Download and install standalone binary. | |
# The binary version can be specified by setting a VERSION variable. | |
# e.g. VERSION=2.21.1 bash install.sh | |
# If VERSION is unspecified it will download the latest version. | |
set -e | |
reset="\033[0m" |
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
# usage get_api_key some-name | |
function get_api_key { | |
value=$(aws apigateway get-api-keys --query "items[?name=='${1}'].value" --include-values --output text); | |
echo "${value}"; | |
} |
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
# test directories | |
__tests__ | |
^(?!@serverless/enterprise-plugin/).*test.*$ # fix for serverless-enterprise | |
tests | |
powered-test | |
*.test.js | |
*.tap.js | |
*.test.ts | |
*tests.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 circl { | |
open "https://app.circleci.com/pipelines/github/ORG_NAME_HERE/$(basename $PWD)?branch=$(git rev-parse --abbrev-ref HEAD)" | |
} |
NewerOlder