Skip to content

Instantly share code, notes, and snippets.

View gythialy's full-sized avatar
🎯
Focusing

Goren G gythialy

🎯
Focusing
View GitHub Profile
@gythialy
gythialy / github_query_pr_by_user.bash
Created May 6, 2024 07:13
Get repo information about user-contributed PR
gh api graphql --paginate -F login="user_name" -f query='
query userInfo($login: String!) {
user(login: $login) {
name
repositoriesContributedTo(contributionTypes: [PULL_REQUEST]) {
totalCount
}
contributionsCollection(
from: "2024-01-01T15:45:00.000Z"
to: "2024-12-30T15:45:00.000Z"
@gythialy
gythialy / alacritty.toml
Created May 5, 2024 07:30
`~/.config/alacritty/alacritty.toml` alacritty 配置
import = [
# uncomment the flavour you want below:
# "~/.config/alacritty/catppuccin-latte.toml",
# "~/.config/alacritty/catppuccin-frappe.toml"
# "~/.config/alacritty/catppuccin-macchiato.toml"
"~/.config/alacritty/catppuccin-mocha.toml",
"~/.config/alacritty/keybindings.toml",
]
live_config_reload = true
@gythialy
gythialy / Dockerfile
Last active February 26, 2023 12:35
build gitbook docker image
FROM node:12.11.1-slim
RUN apt-get update && \
apt-get install -y --no-install-recommends build-essential git procps openssh-client git bzip2 graphviz calibre fonts-noto fonts-noto-cjk locales-all && \
rm -rf /var/lib/apt/lists/*
RUN npm config set unsafe-perm true && \
npm install gitbook-cli svgexport -g
WORKDIR /books
@gythialy
gythialy / redis-migrate.sh
Last active February 8, 2023 08:33
Comfort tool for migrating redis keys among instances. Supports KEYS syntax matching, authentication and TTL
#!/bin/bash
######
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
# TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
# CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
# DEALINGS IN THE SOFTWARE.
######
@gythialy
gythialy / gist:2298afc59de6cb3be2c1a4cb90e84978
Created February 2, 2023 10:53 — forked from uhfx/gist:3922268
Twitter公式/非公式クライアントのコンシューマキー

Twitter公式クライアントのコンシューマキー

Twitter for iPhone

Consumer key: IQKbtAYlXLripLGPWd0HUA
Consumer secret: GgDYlkSvaPxGxC4X8liwpUoqKwwr3lCADbz8A7ADU

Twitter for Android

Consumer key: 3nVuSoBZnx6U4vzUxf5w
Consumer secret: Bcs59EFbbsdF6Sl9Ng71smgStWEGwXXKSjYvPVt7qys

Twitter for iPad

Consumer key: CjulERsDeqhhjSme66ECg

// ==UserScript==
// @name DOUBAN Movie info for RARBG
// @namespace http://rarbg.to/
// @version 0.6.1
// @description Adds douban movie info to RARBG.to
// @author tofuliang
// @match https://rarbg.to/*
// @match http://rarbg.to/*
// @match https://rarbg.is/*
// @match http://rarbg.is/*
@gythialy
gythialy / TTGBonusSignIn.user.js
Last active January 26, 2023 14:34
TTGBonusSignIn userscirpt
// ==UserScript==
// @name TTGBonusSignIn
// @description TTGBonusSignIn
// @namespace https://github.com/gythialy
// @match http://totheglory.im/*
// @match https://totheglory.im/*
// @version 0.3
// @grant none
// ==/UserScript==
(function () {
@gythialy
gythialy / compinit.plugin.zsh
Last active September 27, 2022 12:08
compinit
#!/usr/bin/env zsh
# Load all stock functions (from $fpath files) called below.
autoload -U compaudit compinit
# Figure out the SHORT hostname
if [[ "$OSTYPE" = darwin* ]]; then
# macOS's $HOST changes with dhcp, etc. Use ComputerName if possible.
SHORT_HOST=$(scutil --get ComputerName 2>/dev/null) || SHORT_HOST=${HOST/.*/}
else
@gythialy
gythialy / docker-compose.yml
Created September 21, 2021 03:34
deploy gitlab behind proxy by docker-compose/docker-swarm
version: "3.5"
services:
gitlab:
image: gythialy/gitlab:14.0.1-ee.0
container_name: gitlab
configs:
- source: gitlab
target: /etc/gitlab/gitlab.rb
secrets:
@gythialy
gythialy / kill.sh
Created April 3, 2021 00:35
kill zombie process
kill -9 $(ps -A -ostat,ppid | grep -e '[zZ]'| awk '{ print $2 }')