任意のチャンネルでメールを受信できるようにするための AWS Lambda(Python) スクリプトです。
説明リンク: TBD
| { | |
| "title": "mic", | |
| "rules": [ | |
| { | |
| "description": "押している間マイクをOnに", | |
| "manipulators": [ | |
| { | |
| "from": { | |
| "key_code": "f14", | |
| "modifiers": { |
| import base64 | |
| import random, string | |
| def b64(s): | |
| return (base64.b64encode(s.encode())).decode() | |
| def rnd(): | |
| return ''.join(random.choices(string.punctuation + string.ascii_letters, k=7)) | |
| while True: |
| import numpy as np | |
| import matplotlib.pyplot as plt | |
| import matplotlib.animation as animation | |
| fig = plt.figure() | |
| flames = [] | |
| # 投票ラベル ('A': 1, 'B': 2, 'C': 3) に対応 | |
| labels = ['A', 'B', 'C'] |
| from pongpy.interfaces.team import Team | |
| from pongpy.models.game_info import GameInfo | |
| from pongpy.models.state import State | |
| class MyTeam(Team): | |
| """ https://github.com/pistatium/pong """ | |
| @property | |
| def name(self) -> str: | |
| return 'myteam' |
任意のチャンネルでメールを受信できるようにするための AWS Lambda(Python) スクリプトです。
説明リンク: TBD
| import os | |
| import boto3 | |
| from collections import defaultdict | |
| CLUSTER = os.environ.get('TARGET_CLUSTER') | |
| ecs = boto3.client('ecs') | |
| token = '' | |
| cpus = defaultdict(int) |
| #!/bin/bash | |
| msg=`cat "$1"` | |
| if [[ "$msg" =~ ^[^:] ]]; then | |
| echo >&2 Commit message is not starting emoji. | |
| exit 1 | |
| fi | |
| # emojify 後と比較して変わってなければ不正な絵文字 |
| javascript:prompt('URL ForHatena Blog embed','<iframe frameborder="0" height="150" scrolling="no" src="//hatenablog-parts.com/embed?url='+location.href+'" style="width:100%;height:155px;margin:0 0 20px 0;display:block;" width="300"></iframe>')(); |
| from datetime import timedelta, datetime | |
| from django.utils import timezone | |
| from django.test import TestCase | |
| from django import template | |
| register = template.Library() | |
| @register.filter() | |
| def timeago(dt: datetime, now_dt: datetime=None) -> str: |