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
(sudo) tar -xvzf filename |
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
// using the callback | |
myContract.methods.myMethod(123).send({from: '0xde0B295669a9FD93d5F28D9Ec85E40f4cb697BAe'}, function(error, transactionHash){ | |
... | |
}); | |
// using the promise | |
myContract.methods.myMethod(123).send({from: '0xde0B295669a9FD93d5F28D9Ec85E40f4cb697BAe'}) | |
.then(function(receipt){ | |
// receipt can also be a new contract instance, when coming from a "contract.deploy({...}).send()" | |
}); |
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
jQuery(document).ready(function(){ | |
var screenWidth = jQuery(window).width(); | |
var videoWidth; | |
if (screenWidth < 770) { | |
if (screenWidth % 2 != 0) { | |
videoWidth = screenWidth - 1; | |
} else { | |
videoWidth = screenWidth; | |
} | |
videoHeight = videoWidth / 16 * 9; |
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
// RespGen :: Concurrent HTTP GET Response generator | |
func RespGen(urls ...string) <-chan *http.Response { | |
var wg sync.WaitGroup | |
out := make(chan *http.Response) | |
wg.Add(len(urls)) | |
for _, url := range urls { | |
go func(url string) { | |
req, err := http.NewRequest("GET", url, nil) | |
if err != nil { | |
panic(err) |
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
npm install -D sass-loader node-sass |
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
https://ethereum.stackexchange.com/questions/305/what-are-common-pitfalls-or-limitations-when-coding-in-solidity |
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
rustup override add nightly |
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
docker logs containername >& logs/myFile.log |
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
let cells = document.getElementsByClassName("delegate-item"); | |
let returnDelegates = []; | |
for (let i in cells) { | |
let inner_lis = cells[i].getElementsByTagName("li"); | |
for (let x in inner_lis) { | |
let inner = inner_lis.innerHTML.trim(); | |
if (inner.indexOf("Is public delegate?") > -1) { | |
let i_tag = inner_lis[x].getElementsByTagName("i"); | |
if (i_tag.classList.contains("text-green")) { | |
returnDelegates.push(cells[i]); |
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
query user($uuid: uuid) { | |
user(where: { uuid: { _eq: $uuid } }) { | |
user2holding: Users_to_Holdings { | |
holding_address | |
id | |
holdings: Holding { | |
token_name | |
token: Token { | |
symbol | |
marketData: Market_Data(limit: 1, order_by: { created_at: desc }) { |
OlderNewer