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
// How to run it | |
// Requires nodejs LTS, git, python2 | |
// Open command line and move to the folder where this script is stored | |
// Edit the script and modify storage location (line 87) | |
// Check the startDate and EndDate and modify it if you need another timeframe (line 102 - 103) | |
// Stop the farmer | |
// Execute "npm install storj-lib" | |
// Execute "npm install command-line-args" | |
// Execute "node Storj_Farmer_Contracts.js --startDate=2017-06-01 --endDate=2017-06-05 --location=/home/user/.config/storjshare/shares/188071ba7cfd974a9e47b59e24b0737ebf845db3" | |
// Start the farmer |
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
# 1) Build image: | |
# docker build -t vrm:v1 . | |
# 2) Create new container (create a new container for mining in 16 threads): | |
# docker run --name vrm2_16 -d --restart=always vrm:v1 -o stratum+tcp://eu2.poolinat0r.com:7104 -u username -p password -t 16 --max-temp=70 | |
# 3) stop contatiner: | |
# docker stop vrm2_16 | |
# 4) start contatiner: | |
# docker start vrm2_16 | |
# 5) get logs: | |
# docker logs vrm2_16 |
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
package your.package; | |
import org.junit.Test; | |
import java.util.AbstractMap; | |
import java.util.Comparator; | |
import java.util.List; | |
import java.util.Map; | |
import java.util.stream.Stream; |
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
VBoxManage modifyvm "default" --natpf1 "port2222,tcp,127.0.0.1,2222,,2222" |
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
1) preapre raw dependencies | |
./dependency-list.sh ipflow-parent.pom | |
./dependency-list.sh link-core-1.3.2.pom | |
2) compile | |
javac ConfiltList.java | |
3) execute | |
java ConfiltList ipflow-parent.pom.dep.raw flink-core-1.3.2.pom.dep.raw |
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://github.com/Storj/storjshare-daemon | |
storjshare save | |
storjshare killall | |
npm install -g storjshare-daemon --unsafe-perm | |
storjshare daemon & | |
storjshare load |
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
implicit def dateTimeOrdering: Ordering[DateTime] = Ordering.fromLessThan(_ isBefore _) |
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
version: '3' | |
services: | |
mysql: | |
container_name: "mysql_db" | |
image: "mysql:latest" | |
environment: | |
MYSQL_DATABASE: "db" | |
MYSQL_USER: "dbuser" | |
MYSQL_PASSWORD: "password" | |
MYSQL_ROOT_PASSWORD: "random" |
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
1. sudo sh -c '(echo "#!/usr/bin/env sh" && curl -L https://github.com/lihaoyi/Ammonite/releases/download/2.0.4/2.13-2.0.4) > /usr/local/bin/amm && chmod +x /usr/local/bin/amm' && amm | |
2. create file: | |
val scalaLangVersion = "2.11" | |
val scalaLibVersion = "2.11.8" | |
import $ivy.`org.scala-lang:scala-compiler:2.11.8` | |
import $ivy.`org.scalaj:scalaj-time_2.11:0.8` | |
import scala.util.{Failure, Success, Try} | |
import org.joda.time._ |
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
import io.circe._ | |
import io.circe.generic.auto._ | |
import io.circe.parser._ | |
import io.circe.syntax._ | |
case class User(id: Long, name: String) | |
val user = User(1, "John Doe") | |
// {"id":1,"name":"John Doe"} |