This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sudo zypper addrepo https://download.opensuse.org/repositories/home:lbssousa:numix/openSUSE_Leap_15.0/home:lbssousa:numix.repo | |
| sudo zypper in autoconf automake sassc pkg-config gtk3-devel gnome-themes-standard gtk2-engine-murrine numix-icon-theme | |
| git clone https://github.com/andreisergiu98/arc-flatabulous-theme --depth 1 && cd arc-flatabulous-theme | |
| ./autogen.sh --prefix=/usr | |
| sudo make install |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| set -eu | |
| # account config | |
| AUTH_EMAIL="your-email@domain.tld" | |
| AUTH_KEY="xxxxxxxxxxxxxxxxxxxxxxxxx" | |
| ZONE_IDENTIFIER="yyyyyyyyyyyyyyyyyyyyyyyyyy" | |
| RECORD_IDENTIFIER="zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz" | |
| # record config |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Linux version 2.6.14-hsc0ds (stsp@len) (gcc version 4.0.4) #5 Mon Feb 27 17:02:50 CET 2012 | |
| CPU: ARM946E [41009460] revision 0 (ARMvundefined/unknown) | |
| Machine: Nintendo DS | |
| Memory management: Non-Paged(unused/noMMU) | |
| Ignoring unrecognised tag 0x00000000 | |
| On node 0 totalpages: 9216 | |
| DMA zone: 9216 pages, LIFO batch:3 | |
| Normal zone: 0 pages, LIFO batch:1 | |
| HighMem zone: 0 pages, LIFO batch:1 | |
| CPU0: D VIVT write-back cache |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // High-accuracy square wave generator | |
| // based on ESP8266 | |
| // with runtime adjustable frequency, PWM width and offset | |
| // Output wave at pin 5 (configurable from 0 to 15, but not 16) | |
| // by James Swineson <github@public.swineson.me>, 2017-10 | |
| // https://gist.github.com/Jamesits/92394675c0fe786467b26f90e95d3904 | |
| // See https://blog.swineson.me/implementation-of-6mbps-high-speed-io-on-esp8266-arduino-ide/ | |
| // for more information (article in Chinese) | |
| // Arduino UNO version: https://gist.github.com/Jamesits/8d164818946a65d0cafcd6203e3e5049 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <windows.h> | |
| #include <string> | |
| using namespace std::string_literals; | |
| constexpr size_t buffer_size = 64*1024; | |
| static char buffer[buffer_size]; | |
| static DWORD PrintString(HANDLE h_stdout, std::wstring const& string) { | |
| DWORD count; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| # USE WITH CAUTION | |
| # remove all exited containers | |
| docker rm $(docker ps -a -f status=exited -f status=created -q) | |
| # remove dangling volumes | |
| docker volume rm $(docker volume ls -f dangling=true -q) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| set -eu | |
| SYSCTL_FILE=/etc/sysctl.d/90-tcp-bbr.conf | |
| # check root | |
| if [[ $EUID -ne 0 ]]; then | |
| echo "This script must be run as root" | |
| exit 1 | |
| fi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ; Please see https://gist.github.com/Jamesits/6a58a1b08d5cd09a94a02f30ddaf0e13#gistcomment-2081294 | |
| ; for instruction. | |
| ; Author: James Swineson <mactype@public.swineson.me> | |
| [General] | |
| Name=James Profile | |
| ; 【启用 DirectWrite 支持】 | |
| ; [0:Disable] 1:Enable | |
| DirectWrite=1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| import sys | |
| from PIL import Image | |
| # 载入图像 | |
| im = Image.open(sys.argv[1]) | |
| im.show() | |
| def makeGrayscale(im: 'Image.Image') -> 'Image.Image': | |
| '''Reads a Pillow image and convert it to grayscale using brightness''' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # https://gist.github.com/Jamesits/944ab9a484ad34522f6c4bce8d085132 | |
| # Captures every IP-CIDR notation in HTML file | |
| # then convert it to RouterOS IP List format | |
| # Usage: convert.sh source-file.html List-Name | |
| # Then use /import file-name=List-Name.scr to | |
| # import this list on RouterOS | |
| # You can save bgp.he.net search result as HTML | |
| # then use this script to convert. |