AWS SDK for JavaScript v3 ã使ã£ã¦ãS3 ããåã£ã¦ã㦠S3 ã«ç½®ã
JavaScript çã® AWS SDK 㯠v3 ãåºã¦ãã¦ããã¨ãã°ãAWS Lambda 㧠Node.js 18.x ãã©ã³ã¿ã¤ã ã«é¸æããå ´å SDK ã使ããªããããããã©ã«ãã«ãªã£ã¦ããã
å ¬å¼ãã¼ã¸: https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/
AWS SDK v3 ã使ãã¨ãã® S3 ããåã£ã¦ãã¦ä¿åããããS3 ã«ã¢ãããã¼ããããããã¨ãã®ã¡ã¢ã
ã¡ãªã¿ã« ReadableStream ã®ä½¿ãæ¹å«ãããããããªãã£ãã¨ãã㯠Bing ã®ãã£ãã AI ã«å©ãã¦ããã£ããAI ãããã
å ¬å¼ãµã³ãã«ã³ã¼ã: https://docs.aws.amazon.com/ja_jp/sdk-for-javascript/v3/developer-guide/javascript_s3_code_examples.html
import { createWriteStream, createReadStream } from "fs"; import { S3Client, GetObjectCommand, PutObjectCommand } from "@aws-sdk/client-s3"; const s3Client = new S3Client({ region: "ap-northeast-1" }); async function run() { const data = await s3Client.send(new GetObjectCommand({ Bucket: "mybucket", Key: "foo/bar/gazou.png", })); const writeStream = createWriteStream("/tmp/gazou.png"); data.Body.pipe(writeStream); await new Promise((resolve, reject) => { // ãããå¿ è¦ writeStream.on("finish", resolve); writeStream.on("error", reject); }); // todo: process const readStream = createReadStream("/tmp/kakou.png"); await s3Client.send(new PutObjectCommand({ Bucket: "mybucket", Key: "foo/bar/kakou.png", Body: readStream, })); } run();
memo.txt ãè±å´ãã¦ãObsidian + Google ãã©ã¤ãã試ãã¦ã¿ã¦ãã
ãã¾ã¾ã§ã¡ã¢ç³»ã®ãã¨ã¯ã²ããã memo.txt ã«è¿½è¨ãã¦ããã¨ããæãããåç´ãªãã¨ãããã¦ããªãã£ãã®ã ãã©ã
ãããã«ããã©ããªã£ã¦ããã®ã§å¿æ©ä¸è»¢ãã¡ã¢ã¢ããªã使ããã¨ã«ããã
ã¡ãã¨èª¿æ»ããã¨ãããObsidian ãè¯ãããã ã£ãã®ã§ã試ãã¦ã¿ã¦ããã
Vault ã¨ããåä½ã§ã¡ã¢ãã¡ã管çããã¦ãã¦ããã® Vault èªä½ãã¯ã©ã¦ãã¹ãã¬ã¼ã¸ã§ãã Google ãã©ã¤ãã«ä¿åãã¦ããããèªã¿è¾¼ãå½¢ã§ãWindows10 ã®ã¡ã¤ã³æ©ã¨ Mac Book Air ã®ãµãæ©éã§ã®åæãã§ããã
ã¨ããããã¯ããã¾ãé å¼µããªãæãã§ãã¾ã¾ã§ã® memo.txt ãæ¯ãè¿ããªãããå°æ¥ãè¦è¶ãã¦ã¿ã°ãã¤ãã¤ã¤ Obsidian ã«ç§»ãã¦ãã£ã¦ã¿ããã¨æãã
ã2023-02-27 追è¨ã
Obsidan ã§ã¯ãªãã¦ãObsidian ã ã£ãããã³ãµã¬ã®ãªãã·ãã³ã½ã¼ãã«å¼ã£å¼µããã¦ãã
社å ããã°ãã¨ãã
ä»å¹´ã¯ 2022 å¹´ã®å¾åã«ç¤¾å ããã°ã 9 æ¬æ¸ããã¦ããã£ããããã«ã¤ãã¦ãã¨ããçãªä½ãã
ç¶ããèªã