Skip to content

Instantly share code, notes, and snippets.

Artem Tartakynov tartakynov

Block or report user

Report or block tartakynov

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
tartakynov / WebVersion.scala
Created Oct 18, 2018
Return version in Play application
View WebVersion.scala
import scala.sys.process
import scala.util.Try
import com.typesafe.sbt.web.Import._
import play.sbt.PlayScala
import sbt._
import sbt.Keys._
* Adds /version.txt into Play static assets
tartakynov / Experiment.scala
Last active Jan 23, 2018
Assign to A/B test
View Experiment.scala
import{Hashing, HashFunction};
* Deterministic algorithm for assigning given variables to variants A or B with given probability.
* @param id The experiment's identifier
* @param pA Probability of A (probability of B is 'pB = 1.0 - pA').
class Experiment(val id: String, pA: Float) {
tartakynov /
Created Nov 10, 2017 — forked from kevin-smets/
iTerm2 + Oh My Zsh + Solarized color scheme + Meslo powerline font + [Powerlevel9k] - (macOS)






Keybase proof

I hereby claim:

  • I am tartakynov on github.
  • I am tartakynov ( on keybase.
  • I have a public key whose fingerprint is 1079 61BB B910 0861 2890 3530 CDED D434 0B39 5C9B

To claim this, I am signing this object:

tartakynov / nolock.vbs
Last active Jan 9, 2017
Prevent Windows lock
View nolock.vbs
' put this script in Start / All Programs / Startup
Dim objResult
Set objShell = WScript.CreateObject("WScript.Shell")
i = 0
Do While i = 0
objResult = objShell.sendkeys("{NUMLOCK}{NUMLOCK}")
Wscript.Sleep (6000)
import hexdump
import base64
m = "aGVsbG8gd29ybGQ="
decodedb64 = base64.b64decode(m)
View gist:b670a6b4ad50dcfe04ffb53074b4c2d4
docker run --name mysql -d -p 3306:3306 -e MYSQL_ROOT_PASSWORD=root mysql/mysql-server:latest
docker run --name myadmin -d -p 8888:80 --link mysql:db phpmyadmin/phpmyadmin
docker run --name rabbitmq -d -p 4369:4369 -p 5671:5671 -p 5672:5672 -p 15671:15671 -p 15672:15672 -p 25672:25672 rabbitmq:3-management
tartakynov /
Last active Dec 5, 2016
MySQL Docker
docker run --name mysql -e MYSQL_ROOT_PASSWORD=root -p 3306:3306 -d mysql:latest
docker run --name myadmin -d --link mysql:db -p 8888:80 phpmyadmin/phpmyadmin
tartakynov / build.sbt
Created Sep 5, 2016
Add public asset with app version (Play Framework)
View build.sbt
resourceGenerators in Compile <+= (WebKeys.public in Assets, version).map {
case (dir, v) =>
val file = dir / "version.txt"
val gitCommit = Process("git rev-parse HEAD").lines.head
val content = "version=%s git-commit=%s".format(v, gitCommit)
IO.write(file, content)
View scalastyle-config.xml
If you wish to turn off checking for a section of code, you can put a comment in the source
before and after the section, with the following syntax:
// scalastyle:off
... // stuff that breaks the styles
// scalastyle:on
You can also disable only one rule, by specifying its rule id, as specified in:
You can’t perform that action at this time.