Skip to content

Instantly share code, notes, and snippets.

View MortalFlesh's full-sized avatar

Petr Chromec MortalFlesh

  • Alma Career Czechia
  • Czech Republic
View GitHub Profile
@MortalFlesh
MortalFlesh / serviceCatalogueModel.fs
Last active January 22, 2020 15:31
ServiceCatalogue - model
//
// Concept Definition
//
type ConceptDefinition = {
Service: Service // domain * context
Instances: ServiceInstance list
Downstream: Downstream
}
@MortalFlesh
MortalFlesh / fsharpMix.fs
Last active October 17, 2019 11:49
Mix of functions, helpers, ...
module Color =
/// Transform GUID into a color RGBA hex
let ofGuid (guid: Guid) =
let hash = function
| minimum when minimum <= 0 -> "00"
| maximum when maximum >= 255 -> "FF"
| number ->
match number.ToString("X") with
| short when short.Length < 2 -> sprintf "0%s" short
| hex -> hex
@MortalFlesh
MortalFlesh / PHP Cheat-sheet.md
Last active May 16, 2018 11:29
PHP specific constructs, functions, aproaches etc. which are quite tricky, but usefull sometimes...

PHP Cheat-sheet

PHP specific constructs, functions, aproaches etc. which are quite tricky, but usefull sometimes...

Changing private attribute value

public function testShouldChangeInternalAttributeValue()
{
 $old = new Tenant('all', 'old')

PHPStorm Cheatsheet

Keyboard shortcuts

Storm

  • cmd + shift + a - find action
  • shift + ESC - close window

Find