distraction mode
fullscreen mode
autoscroll from/to source
termial settings -> don't override shortcuts
presentation asist
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
| open () | |
| { | |
| # The first argument to start needs to be empty to avoid issues when paths have spaces | |
| cmd.exe /C start "" "$(wslpath -w "$1")" | |
| } |
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
| package main | |
| import ( | |
| "fmt" | |
| "net" | |
| "time" | |
| "bufio" | |
| ) | |
| func handleConnection(conn net.Conn) { |
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
| import java.io.{File, FileInputStream} | |
| import java.util | |
| import monix.execution.Cancelable | |
| import monix.reactive.Observable | |
| import scala.util.control.NonFatal | |
| def fromInputStream(in: java.io.InputStream, chunkSize: Int = 256): Observable[Array[Byte]] = { | |
| val iterator = new Iterator[Array[Byte]] { | |
| private[this] val buffer = new Array[Byte](chunkSize) | |
| private[this] var lastCount = 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
| import akka.actor.ActorSystem | |
| import akka.stream._ | |
| import akka.stream.scaladsl.{Flow, GraphDSL, Keep, RunnableGraph, Sink, Source} | |
| import akka.stream.stage.{GraphStage, GraphStageLogic, InHandler, OutHandler} | |
| import akka.testkit.TestKit | |
| import org.scalatest.{BeforeAndAfterAll, Matchers, WordSpecLike} | |
| import scala.concurrent.Await | |
| class CombineLatest[A, B] |
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
| version: 2 | |
| jobs: | |
| build: | |
| working_directory: ~/app-name | |
| docker: | |
| - image: circleci/node:6-browsers | |
| steps: | |
| - checkout | |
| - restore_cache: | |
| key: dependency-cache-{{ checksum "yarn.lock" }} |
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
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <meta name="description" content="Creating Reusable Social Share Buttons" /> | |
| <script src="http://code.jquery.com/jquery.js"></script> | |
| <script src="http://cdnjs.cloudflare.com/ajax/libs/handlebars.js/1.0.0/handlebars.js"></script> | |
| <script src="http://builds.emberjs.com/ember-latest.js"></script> | |
| <meta charset=utf-8 /> | |
| <title>JS Bin</title> | |
| </head> |
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
| /* Ismael Celis 2010 | |
| Simplified WebSocket events dispatcher (no channels, no users) | |
| var socket = new FancyWebSocket(); | |
| // bind to server events | |
| socket.bind('some_event', function(data){ | |
| alert(data.name + ' says: ' + data.message) | |
| }); |
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
| function is_valid_email($email) | |
| { | |
| if(preg_match("/[a-zA-Z0-9_-.+]+@[a-zA-Z0-9-]+.[a-zA-Z]+/", $email) > 0) | |
| return true; | |
| else | |
| return false; | |
| } |
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
| function Person() { | |
| this.name = jeff; | |
| this.age = 27; | |
| } | |
| new Person(); | |