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
| require 'nokogiri' | |
| require 'open-uri' | |
| doc = Nokogiri::HTML(open('http://www.amazon.com/s/ref=nb_sb_noss?url=search-alias%253daps&field-keywords=women+dress')) | |
| doc.css('.a-fixed-left-grid-col.a-col-right').each do |c| | |
| a=c.css('.s-access-detail-page') | |
| p [a.text, a.attr('href').value, c.css('.s-price').text] | |
| end |
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
| <style type="text/css"> | |
| #allmap {width: 100%;height: 100%;overflow: hidden;margin:0;} | |
| </style> | |
| <div id="allmap"></div> | |
| <script type="text/javascript" src="http://api.map.baidu.com/api?v=2.0&ak=myTuIQ3Uc0cfVMp8Mhocf5MW"></script> | |
| <script type="text/javascript"> | |
| var map = new BMap.Map("allmap"); | |
| var point = new BMap.Point(116.404, 39.915); | |
| map.centerAndZoom(point, 15); |
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
| seeds = Seed.search(user_name_eq: 'ivy', created_at_gt: 1.month.ago.at_beginning_of_month, created_at_lt: 1.month.ago.at_end_of_month).result | |
| sub = "www.vsat-antenna.com www.tvroantenna.com www.rxonlyantenna.com www.vsatantenna.net www.flyawayantenna.info www.rxantenna.com".split( ) | |
| seeds.map{|s| s.site}.select{|s| !s.name.in?(sub) }.map{|s|s.pr}.inject(&:+) | |
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
| <script src="http://cdn.bootcss.com/vue/2.0.0-rc.7/vue.min.js"></script> | |
| <div id="app"> | |
| <div class="form-horizontal"> | |
| <div class="form-group hidden-xs"> | |
| <div class="col-sm-2"> </div> | |
| <div class="col-sm-3">含量</div> | |
| <div class="col-sm-3">重量</div> | |
| </div> |
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
| exports.lmsServer = 'http://{{ lms_server }}'; | |
| exports.redis = { | |
| host: '{{redis_host}}', | |
| port: {{redis_port}}, | |
| database: {{ redis_db|default(0) }}, | |
| sentinels: '{{ redis_sentinels }}', | |
| name: '{{ redis_sentinel_name }}', | |
| redis_sentinel_enabled: {{ redis_sentinel_enabled | default(0) }}, |
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
| @cache.memoize(3600) | |
| def _auth_access_token(org_code=None): | |
| api_key = current_app.config['DASHBOARD_TC_API_KEY'] | |
| res = post_dashboard( | |
| url='/v1/auth/access_token', | |
| params={"orgCode": org_code, "appKey": api_key}, | |
| need_token=False | |
| ) | |
| return res.json() |
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
| { | |
| "result": [{ | |
| "createdAt": "2020-06-05T03:24:18.629Z", | |
| "apiUrl": "http://192.168.11.162:5000", | |
| "ntfUrl": "http://192.168.11.162:8080", | |
| "area": "cn", | |
| "env": "prod", | |
| "id": "8", | |
| "isPublic": true, | |
| "objectId": "5ed9bae2c141340006612ed6", |
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
| port: 7890 | |
| # Port of SOCKS5 proxy server on the local end | |
| socks-port: 7891 | |
| # Transparent proxy server port for Linux and macOS (Redirect TCP and TProxy UDP) | |
| # redir-port: 7892 | |
| # Transparent proxy server port for Linux (TProxy TCP and TProxy UDP) | |
| # tproxy-port: 7893 |
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 | |
| usage() { | |
| echo "Usage:" | |
| echo " adbx proxy set" | |
| echo " adbx proxy get" | |
| echo " adbx proxy remove" | |
| } | |
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 | |
| COMMIT_MSG=$(git log -1 --pretty=%s) | |
| VERSION=$(python lms/version.py) | |
| function record_version { | |
| if [[ -z "$HIPA_TOKEN" ]]; then | |
| echo "Must provide HIPA_TOKEN in environment" 1>&2 | |
| else | |
| curl -X POST 'https://api.hipacloud.com/v1/apps/609e18e9bdd6c63429bb80d2/tables/609e18e9bdd6c63429bb80d3/records' \ |