Update: please note that I have since switched to using a set of bash scripts instead of poluting the Git repository with git svn.
Author: Kaspars Dambis
kaspars.net / @konstruktors
| import java.net.InetSocketAddress; | |
| import java.util.ArrayList; | |
| import java.util.List; | |
| import java.util.regex.Matcher; | |
| import java.util.regex.Pattern; | |
| /** | |
| * @see <a href="http://tools.ietf.org/html/rfc4291">[RFC4291] IP Version 6 | |
| * Addressing Architecture</a> | |
| * @see <a href="http://tools.ietf.org/html/rfc5952">[RFC5952] A Recommendation |
| #!/usr/bin/env ruby | |
| # A small ruby script to extract a git history to a tikz picture | |
| # Author: Michael Hauspie <Michael.Hauspie@lifl.fr> | |
| # | |
| # Not clean code, not always working well, but does its job in most of the cases I needed :) | |
| # A commit object | |
| class Commit | |
| attr_accessor :hash |
Update: please note that I have since switched to using a set of bash scripts instead of poluting the Git repository with git svn.
Author: Kaspars Dambis
kaspars.net / @konstruktors
| import select | |
| import socket | |
| import sys | |
| import objc | |
| from PyObjCTools import AppHelper | |
| objc.loadBundle("CoreBluetooth", globals(), | |
| bundle_path=objc.pathForFramework(u'/System/Library/Frameworks/IOBluetooth.framework/Versions/A/Frameworks/CoreBluetooth.framework')) |
| package com.example; | |
| import org.springframework.beans.factory.annotation.Autowired; | |
| import org.springframework.beans.factory.annotation.Qualifier; | |
| import org.springframework.boot.SpringApplication; | |
| import org.springframework.boot.autoconfigure.SpringBootApplication; | |
| import org.springframework.web.bind.annotation.RequestMapping; | |
| import org.springframework.web.bind.annotation.RestController; | |
| import java.util.List; |
Once in a while, you may need to cleanup resources (containers, volumes, images, networks) ...
// see: https://github.com/chadoe/docker-cleanup-volumes
$ docker volume rm $(docker volume ls -qf dangling=true)
$ docker volume ls -qf dangling=true | xargs -r docker volume rm
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.
| ############################################################################ | |
| # # | |
| # ------- Useful Docker Aliases -------- # | |
| # # | |
| # # Installation : # | |
| # copy/paste these lines into your .bashrc or .zshrc file or just # | |
| # type the following in your current shell to try it out: # | |
| # wget -O - https://gist.githubusercontent.com/jgrodziski/9ed4a17709baad10dbcd4530b60dfcbb/raw/d84ef1741c59e7ab07fb055a70df1830584c6c18/docker-aliases.sh | bash | |
| # # | |
| # # Usage: # |
| :- use_module(library(http/thread_httpd)). | |
| :- use_module(library(http/http_dispatch)). | |
| :- use_module(library(http/http_unix_daemon)). | |
| :- use_module(prolog/arouter). | |
| :- route_get(hello/Name, handle_hello(Name)). | |
| handle_hello(Name):- | |
| format('Content-Type: text/plain; charset=UTF-8~n~n'), | |
| format('Hello ~w', [Name]). |