Skip to content

Instantly share code, notes, and snippets.

View reud's full-sized avatar
:octocat:
Working

reud reud

:octocat:
Working
View GitHub Profile
@reud
reud / ext.js
Created January 21, 2023 17:06
VSCodeで日記を書くときに使ってる自作拡張機能。これを導入すると右下に日記を作るボタンとか出てきてそれをおすとファイルの作成を良い感じにやってくれます
// The module 'vscode' contains the VS Code extensibility API
// Import the module and reference it with the alias vscode in your code below
import * as vscode from 'vscode';
import { execSync } from 'child_process';
import { create } from 'domain';
const nowyyyymmdd = () => {
var dt = new Date();
const y = dt.getFullYear();
@reud
reud / 台本.md
Created December 22, 2020 13:41
アドベントカレンダー25日用に依頼する時に書いたもの

ご確認ありがとうございます。

reud(れうど)と申します。12/25にブログの記事を書くことになったので、 「クリスマスデートをしてきました。」という流れで以下のボイスドラマを載せたいです。(Youtubeにアップロードしようと考えています)

また、記事の途中で依頼して声当ててもらったとネタバラシします。

  • 12/21

少々追記をしていますが、依頼するセリフ・背景の変化・追加は無しです。一応共有させていただきます。。

@reud
reud / memo.md
Last active September 29, 2020 17:17
OIDC忘れていたのでメモ

自分がよく分からなかった部分の忘備録

※かなり雑なので間違ってたらそっと教えて!

JWS,JWE,JWK,JWT

JWS

シンプルな署名のデータ構造方式。(RFCだからプロトコル?) ヘッダー.ペイロード.署名でできていて、ペイロードは署名されるデータが入っている

JWE

@reud
reud / dev.ts
Created June 2, 2020 03:54
dev.ts
import { Client, Message, TextChannel } from 'discord.js';
// @ts-ignore
import * as schedule from 'node-schedule';
require('dotenv').config();
const client = new Client();
@reud
reud / EPGStation.sh
Last active April 11, 2020 14:56
setup2-2.sh setup1.shのあとに実行してください 
sudo apt install ffmpeg
# check npm update
sudo chown -R $USER:$(id -gn $USER) /home/$USER/.config
git clone https://github.com/l3tnun/EPGStation.git
cd EPGStation && npm i && npm run build
cp config/config.sample.json config/config.json
cp config/operatorLogConfig.sample.json config/operatorLogConfig.json
cp config/serviceLogConfig.sample.json config/serviceLogConfig.json
--
-- PostgreSQL database dump
--
-- Dumped from database version 11.5 (Debian 11.5-1.pgdg90+1)
-- Dumped by pg_dump version 11.5 (Debian 11.5-1.pgdg90+1)
SET statement_timeout = 0;
SET lock_timeout = 0;
SET idle_in_transaction_session_timeout = 0;
--
-- PostgreSQL database dump
--
-- Dumped from database version 11.5 (Debian 11.5-1.pgdg90+1)
-- Dumped by pg_dump version 11.5 (Debian 11.5-1.pgdg90+1)
SET statement_timeout = 0;
SET lock_timeout = 0;
SET idle_in_transaction_session_timeout = 0;
@reud
reud / dump.sql
Last active October 20, 2019 10:05
Has Many Associationの一番上にある奴 http://gorm.io/ja_JP/docs/has_many.html#Has-Many
--
-- PostgreSQL database dump
--
-- Dumped from database version 11.5 (Debian 11.5-1.pgdg90+1)
-- Dumped by pg_dump version 11.5 (Debian 11.5-1.pgdg90+1)
SET statement_timeout = 0;
SET lock_timeout = 0;
SET idle_in_transaction_session_timeout = 0;
@reud
reud / ABC141D.cpp
Created September 17, 2019 01:06
ABC141D.cpp
#include <iostream>
#include <vector>
#include <queue>
using namespace std;
#define REP(i, n) for(int i=0, i##_len=(n); i<i##_len; ++i)
typedef long long ll;
int main() {
int N, M;
@reud
reud / ABC141DTLE.py
Created September 15, 2019 14:36
ABC141DTLE
import bisect
N,M = map(int,input().split())
As = [int(i) for i in input().split()]
As.sort()
for _ in range(M):
takai = As.pop()
takai//=2
bisect.insort_left(As,takai)