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
| call plug#begin() | |
| Plug 'preservim/nerdtree' | |
| Plug 'vim-airline/vim-airline' | |
| Plug 'vim-airline/vim-airline-themes' | |
| Plug 'ajmwagar/vim-deus' | |
| Plug 'projekt0n/github-nvim-theme' | |
| Plug 'puremourning/vimspector' | |
| Plug 'tpope/vim-fugitive' | |
| Plug 'godlygeek/tabular' | |
| Plug 'airblade/vim-gitgutter' |
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
| #include <iostream> | |
| #include <map> | |
| #include <list> | |
| #include <stack> | |
| #include <algorithm> | |
| #include <vector> | |
| #include <future> | |
| #include <sstream> | |
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
| object generic { | |
| sealed trait Schema[A] { | |
| def from(c: Config, p: String): ValidatedConfig[A] | |
| } | |
| object Schema { | |
| def of[A](implicit s: Schema[A]): Schema[A] = s |
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
| trait UpdateRepr[T, R <: HList] { | |
| def apply(t: T, r: R): T | |
| } | |
| object UpdateRepr { | |
| import ops.record._ | |
| implicit def mergeUpdateRepr[T <: HList, R <: HList] | |
| (implicit merger: Merger.Aux[T, R, T]): UpdateRepr[T, R] = | |
| new UpdateRepr[T, R] { |
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 shapeless._ // requires.shapeless | |
| import cats._, implicits._, data.Kleisli // requires.cats | |
| import cats.sequence._ //requires kittens | |
| import cats.effect.IO //requires cats-effect | |
| // ofc, uses "-Ypartial-unification" and kind-projector | |
| case class Result() // replace with the JDBC equivalent | |
| case class DB(val r: Result) { | |
| def nextInt: IO[Int] = ??? //IO(g.nextInt) |
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
| /** Trivial example of a Zipper, using lists. */ | |
| type ListZipper[A] = (List[A],List[A]) | |
| def fst[A](t: (A,A)) = t._1 | |
| def snd[A](t: (A,A)) = t._2 | |
| def forward[A](z: ListZipper[A]) = (fst(z).tail, fst(z).head :: snd(z)) | |
| def backward[A](z: ListZipper[A]) = (snd(z).head :: fst(z), snd(z).tail) |
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
| #!/bin/bash | |
| # install.sh | |
| # install.sh with no arguments will install OpsCenter. | |
| # install.sh --with-dse to install DSE | |
| # n.b. | |
| # For running DSE in the cloud we usually install OpsCenter | |
| # on one node, then use OpsCenter to install on the other EC2 | |
| # nodes. | |
| # |
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
| # | |
| # Apache Reverse Proxy settings for Zeppelin server. | |
| # note: | |
| # Change ZEPPELING_IP_OR_HOST and ZEPPELIN_PORT as appropriate. | |
| # | |
| # FreeBSD put into /usr/local/etc/apache24/Includes directory, | |
| # Linux may vary. | |
| # This is for your-host.your-domain.com/zeppelin | |
| # if you want zeppelin.your-host.your-domain.com |