Skip to content

Instantly share code, notes, and snippets.

View azu's full-sized avatar

azu azu

View GitHub Profile
@azu
azu / z.zsh
Created January 19, 2023 08:04
zoxide + fzf + bat + exa
# https://github.com/ajeetdsouza/zoxide
export _ZO_FZF_OPTS='
--no-sort --height 75% --reverse --margin=0,1 --exit-0 --select-1
--bind ctrl-f:page-down,ctrl-b:page-up
--bind pgdn:preview-page-down,pgup:preview-page-up
--prompt="❯ "
--color bg+:#262626,fg+:#dadada,hl:#f09479,hl+:#f09479
--color border:#303030,info:#cfcfb0,header:#80a0ff,spinner:#36c692
--color prompt:#87afff,pointer:#ff5189,marker:#f09479
--preview "([[ -e '{2..}/README.md' ]] && bat --color=always --style=numbers --line-range=:50 '{2..}/README.md') || exa --color=always --group-directories-first --oneline {2..}"
@azu
azu / GitHub Issue: Open VSCode.user.js
Last active January 16, 2023 05:57
Greasemonkey: Open GitHub Issue in VSCode
// ==UserScript==
// @name GitHub Issue: Open VSCode
// @namespace info.efcl.open-vscode-
// @match https://github.com/*/*/issues/*
// @match https://github.com/*/*/pull/*
// @grant GM_download
// @grant GM_openInTab
// @grant GM_registerMenuCommand
// @version 1.0
// @author azu
@azu
azu / README.md
Last active January 16, 2023 14:46
Migration Script: Convert TypeScript project to Node.js dual package

Convert TypeScript library project to Node.js Dual Package

It is a script to convert a TypeScript library project to a Node.js Dual CommonJS/ES module packages.

This script aim to convert following project:

  • Use TypeScript
  • Use ts-node
  • Use mocha
@azu
azu / all-env-circleci.mjs
Last active January 6, 2023 06:28
Get Circle CI Project envars! Require Node.js 16 + `npm install node-fetch`
import fetch from "node-fetch"; // Node.js 18 just remove line
const CIRCLECI_TOKEN = process.env.CIRCLECI_TOKEN
const ORG_NAME = process.env.ORG_NAME
const fetchProjectList = (orgName = ORG_NAME) => {
return fetch(`https://circleci.com/api/v2/insights/gh/${orgName}/summary`, {
headers: { "Circle-Token": `${CIRCLECI_TOKEN}` }
}).then(res => res.json()).then(json => json.all_projects);
};
const fetchProjectEnv = (orgName, project) => {
@azu
azu / @dependabot merge.js
Last active January 4, 2023 15:33
Google Apps Script: auto reply `@dependabot merge`
// MIT LICENSE ©️ azu
// Usage:
// 1. Create `MERGE_REPLY_LABEL`
// 2. Upload GAS
// 3. Update CONFIG
// 4. Execute `createTimeTrigger` function on GAS
// === CONFIG ====
// Interval hours
const FETCH_INTERVAL_HOURS = 12;
const YOUR_MAIL_ADDRESS = "{yourmail}@gmail.com"
@azu
azu / notion-daily-generator.mjs
Created January 1, 2023 06:36
notion-daily-generator.mjs
import { Client } from "@notionhq/client"
import dayjs from "dayjs"
const notion = new Client({
auth: process.env.NOTION_API_TOKEN,
});
/**
*
* @param {title} title
@azu
azu / ublacklist-best-of.txt
Created December 30, 2022 23:45
ublacklist: best of N
*://ranking.goo.ne.jp/*
*://my-best.com/*
*://sakidori.co/*
*://wowma.jp/*
*://osusume.mynavi.jp/*
*://pc.moppy.jp/*
*://heim.jp/*
*://www.esquire.com/*
*://epark.jp/*
*://iecolle.com/*
@azu
azu / input.user.js
Created November 23, 2022 05:58
get input text
// ==UserScript==
// @name Visual Textarea
// @namespace textarea
// @include http://*
// @include https://*
// @grant none
// @version 1.0
// @author -
// @description 2022/11/23 14:19:51
// ==/UserScript==
@azu
azu / 2022.08.23-ubuntu-18.04u.yml
Last active August 23, 2022 13:57
shepherd script: update ubuntu-18.04 to ubuntu-latest on GitHub Actions
id: 2022.08.23-ubuntu-18.04
title: "CI: update ubuntu-18.04 to ubuntu-latest"
adapter:
type: github
search_type: code
search_query: org:{{user}} path:/.github/workflows
hooks:
should_migrate:
- ls .github/workflows
- find .github/workflows -type f -name "*.y*ml" -exec grep "ubuntu-18.04" {} +;
@azu
azu / 日本伴走型支援協会 設立記念シンポジウム.md
Last active August 15, 2022 11:57
📝 2022/3/12 日本伴走型支援協会 設立記念シンポジウム

2022/3/12 日本伴走型支援協会 設立記念シンポジウム - YouTube

  • 絆の制度化が可能なのか?というところから始まって → 伴走型という言葉が生まれた
  • ホームレスにハウスを提供しても、ホームがない
    • 自立(支援)が孤立につながっている
  • 国の支援で孤独についての研究をずっとやっていたけど、ネタ切れで2018年ぐらいに途切れそうになっていた
  • 2018年に孤立孤独の問題が世界的に起きたので、つながりがきれそうなところがあった
  • けど、このときに伴走型支援的なことを今までやっていのがつながった
  • タイミングがきた感じ
  • コロナで人の関わりを途切れた