Skip to content

Instantly share code, notes, and snippets.

module.exports = {
parser: '@typescript-eslint/parser',
"parserOptions": {
"ecmaVersion": 6,//也就是ES6语法支持的意思
"sourceType": "module",
"ecmaFeatures": {
"modules": true
},
"project": "./tsconfig.json"
},
```
sakiiily@eat-x220i [ ~ ] ! chromium
Fontconfig warning: "/etc/fonts/fonts.conf", line 5: unknown element "its:rules"
Fontconfig warning: "/etc/fonts/fonts.conf", line 6: unknown element "its:translateRule"
Fontconfig error: "/etc/fonts/fonts.conf", line 6: invalid attribute 'translate'
Fontconfig error: "/etc/fonts/fonts.conf", line 6: invalid attribute 'selector'
Fontconfig error: "/etc/fonts/fonts.conf", line 7: invalid attribute 'xmlns:its'
Fontconfig error: "/etc/fonts/fonts.conf", line 7: invalid attribute 'version'
Fontconfig warning: "/etc/fonts/fonts.conf", line 9: unknown element "description"
Fontconfig warning: "/etc/fonts/conf.d/10-hinting-slight.conf", line 4: unknown element "its:rules"
@eatradish
eatradish / gzmetro.py
Created September 27, 2017 13:44
gzmetro.py
import json
import requests
from dateutil.parser import parse
def cal_time(time, time2):
time2 = int(time2)
p_time = parse(time)
time_hour = p_time.hour
time_minute = p_time.minute
time_minute = time_minute - time2
import requests
import json
def get(kid):
comCode_url = 'https://www.kuaidi100.com/autonumber/autoComNum?text=' + kid
headers = {'Origin': "https://www.kuaidi100.com", 'Accept-Encoding': "gzip, deflate, br", 'Accept-Language': "en-US,en;q=0.8,zh-CN;q=0.6,zh;q=0.4,ja;q=0.2,zh-TW;q=0.2,uz;q=0.2,vi;q=0.2", "User-Agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/59.0.3071.115 Safari/537.36"}
c_r = requests.post(comCode_url, headers = headers)
c_r = json.loads(c_r.text)
comCode = c_r['auto'][0]['comCode']
get_url = 'https://www.kuaidi100.com/query?type=' + comCode + '&postid=' + kid + '&id=1&valicode=&temp=0.21830105590577142'
g_r = requests.post(get_url, headers = headers)
@eatradish
eatradish / snake.py
Last active September 20, 2017 06:01
snake.py
class point:
def __init__(self, x, y):
self.x = x
self.y = y
class vector:
def __init__(self, x1, y1, x2, y2):
self.x1 = x1
self.x2 = x2
self.y1 = y1

Keybase proof

I hereby claim:

  • I am eatradish on github.
  • I am eatradish (https://keybase.io/eatradish) on keybase.
  • I have a public key whose fingerprint is 22FA 037D ADE7 1C70 1CFF DF89 89CD 8498 3688 7A97

To claim this, I am signing this object: