This file contains 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
pragma solidity >=0.4.22 <0.7.0; | |
/** | |
* @title Config | |
* @dev Set and get settings | |
*/ | |
contract Config { | |
address private owner; | |
This file contains 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
... | |
action_with_slack_notification = %(banaction)s[name=%(__name__)s, port="%(port)$ | |
slack[name=%(__name__)s] | |
action = %(action_with_slack_notification)s | |
... |
This file contains 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
function transfer | |
if test (count $argv) -eq 0 | |
echo "No arguments specified. Usage:\necho transfer /tmp/test.md\ncat /tmp/test.md | transfer test.md" | |
return 1 | |
end | |
## get temporarily filename, output is written to this file show progress can be showed | |
set tmpfile ( mktemp -t transferXXX ) | |
## upload stdin or file |
This file contains 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
var Nightmare = require('nightmare'); | |
var nightmare = Nightmare({ show: true }); | |
nightmare | |
.goto('http://www.boc.cn/sourcedb/whpj') | |
.select('html body div.wrapper div.BOC_main div.publish div div#DefaultMain.main form#historysearchform div.invest_t table tbody tr td select#pjname', '2895') | |
.click('html body div.wrapper div.BOC_main div.publish div div#DefaultMain.main form#historysearchform div.invest_t table tbody tr td input.search_btn') | |
.wait(2000) | |
.evaluate(function () { | |
return document.querySelector('table:first-child tr.odd').innerText; | |
}) |
This file contains 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
簡化查詢復興航空機票價格流程 |
This file contains 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
從復興航空訂位購票網頁取出資料 |
This file contains 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
function createPost() { | |
var userId = 'me'; | |
var msg = '使用 Google Apps Script 發消息+圖片'; | |
var img = 'https://developers.google.com/apps-script/images/carousel0.png'; | |
var blob = UrlFetchApp.fetch(img).getBlob().setContentTypeFromExtension(); | |
var media = PlusDomains.newMedia(); | |
var result = PlusDomains.Media.insert(media, userId, 'cloud', blob); |
This file contains 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
// Transparent 1x1 PNG: | |
header('Content-Type: image/png'); | |
echo base64_decode('iVBORw0KGgoAAAANSUhEUgAAAAEAAAABAQMAAAAl21bKAAAAA1BMVEUAAACnej3aAAAAAXRSTlMAQObYZgAAAApJREFUCNdjYAAAAAIAAeIhvDMAAAAASUVORK5CYII='); | |
// Transparent 1x1 GIF: | |
header('Content-Type: image/gif'); | |
echo base64_decode('R0lGODlhAQABAJAAAP8AAAAAACH5BAUQAAAALAAAAAABAAEAAAICBAEAOw=='); |
This file contains 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 type="text/javascript"> | |
<!-- | |
(function($){ | |
var pixform = {}; | |
pixform.confirm_popup = false; | |
// 偵測是瀏覽器是否支援 input 的 placeholder 屬性 | |
var tmp = document.createElement('input'); | |
pixform.usePlaceholder = false; |
This file contains 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 id="tmpl-timeline" type="text/x-jquery-tmpl"> | |
<div class="timeline-day"> | |
<div class="timeline-day-date {{= classToday}}"> | |
<div class="timeline-day-vbar"></div> | |
<div class="timeline-day-date-numbers"> | |
<strong>{{= sDate.substr(0,4)}}<br> | |
<strong class="datelarge">{{= sDate.substr(5,5)}}</strong></strong> | |
</div> | |
</div> | |
<div class="timeline-day-thumbs"> |
NewerOlder