Skip to content

Commit

Permalink
Copyright headers
Browse files Browse the repository at this point in the history
  • Loading branch information
bbuck committed Feb 15, 2017
1 parent 6b01f49 commit 4f11303
Show file tree
Hide file tree
Showing 31 changed files with 70 additions and 109 deletions.
20 changes: 0 additions & 20 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,26 +37,6 @@ Because of this, any build that introduces a change reducing a file below a 'B'
should be fixed. I believe that having a standard of a 'B' grade for all files
in the project is reasonable and reachable goal.

### Coveralls

The last integration for quality assurance is Coveralls. The purpose here is to
track test coverage. Unfortunately, with the tools available to us at the moment
test coverage only shows for files that have tests written for it. That means
if you introduce changes without a test suite, this will not impact testing
negatively. So any build without a test suite (unless justified) will be
rejected for this purpose.

The current goals of Coveralls is to keep test coverage as high as possible but
unfortunately the tools used to generate coverage only calculate coverage for
tested code. So coverage results are inaccurate, although still a nice metric
to have. My policy on exact percentage of coverage has changed since the projects
inception due to this fact and the fact there are some things that don't fit
into testing (based on how they're used).

That's not say testing is being dropped or reduced intentionally. Quite the
contrary I still plan on testing all relevant major pieces of code to ensure
the project does as expected (according to the tests).

## Development Tools

### Github Issues
Expand Down
11 changes: 6 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,11 +64,12 @@ this project matures I will clean up and define these details more and more.
project
- [x] Test suites with extensive coverage (protected with Coveralls) -- (not
'completed' per se, but started)
- [ ] Database backed server, can choose which database (default SQLite)
- [ ] SQLite3
- [ ] PostgreSQL
- [ ] MySQL
- [ ] Script engine for loading and executing Lua files.
- [ ] Database backed server, can choose which database (Neo4j)
- [x] Partial implementation
- [ ] Complete implementation
- [x] Script engine for loading and executing Lua files.
- [ ] Plugin system to allow for creation of whatever game one desires
- [ ] Plugin manager (like `go get` but for DragonMUD plugins)
- [ ] MUD Server

## Future
Expand Down
2 changes: 2 additions & 0 deletions ansi/ansi.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package ansi

import (
Expand Down
16 changes: 7 additions & 9 deletions assets/existence_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,13 @@ package assets_test
import (
. "github.com/bbuck/dragon-mud/assets"

. "github.com/onsi/ginkgo"
. "github.com/onsi/ginkgo/extensions/table"
. "github.com/onsi/gomega"
)

var _ = Describe("Existence", func() {
Describe("Dragonfile.toml", func() {
It("should exist as an asset file", func() {
_, err := Asset("Dragonfile.toml")
Ω(err).To(BeNil())
})
})
})
var _ = DescribeTable("Existence",
func(assetName string) {
_, err := Asset(assetName)
Ω(err).To(BeNil())
},
Entry("Dragonfile.toml", "Dragonfile.toml"))
8 changes: 5 additions & 3 deletions cli/colors.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package cli

import (
Expand Down Expand Up @@ -29,16 +31,16 @@ depending on the color settings of your terminal. Color codes are wrapped in
braces to provide them a simple yet easily distinguishable format. Bracketed
text that doesn't match a color code will not be replaced, but if you want to
display a color code the preced the opening brace with a \, like \\{b}.
\{L} {L}black{x} \{R} {R}red{x} \{G} {G}green{x} \{Y} {Y}yellow{x} \{B} {B}blue{x} \{M} {M}magenta{x} \{C} {C}cyan{x} \{W} {W}white{x}
\{l} {l}black{x} \{r} {r}red{x} \{g} {g}green{x} \{y} {y}yellow{x} \{b} {b}blue{x} \{m} {m}magenta{x} \{c} {c}cyan{x} \{w} {w}white{x}
If you plan to transition for bright (uppercase codes) to dark (lowercase codes)
you have to reset between. The best way to achieve this to group your reset
(metioned below) and dark color. For example going from \{R} to \{c} you might
do {R}\{R}this is bright red {x,c}\{x,c}this is dark cyan{x}. Note the reset occurs first,
this is important otherwise you'll reset the code you just set.
If you would prefer to highlight the background, then simply add a '-' before
the code (inside of the braces). For example: \{l,-Y} {l,-Y}Hello, World!{x}. Notice
that color specifications can have a comma seperating color values. This is
Expand Down
2 changes: 2 additions & 0 deletions cli/init.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package cli

import (
Expand Down
2 changes: 2 additions & 0 deletions cli/root.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package cli

import "github.com/spf13/cobra"
Expand Down
2 changes: 2 additions & 0 deletions cli/serve.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package cli

import (
Expand Down
2 changes: 2 additions & 0 deletions cli/version.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package cli

import (
Expand Down
2 changes: 2 additions & 0 deletions cmd/dragon/main.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package main

import (
Expand Down
2 changes: 2 additions & 0 deletions config/load.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package config

import (
Expand Down
2 changes: 2 additions & 0 deletions events/emitter.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package events

import (
Expand Down
4 changes: 3 additions & 1 deletion info/version.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package info

import "fmt"
Expand All @@ -14,7 +16,7 @@ func (v version) String() string {
// Version is the struct that represents the version of DragonMUD in use.
var Version = version{
Major: 0,
Minor: 2,
Minor: 1,
Patch: 0,
Flag: "dev",
}
2 changes: 2 additions & 0 deletions logger/logger.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package logger

import (
Expand Down
2 changes: 2 additions & 0 deletions output/console.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package output

import (
Expand Down
2 changes: 2 additions & 0 deletions random/core.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package random

import (
Expand Down
2 changes: 2 additions & 0 deletions random/dice.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package random

import (
Expand Down
2 changes: 2 additions & 0 deletions scripting/engine/lua_engine.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package engine

import (
Expand Down
2 changes: 2 additions & 0 deletions scripting/engine/lua_value.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package engine

import (
Expand Down
2 changes: 2 additions & 0 deletions scripting/engine/scriptable_object.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package engine

// ScriptableObject defines an interface that returns an object to represent
Expand Down
2 changes: 2 additions & 0 deletions scripting/engine_pool.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package scripting

import (
Expand Down
2 changes: 2 additions & 0 deletions scripting/module_loaders.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package scripting

import (
Expand Down
2 changes: 2 additions & 0 deletions scripting/server_engine.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package scripting

import "github.com/bbuck/dragon-mud/scripting/engine"
Expand Down
2 changes: 2 additions & 0 deletions server/base.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package server

import (
Expand Down
21 changes: 0 additions & 21 deletions talon/LICENSE

This file was deleted.

49 changes: 0 additions & 49 deletions talon/README.md

This file was deleted.

2 changes: 2 additions & 0 deletions talon/relationship.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package talon

import (
Expand Down
2 changes: 2 additions & 0 deletions text/tmpl/base.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package tmpl

import (
Expand Down
2 changes: 2 additions & 0 deletions text/tmpl/fasttemplate_renderer.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package tmpl

import (
Expand Down
2 changes: 2 additions & 0 deletions text/tmpl/renderer.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package tmpl

import "io"
Expand Down
4 changes: 3 additions & 1 deletion utils/json.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// Copyright (c) 2016-2017 Brandon Buck

package utils

import (
Expand All @@ -14,7 +16,7 @@ func ToJSON(i interface{}) string {
buf := new(bytes.Buffer)
encoder := json.NewEncoder(buf)
if err := encoder.Encode(i); err != nil {
logger.WithField("error", err.Error()).Error("Failed to encode object to JSON")
logger.LogWithSource("json_util").WithField("error", err.Error()).Error("Failed to encode object to JSON")

return ""
}
Expand Down

0 comments on commit 4f11303

Please sign in to comment.