Skip to content

Instantly share code, notes, and snippets.

🌴
On vacation

言葉 GitHub30

🌴
On vacation
Block or report user

Report or block GitHub30

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View async$.js
// XPath Helper
// https://wiki.greasespot.net/XPath_Helper
function $x() {
var x='';
var node=document;
var type=0;
var fix=true;
var i=0;
var cur;
View mysql regex.txt
'^([^'\\]|\\.|'')*$'
"^([^"\\]|\\.|"")*$"
^SELECT age FROM users WHERE name = '([^'\\]|\\.|'')*'$
//
View firesql.cnf
[mysqld]
character-set-server = utf8mb4
collation-server = utf8mb4_bin
server-id = 1
log_bin = /var/log/mysql/mysql-bin.log
[client]
default-character-set = utf8mb4
View support_typescript.sh
git clone https://github.com/GitHub30/vscode-remote-try-nuxt.git
code-insiders vscode-remote-try-nuxt/
cd \
&& git clone https://github.com/takehiro-takahashi/create-nuxt-app.git \
&& cd create-nuxt-app/ \
&& git checkout support_typescript \
&& yarn \
&& cd /workspaces/vscode-remote-try-nuxt/
View gist:85baea6c47c7114684b967207d06522f
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import math
import random
import chainer
import chainer.functions as F
import chainer.links as L
import numpy as np
from chainer import reporter
View GitHub Stars shortcut.user.js
// ==UserScript==
// @name GitHub Stars shortcut
// @namespace http://tampermonkey.net/
// @version 0.1
// @description Press p to move Prev. Press n to move Next
// @author You
// @match https://github.com/GitHub30?*tab=stars
// @grant none
// ==/UserScript==
View extract-github-urls-from-qiita.js
sleep=s=>new Promise(r=>setTimeout(r,1e3*s)) // await sleep(1)
var urls = $$('body > div.allWrapper > div.p-organization_wrapper > div.p-organization_container > div > div:nth-child(2) > section > div > ul > li > a').map(a => a.href)
urls.forEach(async (u, i) => {
await sleep(i)
var doc = new DOMParser().parseFromString(await fetch(u).then(r => r.text()), "text/html")
var a = doc.querySelector('a[href^="https://github.com/"]')
if(a) console.log(a.href)
})
View gist:b15136a17c55b209b74b9dfd1fb297af
Operation inhibited by "disco" (PID 3502 "gnome-session-b", user disco), reason is "user session inhibited".
Please retry operation after closing inhibitors and logging out other users.
Alternatively, ignore inhibitors and users with 'systemctl poweroff -i'.
View install_node_npm_yarn.sh
# https://nodejs.org/ja/download/package-manager/#debian-and-ubuntu-based-linux-distributions-enterprise-linux-fedora-and-snap-packages
# https://github.com/nodesource/distributions/blob/master/README.md
curl -sL https://deb.nodesource.com/setup_12.x | sudo -E bash - \
&& sudo apt-get install -y nodejs \
&& curl -sL https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add - \
&& echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list \
&& sudo apt-get update \
&& sudo apt-get install -y yarn \
&& echo 'PATH="$HOME/.yarn/bin:$PATH"' >> ~/.profile \
View shutdown-on-download-complete.sh
source ~/.config/user-dirs.dirs
while [ -f $XDG_DOWNLOAD_DIR/*.crdownload ]
do
sleep 1
done
sudo poweroff
You can’t perform that action at this time.