This file has been truncated, but you can view the full file.
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
mixed-port: 7890 | |
socks-port: 7891 | |
allow-lan: true | |
bind-address: "*" | |
ipv6: true | |
log-level: info | |
external-controller: 127.0.0.1:9090 | |
experimental: | |
ignore-resolve-fail: true | |
cfw-latency-timeout: 3000 |
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
module Document = { | |
type t; | |
type element; | |
type window; | |
let window: window = [%bs.raw "window"]; | |
let document: t = [%bs.raw "document"]; | |
/* external setGlDebug : window => GlT.context => unit = "debugContext" [@@bs.set]; */ | |
[@bs.val] | |
external getElementById : string => Js.nullable(element) = | |
"document.getElementById"; |
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 kategory.* | |
import org.junit.Test | |
import kotlin.test.assertEquals | |
sealed class Logo<out A> : HK<Logo.F, A> { | |
sealed class F private constructor() | |
data class MoveForward(val position: Position, val times: Int) : Logo<Position>() | |
data class TurnRight(val position: Position) : Logo<Position>() |
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 java.nio.ByteBuffer | |
import com.amazonaws.regions.Regions | |
import com.amazonaws.services.kms.AWSKMS | |
import com.amazonaws.services.kms.AWSKMSClientBuilder | |
import com.amazonaws.services.kms.model.{DecryptRequest, EncryptRequest} | |
object Encrypty extends App { | |
val kms: AWSKMS = AWSKMSClientBuilder.standard.withRegion(Regions.EU_WEST_2).build() |
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
name := "interest-calc" | |
version := "1.0" | |
scalaVersion := "2.11.8" | |
libraryDependencies += "org.scalatest" %% "scalatest" % "3.0.0" % "test" | |
libraryDependencies += "org.scalacheck" %% "scalacheck" % "1.13.4" % "test" |
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
# Simple SonarQube database and user creation for Postgresql | |
# | |
sudo -u postgres psql postgres | |
CREATE DATABASE sonar; | |
CREATE USER sonar WITH PASSWORD 'verysecret'; | |
GRANT ALL PRIVILEGES ON DATABASE sonar TO sonar; |
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
travis encrypt <heroku_api_key> -r <account>/<repository> --add |
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
language: ruby | |
rvm: | |
- 2.2.3 | |
before_script: | |
- psql -c 'create database <application_name>_test;' -U postgres | |
test: | |
adapter: postgresql | |
database: <application_name>_test | |
username: postgres |
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
int main(int argc, char *argv[]) { | |
int retVal = -1; | |
@autoreleasepool { | |
@try { | |
retVal = UIApplicationMain(argc, argv, nil, nil); | |
} | |
@catch (NSException* exception) { | |
NSLog(@"Uncaught exception: %@", exception.description); | |
NSLog(@"Stack trace: %@", [exception callStackSymbols]); |
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 Foundation | |
import CoreData | |
func setUpInMemoryManagedObjectContext() -> NSManagedObjectContext { | |
let managedObjectModel = NSManagedObjectModel.mergedModelFromBundles([NSBundle.mainBundle()])! | |
let persistentStoreCoordinator = NSPersistentStoreCoordinator(managedObjectModel: managedObjectModel) | |
do { | |
try persistentStoreCoordinator.addPersistentStoreWithType(NSInMemoryStoreType, configuration: nil, URL: nil, options: nil) | |
} catch { |