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
<?php | |
function do_not_change_this_function() { | |
echo "Something is happening\n"; | |
echo "this is important data\n"; | |
ob_flush(); |
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
#!/usr/bin/env bash | |
tr=trigger | |
tr='==============_AUTOGENERATED_-_EDITS_BELOW_WILL_BE_CLOBBERED' | |
[ ! -f test.conf ] && cat <<EOF >test.conf | |
this | |
is a | |
trigger | |
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
#!/usr/bin/env bash | |
tr=trigger | |
tr='==============_AUTOGENERATED_-_EDITS_BELOW_WILL_BE_CLOBBERED' | |
[ ! -f test ] && cat <<EOF >test | |
this | |
is a | |
trigger | |
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
version: '2' | |
services: | |
db: | |
image: postgres:9.6 | |
command: postgres -c 'max_connections=300' -c 'shared_buffers=4GB' -c 'work_mem=16MB' -c 'maintenance_work_mem=1GB' -c 'bgwriter_lru_maxpages=200' -c 'commit_delay=10' -c 'checkpoint_timeout=30min' -c 'checkpoint_warning=30min' -c 'log_timezone=Canada/Mountain' -c 'timezone=Canada/Mountain' | |
volumes: | |
- ${PWD}/docker/db/initdb.sh:/docker-entrypoint-initdb.d/initdb.sh | |
ports: | |
- "5432:5432" |
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
PB.targets in Compile := Seq( | |
scalapb.gen() -> (sourceManaged in Compile).value | |
) | |
lazy val generateEventSerializer = TaskKey[Seq[File]]("generateEventSerializer", "Write code for me.") | |
generateEventSerializer := { | |
import sys.process._ | |
"./make-proto-serializer.sh".! |
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.time.{Duration, ZonedDateTime} | |
object BruteFast extends App { | |
val startTime = ZonedDateTime.now | |
val theCorrectPassword = "ordaindrooppodlovelyemberlogic" | |
// val theCorrectPassword = "horsebutt" | |
// val dictionary = scala.io.Source.fromFile("/usr/share/dict/words").getLines.toVector | |
val dictionary = Vector("ordain","droop","pod","lovely","ember","logic") |
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
<div class="modal show fade in" role="alert" style="z-index: 2420 !important;"> | |
<div class="modal-backdrop show fade in" style="z-index: 2400 !important;"></div> | |
<div class="modal-dialog modal-md" style="z-index: 2500 !important;"> | |
<div class="modal-content"> | |
<div class="modal-header"> | |
<h2>Confirm {{ actionName }} of {{ itemName }}</h2> | |
</div> | |
<div class="modal-body"> | |
<p>Are you sure you want to {{ actionVerb }} this {{ entityName }}?</p> | |
<p>{{ itemName }}</p> |
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 {Injectable, Inject} from "@angular/core"; | |
import {Http} from "@angular/http"; | |
import {Observable, BehaviorSubject} from "rxjs"; | |
@Injectable() | |
export class ThisDataService { | |
private thisData: BehaviorSubject<any[]> = new BehaviorSubject([]); | |
public thisDataObs$: Observable<any[]> = this.thisData.asObservable(); |
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 domain.slick | |
import domain.model.{Area, Client, Id} | |
import slick.collection.heterogeneous.HNil | |
import slick.collection.heterogeneous.syntax._ | |
import slick.driver.PostgresDriver.api._ | |
import slick.lifted.{ProvenShape, Query, TableQuery, Tag} | |
class Areas(tag: Tag) extends Table[Area](tag, "areas") { |
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
case class Book(title: String, category: String, rating: Int) | |
val t = List( | |
Book("The dark", "Mystery", 90), | |
Book("What is", "Romance", 55), | |
Book("This is what", "Mystery", 80), | |
Book("FPIS", "Reference", 99), | |
Book("Darker", "Mystery", 80), | |
Book("It isn't", "Romance", 82) | |
) |
NewerOlder