From 5319e113bfb0060351c337f6805f76c1cc8b4436 Mon Sep 17 00:00:00 2001 From: "Sascha L. Teichmann" Date: Sun, 14 Sep 2014 00:02:04 +0200 Subject: [PATCH] Moved color parsing to common. --- cmd/tilemapper/main.go | 4 ++-- cmd/tilemapper/colors.txt => colors.txt | 0 {cmd/tilemapper => common}/colors.go | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) rename cmd/tilemapper/colors.txt => colors.txt (100%) rename {cmd/tilemapper => common}/colors.go (98%) diff --git a/cmd/tilemapper/main.go b/cmd/tilemapper/main.go index 0d1de61..8608811 100644 --- a/cmd/tilemapper/main.go +++ b/cmd/tilemapper/main.go @@ -45,9 +45,9 @@ func main() { flag.Parse() var err error - var colors *Colors + var colors *common.Colors - if colors, err = ParseColors(colorsfile); err != nil { + if colors, err = common.ParseColors(colorsfile); err != nil { log.Fatalf("Cannot open color file: %s", err) } diff --git a/cmd/tilemapper/colors.txt b/colors.txt similarity index 100% rename from cmd/tilemapper/colors.txt rename to colors.txt diff --git a/cmd/tilemapper/colors.go b/common/colors.go similarity index 98% rename from cmd/tilemapper/colors.go rename to common/colors.go index 90f3a9d..3fdb858 100644 --- a/cmd/tilemapper/colors.go +++ b/common/colors.go @@ -2,7 +2,7 @@ // Use of this source code is governed by the MIT license // that can be found in the LICENSE file. -package main +package common import ( "bufio"