Skip to content

Instantly share code, notes, and snippets.

@AVGP
Created September 25, 2014 08:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AVGP/85a3928cc3ba3a4e788d to your computer and use it in GitHub Desktop.
Save AVGP/85a3928cc3ba3a4e788d to your computer and use it in GitHub Desktop.
Agile Principle of the day - simple HTTP quote service
package main
import(
"fmt"
"math/rand"
"time"
"net/http"
)
func main() {
principles := []string{
"Our highest priority is to satisfy the customer through early and continuous delivery of valuable software.",
"Welcome changing requirements, even late in development. Agile processes harness change for the customer's competitive advantage.",
"Deliver working software frequently, from a couple of weeks to a couple of months, with a preference to the shorter timescale.",
"Business people and developers must work together daily throughout the project.",
"Build projects around motivated individuals. Give them the environment and support they need, and trust them to get the job done.",
"The most efficient and effective method of conveying information to and within a development team is face-to-face conversation.",
"Working software is the primary measure of progress.",
"Agile processes promote sustainable development. The sponsors, developers, and users should be able to maintain a constant pace indefinitely.",
"Continuous attention to technical excellence and good design enhances agility.",
"Simplicity--the art of maximizing the amount of work not done--is essential.",
"The best architectures, requirements, and designs emerge from self-organizing teams.",
"At regular intervals, the team reflects on how to become more effective, then tunes and adjusts its behavior accordingly." }
rand.Seed(time.Now().Unix())
//fmt.Printf("%v", principles[rand.Intn(len(principles))])
http.HandleFunc("/", func(res http.ResponseWriter, r *http.Request) { fmt.Fprintf(res, "%s\n", principles[rand.Intn(len(principles))]) })
http.ListenAndServe(":8080", nil )
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment