Skip to content

Instantly share code, notes, and snippets.

@tukiyururu
tukiyururu / index.html
Last active September 4, 2022 11:47
ブラウザの音声認識を利用して、自分の発言をVOICEVOXに読上げてもらうJavaScript+HTML。任意のデバイスで再生可能。
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>VOICEVOX TALK</title>
</head>
<script>
class Queue {
constructor() {
this.array = new Array();
@tukiyururu
tukiyururu / readme.md
Last active August 16, 2022 16:20
Win10でGit BashからVOICEVOXのAPIを叩いて、SoXを使用して任意のデバイスで再生するシェルスクリプト。

必要なもの

  • Windows
  • Git
  • SoX(Sound eXchange)
  • VOICEVOX
  • 任意の再生デバイス

環境

  • Windows 10 Home
  • git version 2.37.1.windows.1
@tukiyururu
tukiyururu / clasp-webpack-plugin.js
Last active May 4, 2022 12:38
webpack用claspプラグイン
const fs = require("fs");
/**
* webpack用claspプラグイン
* @class {ClaspPlugin}
*/
class ClaspPlugin {
/**
* @constructor
* @param {object} config
@tukiyururu
tukiyururu / env.py
Last active December 23, 2020 14:27
Spotifyで再生中の曲をTwitterに投稿するなんちゃってなうぷれ。Python統一版。
# Twitter認証のコンシューマキー
CONSUMER_KEY = "xxxxxxxxxxxxxxxxxxxxxxxxx"
CONSUMER_SECRET = "xxxxxxxxxxxxxxxxxxxxxxxxx"
# Twitter認証のアクセストークン
ACCESS_TOKEN = "xxxxxxxxxxxxxxxxxxxxxxxxx"
ACCESS_TOKEN_SECRET = "xxxxxxxxxxxxxxxxxxxxxxxxx"
# Spotify認証のクライアントID
SPOTIPY_CLIENT_ID = "xxxxxxxxxxxxxxxxxxxxxxxxx"
SPOTIPY_CLIENT_SECRET = "xxxxxxxxxxxxxxxxxxxxxxxxx"
@tukiyururu
tukiyururu / .vimrc
Created August 13, 2020 16:11
自分用 Vim 設定
"---------------------------------------------------------------------------
" 検索の挙動に関する設定:
"
" 検索時に大文字小文字を無視
set ignorecase
" 大文字小文字の両方が含まれている場合は大文字小文字を区別
set smartcase
" 検索時にファイルの最後まで行ったら最初に戻らない
set nowrapscan
@tukiyururu
tukiyururu / mstdn-accesstoken.js
Created September 30, 2018 11:00
Mastodonのアクセストークンを取得する 参考:https://qiita.com/albno273/items/eb109820125faf7638cd
const readline =require("readline");
const Mastodon = require("mastodon-api");
const rl = readline.createInterface({
input: process.stdin,
output: process.stdout
})
let clientId
let clientSecret
@tukiyururu
tukiyururu / tweet_json.py
Created August 14, 2017 07:18
ツイートのjsonデータを保存する
# -*- coding: utf-8 -*-
"""
ツイートのjsonデータを保存する
"""
import os
from sys import argv
import codecs
import json
import tweepy
from dotenv import load_dotenv
@tukiyururu
tukiyururu / twitter_media.py
Last active September 12, 2024 00:54
特定ユーザのTwitterの画像・動画を全取得する
# -*- coding: utf-8 -*-
"""
特定ユーザのTwitterの画像・動画を全取得する
"""
import os
import re
from sys import argv
from urllib.request import urlopen
from urllib.parse import urlparse
from json import loads
@tukiyururu
tukiyururu / urara.py
Last active May 14, 2017 15:03
うらら迷路帖の公式HPにあるアイコンを一括DLする
# -*- coding: utf-8 -*-
"""
うらら迷路帖の公式HPにあるアイコンを一括DLする
"""
import os
from urllib.request import urlopen
from bs4 import BeautifulSoup
def save(url, link):
@tukiyururu
tukiyururu / keybindings.json
Last active May 3, 2022 17:28
自分用 Visual Studio Code 設定
[
{ "key": "ctrl+`", "command": "workbench.action.toggleSidebarVisibility" },
{ "key": "ctrl+\\", "command": "workbench.action.terminal.toggleTerminal" },
{ "key": "ctrl+b", "command": "workbench.action.debug.continue", "when": "inDebugMode" },
{ "key": "ctrl+b", "command": "workbench.action.debug.start", "when": "!inDebugMode" },
{ "key": "shift+b", "command": "workbench.action.debug.stop", "when": "inDebugMode" },
{ "key": "ctrl+l", "command": "editor.action.selectHighlights", "when": "editorFocus" },
{ "key": "ctrl+shift+l", "command": "extension.shunt_left", "when": "editorHasSelection && editorTextFocus" }
]