https://qiita.com/yabeenico/items/15532c703974dc40a7f5 を超参考にさせてもらっています
まずはホストキーがないので生成
$ sudo ssh-keygen -t rsa -N '' -f /etc/ssh/ssh_host_rsa_key
https://qiita.com/yabeenico/items/15532c703974dc40a7f5 を超参考にさせてもらっています
まずはホストキーがないので生成
$ sudo ssh-keygen -t rsa -N '' -f /etc/ssh/ssh_host_rsa_key
# -*- coding: utf-8 -*- | |
from __future__ import print_function | |
import socket | |
import ssl | |
import pprint | |
try: | |
ssl.HAS_TLSv1_3 | |
except AttributeError: |
#!/bin/bash | |
# -*- coding: utf-8 -*- | |
# $HOME/.dqxpresence format | |
# { | |
# "slack_token": "xoxp-xxxx", | |
# "id": 667538238772, | |
# "icon_emoji": ":dot_slime:" | |
# } | |
# id は https://hiroba.dqx.jp/sc/character/${user_id} です。マイページ全体の公開設定が『制限なしで公開』になっている必要があります。 | |
slack_token=$(cat $HOME/.dqxpresence | jq -r .slack_token) |
#!/bin/bash | |
# -*- coding: utf-8 -*- | |
# 東京アメッシュの画像を取得して合成 | |
now=$(date +%s) | |
BASE_URL=https://tokyo-ame.jwa.or.jp | |
MAP=/map/map000.jpg | |
MSK=/map/msk000.png | |
# https://tokyo-ame.jwa.or.jp/mesh/000/201906071525.gif | |
rfm=$(date --date=@$((now / (5 * 60) * 5 * 60 - 5 * 60)) +%Y%m%d%H%M) |
for f in $(curl -s https://www.asahi.com/articles/ASL4J669JL4JUEHF016.html | sed -e 's,^<td class="link"><a href="\(.*.pdf\)".*$,\1,p;d'); do wget $f; done |
https://api.slack.com/custom-integrations/legacy-tokens チームのトークンを発行(これは自分用になります)
/usr/bin/curl -s -X POST -d 'token=YourToken' -d "profile={\"display_name\":\"ほげほげ\"}" https://slack.com/api/users.profile.set
とか
#!/usr/bin/perl -l | |
# -*- coding: utf-8 -*- | |
use strict; | |
use warnings; | |
my $word = $ARGV[0]; | |
exit unless $word; | |
use NKF; | |
use LWP::UserAgent; |