Skip to content

Instantly share code, notes, and snippets.

View dongfg's full-sized avatar
🎯
Focusing

dongfg dongfg

🎯
Focusing
View GitHub Profile
@dongfg
dongfg / main.go
Created November 7, 2019 06:56
淘宝自动删除订单
package main
import (
"fmt"
"github.com/go-vgo/robotgo"
"strings"
"time"
)
func main() {
@dongfg
dongfg / script.js
Created July 23, 2019 01:53
iconfont 批量添加购物车
// 在图标集合页面控制台执行,eg. https://www.iconfont.cn/collections/detail?cid=15699
var event = new MouseEvent('click', {
'view': window,
'bubbles': true,
'cancelable': true
});
var list = $("#magix_vf_main > div.wrap > div.page-collection-detail-wrap > div.collection-detail > ul").children;
[].forEach.call(list, function(el) {
el.children[2].children[0].dispatchEvent(event);
});
@dongfg
dongfg / build.sh
Created January 18, 2019 05:48
delete blank lines of hexo generate html
# execute after hexo g;
# if you are use macos, use gsed instead sed(brew install gnu-sed);
find public -type f -name *.html -exec sed -i '/^[[:space:]]*$/d' {} +
@dongfg
dongfg / xxf-v.zsh-theme
Last active June 27, 2025 01:25
zsh xxf custom theme
# Copy and self modified from xxf
# Machine name.
function box_name {
[ -f ~/.box-name ] && cat ~/.box-name || echo $HOST
}
function exists {
command -v $1 >/dev/null 2>&1
}
@dongfg
dongfg / Jenkinsfile
Created July 3, 2017 05:38
jenkins pipeline send message to DingTalk
node {
try {
stage('common build stage'){
echo 'build ...'
}
currentBuild.result = "SUCCESS"
} catch(e) {
currentBuild.result = "FAIL"
}
@dongfg
dongfg / settings-huaweicloud.xml
Last active October 10, 2025 22:15
maven mirror setting
<?xml version="1.0" encoding="UTF-8"?>
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd">
<!-- DO NOT USE relative path with maven wrapper -->
<!-- <localRepository>/opt/devtools/maven/repo</localRepository> -->
<mirrors>
<mirror>
<id>maven-huaweicloud-mirror</id>
<name>maven-huaweicloud-mirror</name>