This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding:utf-8 -*- | |
# ©2024 Yuichiro Nakada | |
# | |
# crontab -e | |
# 0 7,16 * * * python3 ~/weather_line.py | |
# | |
# 絵文字: http://www.shurey.com/memo/emoji.html | |
from dotenv import load_dotenv | |
load_dotenv() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: UTF-8 -*- | |
import sys, json | |
result_json = {'key': 'value'} | |
print('Content-Type:application/json\n\n') | |
print(json.dumps(result_json)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/python | |
# -*- coding: utf-8 -*- | |
# python3 make_report.py Relatorio.csv 3 | |
# pip install pymupdf | |
import fitz | |
import os | |
import glob |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import argparse | |
parser = argparse.ArgumentParser(description='指定された言語の文を抽出します。') | |
parser.add_argument('name', help='file name') | |
parser.add_argument('-l', '--lang', help='select language [ja/en/pt]', default='en') | |
args = parser.parse_args() | |
import re | |
#p = r'\~[^~]*\~' # ~で囲まれている~以外の文字 | |
#p = r'\~.+\~' # ~で囲まれている |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#version 450 | |
layout ( | |
local_size_x = WORKGROUP_SIZE, | |
local_size_y = 1, | |
local_size_z = 1 | |
) in; | |
layout (binding = 0) buffer buf_in { int buffer_in[]; }; | |
layout (binding = 1) buffer buf_out { int buffer_out[]; }; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//--------------------------------------------------------- | |
// Cat's eye | |
// | |
// ©2020 Yuichiro Nakada | |
//--------------------------------------------------------- | |
// clang -Os gpgpu_gl.c -o gpgpu_gl `pkg-config --libs --cflags gl egl gbm` -lglfw | |
// clang -Os gpgpu_gl.c -o gpgpu_gl `pkg-config --libs --cflags glesv2 egl gbm` -lglfw | |
// dnf install mesa-libgbm-devel libdrm-devel mesa-libGL-devel mesa-libGLU-devel mesa-libEGL-devel mesa-libGLES-devel glfw- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# IPoE | |
# WAN | |
description lan1 WAN | |
ngn type lan1 ntt | |
ipv6 route default gateway dhcp lan1 | |
#ipv6 prefix 1 ra-prefix@lan1::/64 | |
ipv6 prefix 1 dhcp-prefix@lan1::/64 | |
ipv6 lan1 address dhcp | |
ipv6 lan1 dhcp service client |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# IPoE | |
# WAN | |
description lan2 WAN | |
ngn type lan2 ntt | |
ipv6 route default gateway dhcp lan2 | |
#ipv6 prefix 1 ra-prefix@lan2::/64 | |
ipv6 prefix 1 dhcp-prefix@lan2::/64 | |
ipv6 lan2 address dhcp | |
ipv6 lan2 dhcp service client |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
i=1 | |
#for f in $(ls -1 *.jpg | sort -t'-' -k2h) | |
ls -1v *.jpg | while read f | |
do | |
mv "$f" $(printf "%04d.jpg" $i) | |
: $((i++)) | |
done |
NewerOlder