Skip to content

Instantly share code, notes, and snippets.

@evianzhow
evianzhow / WebTerminal.md
Last active February 7, 2023 15:20
MetaTrader Web Terminal 启动参数

Original URL Sample:

https://trade.mql5.com/trade?servers=PTAus-Demo,PTAus-Live%201&trade_server=PTAus-Live%201&demo_server=PTAus-Demo&demo_type=forex,forex-usd&demo_leverage=1,33,100,300,500&startup_mode=open_demo&lang=zh&save_password=off

Decoded:

https://trade.mql5.com/trade?servers=PTAus-Demo,PTAus-Live 1&trade_server=PTAus-Live 1&demo_server=PTAus-Demo&demo_type=forex,forex-usd&demo_leverage=1,33,100,300,500&startup_mode=open_demo&lang=zh&save_password=off
@evianzhow
evianzhow / README.md
Last active April 25, 2017 02:34
iPod battery percentage enabler
default 16:24:50.953454 +0800 Home activate generator <_UIFeedbackStatesBehavior: 0x17413c3e0: prepared=1> with style: Prewarm; activationCount: 1 -> 0; styleActivationCount: 1 -> 0
default 16:24:50.954154 +0800 Home feedback engine <_UIFeedbackHapticEngine: 0x1742c8340: state=0, numberOfClients=0, prewarmCount=1, _isSuspended=0> state changed: Inactive -> Prewarming
default 16:24:50.956076 +0800 Home 384: clientID: 0x1000194
default 16:24:50.993726 +0800 mediaserverd 317: Calling startPrewarm on synth
default 16:24:51.000852 +0800 mediaserverd 678: Client request to start IO proc ID 0x0 on VAD 173.
default 16:24:51.013337 +0800 mediaserverd 560: Starting IO type 1 on AggregateDevice 146.
default 16:24:51.015553 +0800 mediaserverd HALS_IOContext.cpp:766:StartIOProcID: HALS_IOContext::StartIOProcID: 150 Speaker (VAD [vdef] AggDev 1):
default 16:24:51.016062 +0800 mediaserverd HALS_IOContext.cpp:772:StartIOProcID: starting ProcID 0x0 state: Prewarm: 0 Play: 0 State: Stopped IOProc 0x21: no
default 16:24:5
default 15:58:44.577574 +0800 Home subsystem: com.apple.avfaudio, category: avas, enable_level: 0, persist_level: 0, default_ttl: 0, info_ttl: 0, debug_ttl: 0, generate_symptoms: 0, enable_oversize: 0, privacy_setting: 2, enable_private_data: 0
default 15:58:44.614805 +0800 Home subsystem: com.apple.coreaudio, category: as, enable_level: 0, persist_level: 0, default_ttl: 0, info_ttl: 0, debug_ttl: 0, generate_symptoms: 0, enable_oversize: 0, privacy_setting: 2, enable_private_data: 0
default 15:58:44.623043 +0800 mediaserverd 3817: created session sid:0x1e63f, Home(404), 'prim' for PID: 404 and port: 181107
default 15:58:44.637573 +0800 Home subsystem: com.apple.UIKit, category: FeedbackActivation, enable_level: 0, persist_level: 0, default_ttl: 0, info_ttl: 0, debug_ttl: 0, generate_symptoms: 0, enable_oversize: 1, privacy_setting: 2, enable_private_data: 0
default 15:58:44.640189 +0800 Home activate generator <_UIFeedbackStatesBehavior: 0x17413c3e0: prepared=1> with style: Prewarm; activationCount: 1 -> 0;
#!/usr/bin/env ruby
# This script only support ASCII format
# and tick download.
require 'uri'
require 'net/http'
require 'mechanize'
agent = Mechanize.new
@evianzhow
evianzhow / shadowsocks-server
Last active April 27, 2019 14:21
shadowsocks-server OpenWRT init.d script
#!/bin/sh /etc/rc.common
#
# Copyright (C) 2016 Jian Chang <aa65535@live.com>
# Copyright (C) 2016 Evian Zhow <evianzhow@gmail.com>
#
# This is free software, licensed under the GNU General Public License v3.
# See /LICENSE for more information.
#
START=90
@evianzhow
evianzhow / remove_deploy_keys.rb
Created November 15, 2016 05:57
Remove all GitLab deploy keys like a boss
require 'net/http'
require 'json'
HOST = 'enter_your_own_domain_here'
def login username, password
uri = URI("http://#{HOST}/api/v3/session?login=#{username}&password=#{password}")
# Create client
http = Net::HTTP.new(uri.host, uri.port)
# Create Request
tell application "System Events"
repeat while exists (processes where name is "SecurityAgent")
tell process "SecurityAgent"
set value of text field 1 of window 1 to "password"
click button "OK" of window 1
end tell
delay 0.2
end repeat
end tell
#!/usr/local/env ruby
require 'open-uri'
require 'uri'
require 'csv'
files = open('pw.txt').read
csv = []
@evianzhow
evianzhow / Vagrantfile
Created August 5, 2016 13:52
Cross-compile Vagrant box for EdgeRouter
Vagrant.configure(2) do |config|
config.vm.box = "ubuntu/trusty64"
config.vm.provider "virtualbox" do |vb|
vb.memory = "1024"
end
config.vm.provision "shell", inline: <<-SHELL