Skip to content

Instantly share code, notes, and snippets.

View kmorcinek's full-sized avatar

Krzysztof Morcinek kmorcinek

View GitHub Profile
sheikhwaqas / docker-compose.yml
Last active October 3, 2022 14:40
Docker Compose configuration to run MySQL 5.6 and MySQL 5.7 on one instance. Create /var/lib/mysql56-data & /var/lib/mysql57-data with root as the owner of these directories before running docker-compose up -d
version: '3'
image: mysql:5.6
restart: unless-stopped
container_name: mysql56-container
- ""
wojteklu /
Last active June 20, 2024 11:52
Summary of 'Clean code' by Robert C. Martin

Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.

General rules

  1. Follow standard conventions.
  2. Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
  3. Boy scout rule. Leave the campground cleaner than you found it.
  4. Always find root cause. Always look for the root cause of a problem.

Design rules

kmorcinek / gitconfig
Last active February 27, 2022 18:45
Add it to ".gitconfig" file in your user directory. Configuration & aliases for git.
# autocrlf = true/input # it should be done explicit using .gitattributes
rebase = true
default = current
ls = log --pretty=format:"%C(yellow)%h%Cred%d\\ %Creset%s%Cgreen\\ [%an]" --decorate
lst = log --pretty=format:%C(yellow)%h%Cred%d\\ %Creset%s%Cgreen\\ [%an] --decorate -10
lds = log --pretty=format:"%C(yellow)%h\\ %ad%Cred%d\\ %Creset%s%Cgreen\\ [%an]" --decorate --date=short
SzymonPobiega / gist:5220595
Last active April 25, 2024 17:19
DDD/CQRS/ES/Architecture videos

If you have two days to learn the very basics of modelling, Domain-Driven Design, CQRS and Event Sourcing, here's what you should do:

In the evenings read the [Domain-Driven Design Quickly Minibook]{}. During the day watch following great videos (in this order):

  1. Eric Evans' [What I've learned about DDD since the book]{}
  2. Eric Evans' [Strategic Design - Responsibility Traps]{}
  3. Udi Dahan's [Avoid a Failed SOA: Business & Autonomous Components to the Rescue]{}
  4. Udi Dahan's [Command-Query Responsibility Segregation]{}
  5. Greg Young's [Unshackle Your Domain]{}
  6. Eric Evans' [Acknowledging CAP at the Root -- in the Domain Model]{ht
iros /
Created August 22, 2012 14:42
Documenting your REST API


<Additional information about your API call. Try to use verbs that match both request type (fetching vs modifying) and plurality (one vs multiple).>

  • URL

    <The URL Structure (path only, no root url)>

  • Method: