Skip to content

Instantly share code, notes, and snippets.

View KEINOS's full-sized avatar

KEINOS KEINOS

View GitHub Profile
@myobie
myobie / ci.yml
Last active September 20, 2023 09:26
Don't run GitHub Actions for pull requests that are drafts
on:
push:
branches:
- master
pull_request:
types:
- opened
- reopened
- synchronize
- ready_for_review
@hidao80
hidao80 / Right-click-jammer-canceller.bookmarklet.js
Last active September 5, 2023 09:46
Bookmarklet to enable context menus on web pages that do not allow right-clicking.
javascript:(()%3D%3E%7B!function()%7Bfor(const%20o%20of%5Bdocument%2Cdocument.body%5D)o.addEventListener(%22contextmenu%22%2C(o%3D%3E%7Bo.stopImmediatePropagation()%7D)%2C!0)%7D()%3B%7D)()
/**
* Copyright (c) 2022 hidao80
* Released under the MIT license
* https://opensource.org/licenses/mit-license.php
*/
(function () {
const instance = "https://misskey.dev";
const link_text = "選択範囲へ直リンク";
const LF = '\n';
const CR = '\r';
@noonat
noonat / coreos-virtualbox.md
Last active February 10, 2023 22:00
Installing CoreOS on VirtualBox
  • Download and install VirtualBox.
  • Download the CoreOS ISO
  • Create a new VM in VirtualBox
    • For the OS, Other Linux, 64-bit should be fine
    • Give the VM 1gb of memory, like your physical hardware has.
    • Create a disk of whatever size you want. I made a VMDK file that could expand dynamically up to 8gb.
  • Mount the ISO in the VM
    • Right click on the VM and click settings
  • Go to the storage tab
@nikuyoshi
nikuyoshi / build-crosscompile-env.sh
Last active November 20, 2022 13:17
Goのクロスコンパイル環境構築のためのシェルスクリプト
#!/bin/sh
# Environment list
# $GOOS $GOARCH
# darwin 386
# darwin amd64
# freebsd 386
# freebsd amd64
# freebsd arm
# linux 386
@rodneyrehm
rodneyrehm / mb_range.php
Created October 22, 2011 15:35
PHP: mb_range() - Unicode compatible range('A', 'Z')
<?php
mb_internal_encoding('UTF-8');
/**
* multibyte string compatible range('A', 'Z')
*
* @param string $start Character to start from (included)
* @param string $end Character to end with (included)
* @return array list of characters in unicode alphabet from $start to $end
@kaloprominat
kaloprominat / url: mac os online launchd plist generator
Created July 25, 2013 22:07
url: mac os online launchd plist generator
http://launched.zerowidth.com/
@miguelmota
miguelmota / ipfs
Last active February 25, 2022 23:03
IPFS daemon run in background
ipfs daemon > ipfs.log &
@t-asa2000
t-asa2000 / twitter_customize.css
Last active November 28, 2021 07:28
自分仕様のTwitter(2020.7.23現在) #stylus #css
/*緑ベースのUIにする*/
svg.r-13gxpu9.r-4qtqp9.r-yyyyoo.r-16y2uox.r-1q142lx.r-8kz0gk.r-dnmrzs.r-bnwqim.r-1plcrui.r-lrvibr,.r-nw8l94 {
color: #00BC00;
}
.r-b5skir {
background-color: #00BC00;
}
/*サイドバーを非表示にする*/
@okapies
okapies / mastodon-ostatus.md
Last active September 5, 2021 11:39
Mastodon OStatus API の叩き方

Mastodon が他のインスタンスと情報交換をする OStatus API の使い方。使ってるだけのユーザは知る必要がない裏側の話。

host-meta

Mastodon インスタンスに対して、RFC6415 が規定する /.well-known/host-meta というパスを要求すると以下の XML が返ってくる.

<?xml version="1.0"?>
<XRD xmlns="http://docs.oasis-open.org/ns/xri/xrd-1.0">
  <Link rel="lrdd" type="application/xrd+xml" template="https://[MASTODON_HOST]/.well-known/webfinger?resource={uri}"/>
</XRD>