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
/system/device-mode/update container=yes | |
/interface veth add address=172.17.0.1/24 gateway=172.17.0.254 name=agh | |
/interface bridge add name=dockers | |
/interface bridge port add bridge=dockers interface=agh | |
/ip address add address=172.17.0.254/24 interface=dockers network=172.17.0.0 | |
/ip firewall nat add action=masquerade chain=srcnat | |
/container config set registry-url=https://registry-1.docker.io tmpdir=/disk1/tmp |
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
{ | |
"servers": [ | |
{ | |
"name": "s1", | |
"address": "https://anisette-v3-server-e1ug.onrender.com" | |
}, | |
{ | |
"name": "s2", | |
"address": "http://103.237.28.56:6969" | |
} |
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
# from http://endot.org/2011/12/06/my-tmux-configuration/ | |
# keybindings to make resizing easier | |
bind -r C-h resize-pane -L | |
bind -r C-j resize-pane -D | |
bind -r C-k resize-pane -U | |
bind -r C-l resize-pane -R | |
# VI keybindings | |
setw -g mode-keys vi |
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 <iostream> | |
#include <cstdio> | |
#include <map> | |
#include <vector> | |
#include <algorithm> | |
using namespace std; | |
const int maxn = 10000 + 5; | |
int a[maxn]; | |
map<int, int> idx_array; |
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
<?php | |
// author: moonsn | |
// desc: 发现个 iu 妹纸的图站,果断全站拔下来。。。 | |
echo "iustudio images saver\n"; | |
for($i = 1; $i < 35; $i++) { | |
$list_url = "http://iustudio.tistory.com/category/?page=$i"; | |
echo "get_list: $list_url\n"; |
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 <iostream> | |
using namespace std; | |
int partition(int *a, int l, int r){ | |
int i = l,j = r; | |
int p = a[r]; | |
while(1) { | |
while(a[i] < p) i++; |
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
struct User; | |
struct relationship { | |
User *user1, *user2; | |
unsigned int type; // 微信 1;QQ 2;帮派 4;游戏好友 8 | |
}; | |
using relationship_user = pair<User*, unsigned int>; | |
int calculate_relationship_value(const relationship_user& r) { |