Skip to content

Instantly share code, notes, and snippets.

View pansila's full-sized avatar

Lix Zhou pansila

View GitHub Profile
@y0ngb1n
y0ngb1n / docker-registry-mirrors.md
Last active April 18, 2024 12:27
国内的 Docker Hub 镜像加速器,由国内教育机构与各大云服务商提供的镜像加速服务 | Dockerized 实践 https://github.com/y0ngb1n/dockerized

Docker Hub 镜像加速器

国内从 Docker Hub 拉取镜像有时会遇到困难,此时可以配置镜像加速器。Docker 官方和国内很多云服务商都提供了国内加速器服务。

Dockerized 实践 https://github.com/y0ngb1n/dockerized

配置加速地址

Ubuntu 16.04+、Debian 8+、CentOS 7+

@extremecoders-re
extremecoders-re / qemu-networking.md
Last active March 31, 2024 17:19
Setting up Qemu with a tap interface

Setting up Qemu with a tap interface

There are two parts to networking within QEMU:

  • The virtual network device that is provided to the guest (e.g. a PCI network card).
  • The network backend that interacts with the emulated NIC (e.g. puts packets onto the host's network).

Example: User mode network

@Tset-Noitamotua
Tset-Noitamotua / README.md
Last active February 7, 2024 08:35
HOW-TO enable MarkDown support in RobotFramework

HOW-TO enable MarkDown support in RobotFramework

You want to execute robot test which are inside fenced code blocks of a markdown file (.md) like any normal robot test? Follow the steps below then you can run your tests as simple as robot your_test_suite.md with all robot command line execution options.

This will add support for .md files to RF

  1. Clone [RobotFramework][4] repository
  2. Save the code below as 'mdreader.py' in parsing folder of your local clone. It's based on [restreader.py][1]
  3. Add this from .mdreader import MarkDownReader [here][2] to your local clone.
@magnetikonline
magnetikonline / README.md
Last active February 4, 2024 07:45
List all Git repository objects by size.

List all Git repository objects by size

Summary

Bash script to:

  • Iterate all commits made within a Git repository.
@lukechilds
lukechilds / get_latest_release.sh
Created August 9, 2016 19:43
Shell - Get latest release from GitHub
get_latest_release() {
curl --silent "https://api.github.com/repos/$1/releases/latest" | # Get latest release from GitHub api
grep '"tag_name":' | # Get tag line
sed -E 's/.*"([^"]+)".*/\1/' # Pluck JSON value
}
# Usage
# $ get_latest_release "creationix/nvm"
# v0.31.4
@sankarara
sankarara / monitor-off.ahk
Created March 23, 2016 14:29
AutoHotKey: Turn monitor off with a keyboard shortcut
; This is part of my AutoHotkey [1] script that turns off my monitor when I
; press Win+\.
; It also turns the screensaver on at the same time, so that Windows Live
; Messenger (and any other programs) know I am away.
; I don't have a password on my screensaver, so there is a second version
; (Win+Shift+\) that locks the PC as well.
; Note: Sometimes the monitor comes back on after a second and I have to
@kevintop
kevintop / 12306AutoLogin.user.js
Created January 6, 2012 15:05
12306 Auto Login
/*
12306 Auto Login => A javascript snippet to help you auto login 12306.com.
Copyright (C) 2011 Kevintop
Includes jQuery
Copyright 2011, John Resig
Dual licensed under the MIT or GPL Version 2 licenses.
http://jquery.org/license
Includes 12306.user.js