Skip to content

Instantly share code, notes, and snippets.

View Lycolia's full-sized avatar
🍥

Lycolia Rizzim Lycolia

🍥
View GitHub Profile
@Lycolia
Lycolia / .htaccess
Last active February 18, 2021 12:23
C-lang-CGI-example
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /test.cgi [L]
</IfModule>
@Lycolia
Lycolia / Redmine wiki TOC navigator.user.js
Created February 18, 2021 12:23
Redmine-wiki-ToC-floating-navigator
// ==UserScript==
// @name Redmine-wiki-ToC-floating-navigator
// @namespace https://github.com/Lycolia
// @version 0.2
// @description Redmine wiki ToC floating navigator, for 4.1.1.stable
// @author Lycolia
// @match *://*/redmine/projects/*/wiki/*
// @grant none
// ==/UserScript==
@Lycolia
Lycolia / MyDNS.jp-v4-Update.sh
Created February 21, 2021 23:27
update ip-address for MyDNS.jp by bash
#!/bin/bash
# 関数定義
## ログ出力して終了
put_exit_log() {
# ログ文字列生成
log_mes="DATE:${exec_date}"
log_mes="${log_mes}\tIP_GET_STATE:${ip_rescd}"
log_mes="${log_mes}\tGET_v4IP:${ipv4_addr}"
log_mes="${log_mes}\tMyDNS_UPDATE_STATE:${ddns_rescd}"
@Lycolia
Lycolia / switch-pull-back-branch.py
Created February 21, 2021 23:32
git switch pull back branch with auto --skip-work-tree
#!/usr/bin/env python
# -*- coding: utf-8 -*-
#region 環境
import sys
import subprocess
# トレースバック非表示
sys.tracebacklimit = 0
@Lycolia
Lycolia / remove-git-shellex.reg
Created March 15, 2021 01:04
Remove git shell extention
Windows Registry Editor Version 5.00
[-HKEY_CLASSES_ROOT\Directory\shell\git_gui]
[-HKEY_CLASSES_ROOT\Directory\shell\git_shell]
[-HKEY_CLASSES_ROOT\LibraryFolder\background\shell\git_gui]
[-HKEY_CLASSES_ROOT\LibraryFolder\background\shell\git_shell]
[-HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Directory\background\shell\git_gui]
[-HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Directory\background\shell\git_shell]
@Lycolia
Lycolia / user.js
Last active April 3, 2021 09:18
Disable Google analytics by owner access
// ==UserScript==
// @name Disable Google analytics
// @description Disable Google analytics by owner access
// @author Lycolia Rizzim
// @namespace https://lycolia.info/
// @version 0.1
// @match pattern here
// @run-at document-start
// @grant none
// ==/UserScript==
@Lycolia
Lycolia / get-tsv-weight-and-body_fat-from-asken_web.js
Last active December 10, 2021 00:48 — forked from yosiopp/get_weights_from_asken.js
asken.jpのPC画面で日付、体重、体脂肪率をTSV形式で取得
/**
* ## 使い方
*
* 1. あすけん PC サイトにログイン
* 2. データを取得したい範囲で beginYear, endYear を設定
* 3. ブラウザのコンソールにこのスクリプトを流す
* 4. TSV がコンソールに出力される
*/
/** データ取得開始年 */
@Lycolia
Lycolia / get-progress-func.sh
Last active January 17, 2022 00:50
Get progress of specified in GitHub Issues
#!/bin/bash
getProgress() {
local issueNo=$1
local issue=$(curl -sS \
-H "Authorization: token $GH_TOKEN" \
-H "Accept: 'application/vnd.github.v3+json'" \
https://api.github.com/repos/$TARGET_REPO/issues/$issueNo \
| perl -lpe 's/\n//')
@Lycolia
Lycolia / yarpp-template-thumbnail.php
Last active March 30, 2023 11:48
YARPP thumbnail template for SANGO theme
<?php
function get_post_data($post_id) {
$url = esc_url(get_permalink($post_id));
$title = esc_attr(get_the_title($post_id));
$img = '';
if (has_post_thumbnail($post_id)) {
$img = get_the_post_thumbnail_url($post_id, 'thumb-520');
} else {
@Lycolia
Lycolia / stable-diffusion-webui-preset.ipynb
Last active May 3, 2023 19:15
Stable Diffusion web UI(AUTOMATIC1111) setup preset
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.