move combination function from puppet to ruby code

Signed-off-by: Dominik Richter <dominik.richter@gmail.com>